[LLVMdev] AddressSanitizer+CMake unittest question

Chandler Carruth chandlerc at google.com
Mon Jun 25 06:01:47 PDT 2012

On Mon, Jun 25, 2012 at 5:00 AM, Chandler Carruth <chandlerc at google.com>wrote:
> A) We could require the host compiler to have support for
> -faddress-sanitizer, but ensure that the just-built runtime library is used
> rather than the host compiler's runtime library.

FWIW, I've started implementing this and folks can try it out as of r159134.

The way to test out the current CMake build is to comment out the exclusion
of 'compiler-rt' from the LLVM build in 'projects/CMakeLists.txt'. Then you
can build, for example 'make AsanTests' and it should compile both the
instrumented and non-instrumented unit tests.

Currently, you have to run them by hand -- I need to refactor a bit of the
LLVM cmake build before i can wire in nice convenience targets for running
these -- but I've tried and they seem to work for me...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120625/b694c265/attachment.html>

More information about the llvm-dev mailing list