Re: GMP 6.2.1 core2 x86_64 assembler error "operands invalid for `movq'"
Simon Sobisch writes: That is an old MacBook with the most current "developer command line tools" that were available (from 2013/2014 if I remember correctly). I am afraid obsolete systems might get less developer attention... Sigh. Sadly I don't know enough about assembly to patch it myself :-( But I can test because that machine is now available to me (it was passed to me instead of being thrown away; I did a reset, installed the most current software that was supported there and now try to get some programs running via terminal). I know asm well, but alas, I don't know the quirks of these old tools. If you're really eager to get these files to work, here is a cumbersome method: Build things on a current system. Use objdump -dw (or otool under macos) to see the encoding for the trouble instructions. Replace the movq instructions with .byte sequences. Re-compile on the current system to make sure the objdump output stays the same. Go back to the obsolete system and compile happily there. -- Torbjörn Please encrypt, key id 0xC8601622 ___ gmp-bugs mailing list gmp-bugs@gmplib.org https://gmplib.org/mailman/listinfo/gmp-bugs
Re: GMP 6.2.1 core2 x86_64 assembler error "operands invalid for `movq'"
> On 1 Nov 2022, at 22:55, Torbjörn Granlund wrote: > > Is this on a recent version of macos with current versions gcc+binutils > installed? Or is either old variants? Darwin 11.4.2 is OS X 10.7.5 Lion from September 19, 2012. https://en.wikipedia.org/wiki/OS_X_Lion ___ gmp-bugs mailing list gmp-bugs@gmplib.org https://gmplib.org/mailman/listinfo/gmp-bugs
Re: GMP 6.2.1 core2 x86_64 assembler error "operands invalid for `movq'"
Am 01.11.2022 um 22:55 schrieb Torbjörn Granlund: Simon Sobisch writes: config.status: linking ../mpn/x86_64/core2/popcount.asm to mpn/popcount.asm config.status: linking ../mpn/x86_64/core2/hamdist.asm to mpn/hamdist.asm tmp-popcount.s:181:suffix or operands invalid for `movq' tmp-hamdist.s:206:suffix or operands invalid for `movq' Is this on a recent version of macos with current versions gcc+binutils installed? Or is either old variants? That is an old MacBook with the most current "developer command line tools" that were available (from 2013/2014 if I remember correctly). This is not the same bug as we worked around for register-to-register copying on x86-32 some years ago. It is not cleer what syntax this assembler might accept, and which also gives the right instruction (here and on non-prolematic hosts). Sigh. Sadly I don't know enough about assembly to patch it myself :-( But I can test because that machine is now available to me (it was passed to me instead of being thrown away; I did a reset, installed the most current software that was supported there and now try to get some programs running via terminal). Note: running configure with ABI=32 (which leads to use of x86 instead of x86_64) leads to all files compiling and also all tests passing. Therefore we at least know that the syntax used there including that old register to register workaround _does_ work correct with that assembler. Thank you for getting back to me on this topic. Simon ___ gmp-bugs mailing list gmp-bugs@gmplib.org https://gmplib.org/mailman/listinfo/gmp-bugs
Re: GMP 6.2.1 core2 x86_64 assembler error "operands invalid for `movq'"
Simon Sobisch writes: config.status: linking ../mpn/x86_64/core2/popcount.asm to mpn/popcount.asm config.status: linking ../mpn/x86_64/core2/hamdist.asm to mpn/hamdist.asm tmp-popcount.s:181:suffix or operands invalid for `movq' tmp-hamdist.s:206:suffix or operands invalid for `movq' Is this on a recent version of macos with current versions gcc+binutils installed? Or is either old variants? This is not the same bug as we worked around for register-to-register copying on x86-32 some years ago. It is not cleer what syntax this assembler might accept, and which also gives the right instruction (here and on non-prolematic hosts). -- Torbjörn Please encrypt, key id 0xC8601622 ___ gmp-bugs mailing list gmp-bugs@gmplib.org https://gmplib.org/mailman/listinfo/gmp-bugs
GMP 6.2.1 core2 x86_64 assembler error "operands invalid for `movq'"
Environment: Version: GNU MP 6.2.1 Host type: core2-apple-darwin11.4.2 ABI: 64 linked files: config.status: linking ../mpn/x86_64/core2/popcount.asm to mpn/popcount.asm config.status: linking ../mpn/x86_64/core2/hamdist.asm to mpn/hamdist.asm make -k builds everything without an error but those two above fail (I think in gas), details see below. When doing a research on this issue I recognized in mpn/x86/pentium4/sse/popcount.asm a comment "movq avoided due to gas bug" (which is in since GMP 4.3). Maybe it is possible do do something similar for popcount.asm and hamdist.asm in mpn/x86_64/core2 ? Making all in mpn /bin/sh ../libtool --mode=compile --tag=CC ../../mpn/m4-ccas --m4="m4" gcc -std=gnu99 -c -DHAVE_CONFIG_H -I. -I../../mpn -I.. -D__GMP_WITHIN_GMP -I../.. -DOPERATION_`echo popcount | sed 's/_$//'` -O2 -pedantic -fomit-frame-pointer -m64 -mtune=core2 -march=core2 `test -f 'popcount.asm' || echo '../../mpn/'`popcount.asm libtool: compile: ../../mpn/m4-ccas --m4=m4 gcc -std=gnu99 -c -DHAVE_CONFIG_H -I. -I../../mpn -I.. -D__GMP_WITHIN_GMP -I../.. -DOPERATION_popcount -O2 -pedantic -fomit-frame-pointer -m64 -mtune=core2 -march=core2 popcount.asm -fno-common -DPIC -o .libs/popcount.o m4 -DHAVE_CONFIG_H -D__GMP_WITHIN_GMP -DOPERATION_popcount -DPIC popcount.asm >tmp-popcount.s gcc -std=gnu99 -c -DHAVE_CONFIG_H -I. -I../../mpn -I.. -D__GMP_WITHIN_GMP -I../.. -DOPERATION_popcount -O2 -pedantic -fomit-frame-pointer -m64 -mtune=core2 -march=core2 tmp-popcount.s -fno-common -DPIC -o .libs/popcount.o tmp-popcount.s:181:suffix or operands invalid for `movq' make[2]: *** [popcount.lo] Error 1 /bin/sh ../libtool --mode=compile --tag=CC ../../mpn/m4-ccas --m4="m4" gcc -std=gnu99 -c -DHAVE_CONFIG_H -I. -I../../mpn -I.. -D__GMP_WITHIN_GMP -I../.. -DOPERATION_`echo hamdist | sed 's/_$//'` -O2 -pedantic -fomit-frame-pointer -m64 -mtune=core2 -march=core2 `test -f 'hamdist.asm' || echo '../../mpn/'`hamdist.asm libtool: compile: ../../mpn/m4-ccas --m4=m4 gcc -std=gnu99 -c -DHAVE_CONFIG_H -I. -I../../mpn -I.. -D__GMP_WITHIN_GMP -I../.. -DOPERATION_hamdist -O2 -pedantic -fomit-frame-pointer -m64 -mtune=core2 -march=core2 hamdist.asm -fno-common -DPIC -o .libs/hamdist.o m4 -DHAVE_CONFIG_H -D__GMP_WITHIN_GMP -DOPERATION_hamdist -DPIC hamdist.asm >tmp-hamdist.s gcc -std=gnu99 -c -DHAVE_CONFIG_H -I. -I../../mpn -I.. -D__GMP_WITHIN_GMP -I../.. -DOPERATION_hamdist -O2 -pedantic -fomit-frame-pointer -m64 -mtune=core2 -march=core2 tmp-hamdist.s -fno-common -DPIC -o .libs/hamdist.o tmp-hamdist.s:206:suffix or operands invalid for `movq' make[2]: *** [hamdist.lo] Error 1 Thanks for any pointers, Simon ___ gmp-bugs mailing list gmp-bugs@gmplib.org https://gmplib.org/mailman/listinfo/gmp-bugs