On 13 April 2017 at 17:14, Nicolai Hähnle <nhaeh...@gmail.com> wrote: > From: Nicolai Hähnle <nicolai.haeh...@amd.com> > > Enable code sanitizers by adding -fsanitize=$foo flags for the compiler > and linker. > > In addition, this also disables checking for undefined symbols: running > the address sanitizer requires additional symbols which should be provided > by a preloaded libasan.so (preloaded for hooking into malloc & friends > globally), and the undefined symbols check gets tripped up by that. > > Running the tests works normally via `make check`, but shows additional > failures with the address sanitizer due to memory leaks that seem to be > mostly leaks in the tests themselves. I believe those failures should > really be fixed. In the mean-time, you can set > > export ASAN_OPTIONS=detect_leaks=0 > > to only check for more serious error types. > > v2: > - fail reasonably when an unsupported sanitize flag is given (Eric Engestrom) > > Reviewed-by: Bartosz Tomczyk <bartosz.tomczy...@gmail.com> (v1) > Reviewed-by: Eric Engestrom <eric.engest...@imgtec.com> > -- > Eric, did you ever figure out what went wrong with LLVM? I'm compiling > with a fairly recent LLVM trunk here and it works fine, and so apparently > did you. FWIW, I'm using gcc 6.2. > > Emil, as you can see I tried `make check`, and it works without the > preload because all the tests are standalone libraries. > Thought we had some tests that use shared libs. Glad to hear that everything works as expected. Thanks for double-checking!
Reviewed-by: Emil Velikov <emil.veli...@collabora.com> -Emil P.S. Feel free to add a note to docs/relnotes/17.1.0.html or I'll add one later today. _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev