[PATCH] D67298: [ASan] Fix test case dlopen-mixed-c-cxx.c without C++ stdlib

Jonas Hahnfeld via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Sep 7 01:08:39 PDT 2019


Hahnfeld added a comment.

In D67298#1661672 <https://reviews.llvm.org/D67298#1661672>, @serge-sans-paille wrote:

> Mmmmh the whole point of the test is to test how asan behaves when meeting a symbol like `__cxa_throw` in a dlopened library when the calling compilation unit is not linked against libstdc++. Previous behavior was a segfault, we should now get a reasonable error. By defining `__cxa_throw` in the c file, you remove the origin of the bug, so sure it works, but it no longer tests the faulty situation. Maybe there's a symbol caught by asan and defined in both libcxx and libstdc++?


And that's what I don't understand and what I have been trying to sort out in my comments in D63877 <https://reviews.llvm.org/D63877>: In the default configuration the asan shared library is linked against libstdc++. As the C file is compiled with `-fsanitize=address` it pulls in a definition of `__cxa_throw`, so what's the difference?

For me, it's unacceptable that the test is failing for more than a month on a totally legit configuration. We should get this fixed rather sooner than later, and not being the author I'm grabbing at any straw without really getting insight into what's going on.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67298/new/

https://reviews.llvm.org/D67298





More information about the llvm-commits mailing list