This is the mail archive of the mailing list for the binutils 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: PATCH: PR ld/12730: regression] crash when allocating in a static constructor

On Sun, May 15, 2011 at 08:14:19PM +1000, Craig Southeren wrote:
> At the heart of the issue is the timing of initialising statics at
> the global/namespace level.

You won't get much traction on this issue here on the binutils list.
We did have a ld bug that affected you but that has now been fixed.
Further discussion should go to one of the gcc lists.  If you can get
agreement that functions declared with __attribute__ ((constructor))
ought to be treated exactly as standard C++ namespace scope
constructors regarding initialisation order, then it would be good to
have your testcase added to the g++ testsuite.  That should ensure
both g++ and ld do not regress.

FWIW, I think your testcase is quite reasonable.  The main reason I
wanted the testcase removed from the ld testsuite because I found
the testcase failed using commonly available versions of g++, and
therefore a C++ testcase wasn't the best way to test ld behaviour.

Alan Modra
Australia Development Lab, IBM

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