-
Notifications
You must be signed in to change notification settings - Fork 997
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Asan memory leak detection on x86 platform #1049
Comments
works for current clang:
Doesn't work for my gcc (7.3.0). |
(closing since there is nothing to fix in the LLVM trunk) |
i tried using clang6.0 to compile my test app but it does not seem to work either, may i know which version of clang are you using ? clang-6.0 -g -fsanitize=address -fno-omit-frame-pointer -m32 -o asantest asantest.c && ./asantest hi |
I am using the current clang trunk (9.0), pretty sure it will work the same in 8.0 and 7.0, but please verify. |
On ubuntu 20.04 clang -m32 not works
|
lsan does not detect 100% of leaks. after return from main() pointer still can be on the stack in some uninitialized stack variable and be visible to the lsan long after leak happens from the c++ perspective. |
Hi,
Change description mentioned as part of "https://reviews.llvm.org/D28609" says memory leaks detection is disabled by default, may i know how to enable it at run time (or) compile time?
Sample C program with memory leak
cat asantest.c
gcc -g -m32 -fsanitize=address -fno-omit-frame-pointer asantest.c -o asantest
when program run as shown below , no leaks were detected.
when program run with ASAN_OPTIONS , following error is shown.
My system info
Thanks in advance.
The text was updated successfully, but these errors were encountered: