public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/51333] New: cxxabi.h incompatible with -fkeep-inline-functions at link time
@ 2011-11-28 14:11 dak at gnu dot org
  2011-11-28 14:53 ` [Bug c++/51333] " redi at gcc dot gnu.org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: dak at gnu dot org @ 2011-11-28 14:11 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51333

             Bug #: 51333
           Summary: cxxabi.h incompatible with -fkeep-inline-functions at
                    link time
    Classification: Unclassified
           Product: gcc
           Version: 4.6.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: dak@gnu.org


Created attachment 25935
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25935
File failing at link time

The following file fails, when compiled with -fkeep-inline-functions, at link
time with the error

g++ -fkeep-inline-functions abi.cc
/tmp/ccI7H3ZL.o: In function
`__gnu_cxx::recursive_init_error::recursive_init_error()':
abi.cc:(.text._ZN9__gnu_cxx20recursive_init_errorC2Ev[_ZN9__gnu_cxx20recursive_init_errorC5Ev]+0x16):
undefined reference to `vtable for __gnu_cxx::recursive_init_error'
collect2: ld returned 1 exit status

Compilation exited abnormally with code 1 at Mon Nov 28 14:41:24

Version is
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/i686-linux-gnu/4.6.1/lto-wrapper
Target: i686-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro
4.6.1-9ubuntu3' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++,go --prefix=/usr
--program-suffix=-4.6 --enable-shared --enable-linker-build-id
--with-system-zlib --libexecdir=/usr/lib --without-included-gettext
--enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6
--libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu
--enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-plugin
--enable-objc-gc --enable-targets=all --disable-werror --with-arch-32=i686
--with-tune=generic --enable-checking=release --build=i686-linux-gnu
--host=i686-linux-gnu --target=i686-linux-gnu
Thread model: posix
gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3)


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/51333] cxxabi.h incompatible with -fkeep-inline-functions at link time
  2011-11-28 14:11 [Bug c++/51333] New: cxxabi.h incompatible with -fkeep-inline-functions at link time dak at gnu dot org
@ 2011-11-28 14:53 ` redi at gcc dot gnu.org
  2011-11-28 15:35 ` dak at gnu dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: redi at gcc dot gnu.org @ 2011-11-28 14:53 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51333

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-11-28 14:38:15 UTC ---
works with -lsupc++ but I'm not sure why it fails without


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/51333] cxxabi.h incompatible with -fkeep-inline-functions at link time
  2011-11-28 14:11 [Bug c++/51333] New: cxxabi.h incompatible with -fkeep-inline-functions at link time dak at gnu dot org
  2011-11-28 14:53 ` [Bug c++/51333] " redi at gcc dot gnu.org
@ 2011-11-28 15:35 ` dak at gnu dot org
  2011-12-03  0:52 ` redi at gcc dot gnu.org
  2015-09-25 20:10 ` joshb at cadence dot com
  3 siblings, 0 replies; 5+ messages in thread
From: dak at gnu dot org @ 2011-11-28 15:35 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51333

David Kastrup <dak at gnu dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|4.5.2                       |

--- Comment #2 from David Kastrup <dak at gnu dot org> 2011-11-28 15:25:03 UTC ---
I am more surprised that actual demangling applications work without -lsupc++
as long as -fkeep-inline-functions is not used.

It is good to have a solution (even if its necessity depends on the compilation
options in a non-obvious way), but the actual error message certainly does not
particularly help in figuring out the problem.

I have to take back "works with 4.5.2" since I forgot that I used
-fkeep-inline-functions only once I needed to work around a 4.6.1 bug.  So I
actually have no data point when this option would have worked with the given
test file.

Probably that renders this particular report "invalid", but somebody really
should try making the link error message more intelligible.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/51333] cxxabi.h incompatible with -fkeep-inline-functions at link time
  2011-11-28 14:11 [Bug c++/51333] New: cxxabi.h incompatible with -fkeep-inline-functions at link time dak at gnu dot org
  2011-11-28 14:53 ` [Bug c++/51333] " redi at gcc dot gnu.org
  2011-11-28 15:35 ` dak at gnu dot org
@ 2011-12-03  0:52 ` redi at gcc dot gnu.org
  2015-09-25 20:10 ` joshb at cadence dot com
  3 siblings, 0 replies; 5+ messages in thread
From: redi at gcc dot gnu.org @ 2011-12-03  0:52 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51333

--- Comment #3 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-12-03 00:52:03 UTC ---
that function was not defined in its own file in 4.5, I moved it for PR 43863


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/51333] cxxabi.h incompatible with -fkeep-inline-functions at link time
  2011-11-28 14:11 [Bug c++/51333] New: cxxabi.h incompatible with -fkeep-inline-functions at link time dak at gnu dot org
                   ` (2 preceding siblings ...)
  2011-12-03  0:52 ` redi at gcc dot gnu.org
@ 2015-09-25 20:10 ` joshb at cadence dot com
  3 siblings, 0 replies; 5+ messages in thread
From: joshb at cadence dot com @ 2015-09-25 20:10 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=51333

Josh Baudhuin <joshb at cadence dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |joshb at cadence dot com

--- Comment #4 from Josh Baudhuin <joshb at cadence dot com> ---
Noticed this somewhat intermittently in 4.8.3. The option was not universally
applied to the build, just to the code in one .so (and the same code
rebuilt/linked as .a).


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-09-25 20:10 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-28 14:11 [Bug c++/51333] New: cxxabi.h incompatible with -fkeep-inline-functions at link time dak at gnu dot org
2011-11-28 14:53 ` [Bug c++/51333] " redi at gcc dot gnu.org
2011-11-28 15:35 ` dak at gnu dot org
2011-12-03  0:52 ` redi at gcc dot gnu.org
2015-09-25 20:10 ` joshb at cadence dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).