[PATCH] D34210: Add __has_feature(leak_sanitizer)

Francis Ricci via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 20 12:14:41 PDT 2017


fjricci reclaimed this revision.
fjricci added a comment.

As I've looked into this further, I do think we need `has_feature(leak_sanitizer)` after all. For example, if a user program calls `pthread_create()` with a custom stack size, leak sanitizer will intercept the call to `pthread_create()`, and may modify the stack size set by the user (lsan's interceptor for `pthread_create` calls `AdjustStackSize` in sanitizer_common). Without `has_feature(leak_sanitizer)`, there's no good way for the user program to account for these sorts of modifications. There are most likely other interceptors which will cause similar issues, this is just the first example I ran into.


https://reviews.llvm.org/D34210





More information about the cfe-commits mailing list