This is the mail archive of the gcc-help@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: Question about duplicate C++ functions generated with GNU 3.4.1


Jon Watson wrote:
Hi -

We recently switched to GCC 3.4.1 (built for PowerPC EABI). As we have started to recompile our code and bring up our products we noticed some odd behavior. Specifically, it appears that GCC has created two functionally identical copies of C++ object constructors that are referenced by different symbols...

Symbols for BufferPool::BufferPool():
00002c78 T _ZN10BufferPoolC2Ev	./..\..\..\..\..\..\..\..\..\airvana\sw\ne\src\net\BufferPool\src\BufferPool.cpp:91
00002c88 T _ZN10BufferPoolC1Ev     ./..\..\..\..\..\..\..\..\..\airvana\sw\ne\src\net\BufferPool\src\BufferPool.cpp:91

It is to do with ctors-for-most-derived and ctors-for-base. Refer to the ABI document (linked to from Further Readings) for details. I thought there qas a faq or something about it, but I cannot find it right now. There is a bug report pointing out that, where virtual bases are not involved, these two things are the same.

nathan

--
Nathan Sidwell    ::   http://www.codesourcery.com   ::     CodeSourcery LLC
nathan@codesourcery.com    ::     http://www.planetfall.pwp.blueyonder.co.uk


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