[PATCH] mpn/sh/*.s: Transform to m4-ccas format.
takasi-y at ops.dti.ne.jp
takasi-y at ops.dti.ne.jp
Thu Jun 14 18:03:25 CEST 2007
Thank you for your reply.
> It seems odd that the configure script doesn't detect the .s files. I
> tested "configure --host=sh2-unknown-linux-gnu" and it worked as it
> should. (Admittedly, I did that on a non-SH non-Linux system.)
Yes it detects .s files, but doesn't detect that mpn_{add,sub}_n functions
are defined.
> What is your evidence for that configure really fails to detect the
> SH assembly code?
Please try this.
$ ./configure --host=sh2-unknown-linux-gnu
$ grep "define HAVE_NATIVE" config.h
This should produce following output.
#define HAVE_NATIVE_mpn_add_n 1
#define HAVE_NATIVE_mpn_sub_n 1
But, nothing cames out without the patch.
And, this results a problem in addsub_n.c.
# Sorry, I should have explained this first.
The file mpn/addsub_n.c have lines like following.
| #if HAVE_NATIVE_mpn_add_nc || !HAVE_NATIVE_mpn_add_n
| acyo = mpn_add_nc (r1p + off, s1p + off, s2p + off, this_n, acyo);
| #else
| acyn = mpn_add_n (r1p + off, s1p + off, s2p + off, this_n);
| acyo = acyn + mpn_add_1 (r1p + off, r1p + off, this_n, acyo);
| #endif
Without the fix, "then clause(?)" is selected instead of "else clause"
because HAVE_NATIVE_mpn_add_n is not defined,
But because mpn_add_nc() is also not defined, this symbol is left in the
library as an unresolved symbol. This makes the library useless.
Hope I could explain the issue this time....
Best regards,
/yoshii
More information about the gmp-bugs
mailing list