Re: AddressSanitizer on Windows

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Switching compilers is sadly probably not a possibility. Neither is
using valgrind to archive what the AddressSanitizer can do.


On 04.05.20 23:45, Dan Kegel wrote:
> If you can use msvc, check the options for visual studio community
> 2019.  The version I downloaded yesterday mentioned it.
>
> See also
> https://devblogs.microsoft.com/cppblog/addresssanitizer-asan-for-windows-with-msvc/
>
> On Mon, May 4, 2020 at 11:44 AM Lou Knauer via Gcc-help
> <gcc-help@xxxxxxxxxxx> wrote:
>> Hi,
>>
>>
>> Is it possible to use the AddressSanitizer (-fsanitize=address) on
>> Windows (And if yes, how?)? I built gcc (master branch) from source
>> today, and it told me that the current configuration/target
>> (mingw/msys2, x86_64) would not work with the address sanitizer runtime
>> libraries. In fact, compiling binaries actually works, but when trying
>> to link with -fsanitize=address it fails (with pre-built gcc-9 as well).
>>
>> Are there plans to bring gcc's AddressSanitizer to Windows in the near
>> feature if not? [1] says that LLVMs AddressSanitizer is "periodically"
>> merged to GCC, which does work on windows.
>>
>>
>> On Linux, i managed to link a binary built by gcc with clangs
>> `libclang_rt.asan-x86_64.so` and run it, but something similar with DLLs
>> on windows segfaults (and this seams like a very dirty hack too). Any ideas?
>>
>>
>> Thank you very much in advance,
>>
>> Lou
>>
>>
>> [1]
>> https://github.com/google/sanitizers/wiki/AddressSanitizerClangVsGCC-(6.0-vs-8.1)
>>
>>
>>





[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux