https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109712
--- Comment #10 from Carlos Galvez <carlosgalvezp at gmail dot com> --- Hi! I've continued to look into this and am having a slightly different but essentially same error with yet another Nvidia library, but this time is with a pure shared library, "libnvinfer.so", which was compiled against GCC 7. Most likely the library is statically linked against libcudart_static.a. The issue is not solved using bfd or lld linker. My program simply links against that library, which internally throws an exception. I get a very similar backtrace: #0 linear_search_fdes (ob=0x7fffffffd350, this_fde=0x0, pc=0x7fffdf4b6a69) at ../../../gcc/libgcc/unwind-dw2-fde.c:973 #1 0x00007fffdde1cde1 in find_fde_tail (dbase=2424076, bases=0x7fffffffd5a8, hdr=0x7ffff690ca70, pc=140736939649641) at ../../../gcc/libgcc/unwind-dw2-fde-dip.c:519 #2 _Unwind_Find_FDE (pc=<optimized out>, bases=bases@entry=0x7fffffffd5a8) at ../../../gcc/libgcc/unwind-dw2-fde-dip.c:573 #3 0x00007fffdde1847a in uw_frame_state_for (context=0x7fffffffd500, fs=0x7fffffffd5f0) at ../../../gcc/libgcc/unwind-dw2.c:1005 #4 0x00007fffdde19ecd in _Unwind_RaiseException (exc=0x904320) at ../../../gcc/libgcc/unwind.inc:104 #5 0x00007fffde2b7e6a in __cxa_throw () from /path/to/usr/lib64/libstdc++.so.6 #6 0x00007fffdf4b6a6a in ?? () from /path/to/nvinfer/lib/libnvinfer.so.8 #7 0x00007fffdf4c21b5 in ?? () from /path/to/nvinfer/lib/libnvinfer.so.8 #8 0x00007fffdfbddf02 in ?? () from /path/to/nvinfer/lib/libnvinfer.so.8 #9 0x00007fffdf42a118 in createInferBuilder_INTERNAL () from /path/to/nvinfer/lib/libnvinfer.so.8 #10 0x0000000000401163 in nvinfer1::(anonymous namespace)::createInferBuilder (logger=...) at nvinfer/include/NvInfer.h:9093 #11 0x0000000000401182 in main () at main.cpp:13 So the library was compiled with GCC 7 and has a dependency on libstdc++.so.6. Via LD_LIBRARY_PATH, I run my executable using GCC trunk (14)'s libstdc++.so.6. Now, I try to see if "libnvinfer_static.a" uses any symbol from "libgcc_eh.a", by doing: - Run "nm libgcc_eh.a" and store a list of all "T" or "t" symbols. - Run "nm libnvinfer_static.a" and store a list of all "U" symbols. - Compute the intersection between those two lists. This results in that "libnvinfer_static.a" only uses 1 symbol from libgcc_eh.a: _Unwind_Resume. Is the above test procedure correct to determine the symbols used from libgcc_eh.a? How come linking a pure shared library such as libnvinfer.so would lead to mixing types from different versions of libgcc_eh.a, i.e. how could those internal changes leak outside the shared library boundaries? After all this comes from __cxa_throw() from libstdc++.so.6, which is a versioned symbol. Shouldn't that function get a new symbol version if there's an ABI incompatible change? Thank you for your time and help, really appreciated!