This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [CFT] in-tree GMP/MPFR, one more round


On Tue, 9 Jan 2007, Paolo Bonzini wrote:

> This version should fix all the problems that Kaveh reported, looking at
> the generated files.  I ask for testing precisely because all my systems
> have gmp and mpfr in the "usual" places.
> Paolo

I was able to compile a C-only --disable-bootstrap with your patch.  I was
also able to do a C-only complete bootstrap.  I'll do an all-languages
complete bootstrap later just to be sure, but I think it looks good.
Thanks very much!



Then I tried "make check" and it failed as per PR29404.  I think it's
critically important to have "make check" working for in-tree builds of
gmp and mpfr, their web pages specifically recommend checking because they
are often miscompiled.  However your patch is not to blame since the issue
also occurs with libiberty and probably any library we bootstrap.

The issue in the PR is that each library's testcases are compiled and/or
linked with the stage1 compiler (cc in my case) but the libraries
(libiberty.a, libgmp.a, libmpfr.a) were compiled with gcc stage3.  So in
the link step we're missing libgcc and have missing symbols.  Also some of
the configure steps in stage3 chose gcc defaults which no longer hold when
testcases are compiled with stage1 cc, like __attribute__.  I recall this
working for at least libiberty at some point, so it may be fallout from
switching to top level bootstrap or the autogen Makefile.in or something
like that.  I'm not sure.  Also most likely you won't notice any of this
if you use gcc for stage1.

A second problem, mpfr testcases can't find gmp.h so they all fail to
compile, most likely even if gcc is used for stage1.

I think a fix needs to teach all libraries that they should use stage3 gcc
for compiling and linking (if a bootstrap was done).  And we also need to
tell mpfr-check where to find gmp.h.

If you could help with this issue after your initial patch goes in, I
would very much appreciate it.

		Thanks,
		--Kaveh
--
Kaveh R. Ghazi			ghazi@caip.rutgers.edu


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]