This is the mail archive of the 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]

Re: libg++- (was: Re: Segmentation fault building libg++ without named returns)

> On Monday, 11 September 2000, 17:25:11 -0400, wrote:
> > > The rtl at -O3 has no calls to Fix::~Fix(void), even in
> > > There is also no definition for Fix::~Fix(void) in the assemble output.
> > 
> > If I specify `-fno-inline', the weak defines are output at -O3 in the
> > implementation object module.  It seems a runtime callable version of
> > an inline function is not being output when the function isn't static.  
> > For modules which include Fix.h but don't have `#pragma implementation',
> > it appears the functions defined in the interface are not being inlined
> > and a runtime callable version must exist.
> Your analysis is correct and is similar to my observations. Since I
> don't have enough time to fix this properly, I came up with the hack
> to use -O0 on ia32-linux. I've attached the patch which supersedes the
> former version -20000907; "make bootstrap check" ran successfully using
> this patch.

I have found that the problem is in some way related to math inlines.  If
the build is done with __NO_MATH_INLINES defined, then Fix.o contains all
the required weak defines.  There are no testsuite failures with your
version -20000907 if I add -D__NO_MATH_INLINES to CXXFLAGS in the Makefile's.

The math inlines are output at optimisations above O0.  If the preprocessing
is done at -O0 and the compilation at -O3, the weak defines are there.  The
other way around doesn't work.

I have been poking around in cc1plus trying to find why the weak defines
aren't getting output when the math inlines are present.  If somebody more
familiar with code can suggest some places to look, it would be helpful.

J. David Anglin                        
National Research Council of Canada              (613) 990-0752 (FAX: 952-6605)

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