"se...@t-online.de" <se...@t-online.de> writes: Hello, I am compiling and testing libgmp for AmigaOS. Yes, I am crazy. I use<https://gmplib.org/download/gmp/gmp-6.2.1.tar.lz> Thanks to bebbo's gcc https://github.com/bebbo/amiga-gcc <https://github.com/bebbo/amiga-gcc> I was quite successful. I had some issues in the tests hovever. For instance t-conv, t-sqrt and t-sqrt_ui failed. The bugs disappeared when I compiled without optimization and appeared when I used -O2, so I suspected a compiler bug and reported that to the Amiga gcc6 maintainer. He looked after the problem and found an issue inside libgmp's code. The bug is inside gmp's header longlong.h:1220, where asm for 68000 is defined: wrong code: ... " | End inlined umul_ppmm" \ : "=&d" (xh), "=&d" (xl), \ "=d" (__umul_tmp1), "=&d" (__umul_tmp2) \ : "%2" ((USItype)(a)), "d" ((USItype)(b))); \ correction: ... " | End inlined umul_ppmm" \ : "=&d" (xh), "=&d" (xl), \ "=&d" (__umul_tmp1), "=&d" (__umul_tmp2) \ <--- an & must be added after the = : "%2" ((USItype)(a)), "d" ((USItype)(b))); \ The current code looks correct to me. Please explain why you think it is not correct.
-- Torbjörn Please encrypt, key id 0xC8601622 _______________________________________________ gmp-bugs mailing list gmp-bugs@gmplib.org https://gmplib.org/mailman/listinfo/gmp-bugs