[PATCH] D35443: Enable 64-bit Darwin LeakSanitizer by default on AddressSanitizer builds

Francis Ricci via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 11 09:59:10 PDT 2017


fjricci added a comment.

> Why does it omit some of the output?

My assumption was that the crash handlers may run inside atexit() or something similar, which would conflict with LSan, but I didn't dig too much into the way clang's crash handlers work.

> In any case, for clang test failures, if we think the value of running LSan is high enough already, we can just disable the two failing tests under ASan/LSan. I don't have a problem with that.

Makes sense to me

> The way I see it, I'd prefer users to opt in to use LSan. If a project wants to detect leaks, it can just set ASAN_OPTIONS=detect_leaks=1. Do you have a strong reason why detect_leaks=1 should be the default? (Besides parity with Linux.)

I think my main interest is related to getting the info out about it, I've spoken to a couple ASan users from other teams/companies who were interested in darwin+LSan but weren't aware it was now supported. Perhaps a better way to accomplish this would be just updating the documentation to reflect that LSan exists on Darwin now (probably with some sort of beta designation)? I assume the lightning talk would also help with visibility.

> Setting detect_leaks=1 in the ASan test suite is, of course, a good thing to do in any case.

It already is the default in the asan suite, but could be good to turn it on for the clang suite as well.


https://reviews.llvm.org/D35443





More information about the llvm-commits mailing list