Open wjwwood opened 6 years ago
I don't think this will help me, but something interesting and related that I found while researching:
It doesn't help me because I don't have a header that gets included in each TU, but it's interesting to know that's how std::cout
is probably implemented.
This issue appears as a
Program received signal SIGBUS, Bus error.
ingdb
or a return code of-7
from the gtest's that use memory tools, but only in our Linux-aarch64 CI jobs, e.g.:-- from https://ci.ros2.org/job/ci_linux-aarch64/1444/testReport/junit/(root)/projectroot/test_time__rmw_fastrtps_cpp/
I've given up trying to fix this for now. I can confirm that the actual checks are still working in gtest, it's just an error that occurs during shutdown and I have no reason to believe it means that there's a memory problem on ARM, so I think checking on Linux-x86_64 and macOS-x86_64 is good enough for now.
This is what I've been able to debug so far. I added this diff and then took the output from
gdb
:A useful thing to note here is that the interpose library (the one being loaded with
LD_PRELOAD
has it's shared libraryfini
called before some of the other libraries like the rmw fastrtps library (this information comes fromLD_DEBUG=libs
being set).My next things to check would be what the unloading order of the shared libraries are on Linux x86_64 and macOS.
Other ideas/notes:
gdb
is concerning:Backtrace stopped: previous frame identical to this frame (corrupt stack?)
libc6-2.23
: https://github.com/lattera/glibc/blob/a2f34833b1042d5d8eeb263b4cf4caaea138c4ad/stdlib/cxa_finalize.c#L48.bss
versus.data
compared tox86_64
?