-
Notifications
You must be signed in to change notification settings - Fork 11.9k
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
address sanitizer does not catch simple memory leak on aarch64/RHEL8 #57360
Comments
@llvm/issue-subscribers-backend-aarch64 |
(doh, confused asan and leaksan) We (Linaro) will double check the status of the test on our bots and get back to you. |
I completely missed that this isn't part of a test suite in llvm but an external repo. So no we don't run this on our bots but we do run the tests within llvm-project and see no issues there. I wasn't able to get a RHEL8 container going but I did get Centos 8 (they are related, right?), which also fails to detect the leak. This first bit is the Ubuntu container we run our bots on. The test works there.
Then the Centos 8 container.
We also have Bionic which is glibc 2.27, I'll see what that does. |
Focal works, it has glibc 2.27.
Though I'm just guessing that the glibc version is important. It could be unrelated. |
Clang |
I think this is an issue with RHEL8 clang itself, rather than glibc. I checked on a CENTOS8, but I assume kernel and runtime will be similar to RHEL8:
|
Wait, so you both tried Centos8 and one of you could reproduce it but the other one couldn't? |
It was not clear to me which clang was used by you or by @DavidSpickett. Debugging a little more, it seems to be the ASAN runtime and not the instrumentation, since linking an object built with CENTOS8 provided clang against the git as an runtime does work. |
For my Centos 8 checks I used clang 12 as the host compiler then built the test using the clang built from
I'm not sure whether the compiler-rt build uses the host compiler or the just built clang though. |
The asan runtime is usually linked statically by clang (libclang_rt.asan_static.a) and if you linked the tests using the build clang it will use the one built. I am not sure if you actually install if clang would use the system one, I will need to check it. |
This simple test case from the llvm-toolchain-integration-test-suite does not detect the memory leak when run on RHEL 8.
clang is 14.0.6, glibc is 2.28-209.
The bug only reproduces on RHEL 8 and only on aarch64. RHEL 9 and Fedora are unaffected on all arches.
The text was updated successfully, but these errors were encountered: