[PATCH] D35085: Respect exitcode sanitizer option in UBSan

Evgenii Stepanov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 11 16:15:19 PDT 2017


eugenis added a comment.

Right, there are no interceptors in ubsan. I confused it with LSan, which has its own interceptors that are used in standalone mode only.

I'm not sure if adding interception to UBSan is a good idea. I think the current library is OK to link into shared libraries (i.e. does not have real global state). Or is it not the case any longer? I don't think we use this property anywhere, and clang does not link the ubsan runtime library to shared libraries. So maybe this is fine. Thoughts?

In https://reviews.llvm.org/D35085#805845, @fjricci wrote:

> There's a further complication with intercepting in UBSan - there doesn't seem to be a way to tell whether you're building standalone at compile time (although I could add a cmake define for that), so the UBSan interceptor will conflict with the TSan/ASan interceptor.


Just put interceptors in UBSAN_STANDALONE_SOURCES.


https://reviews.llvm.org/D35085





More information about the llvm-commits mailing list