RFR: JDK-8302599: Extend ASan support to Microsoft Visual C++
Justin King
jcking at google.com
Thu Feb 16 15:44:24 UTC 2023
It is consumed by the ASan runtime itself, which is loaded first well
before main(int, char**) is invoked. In order for ASan to find it, the
symbol to it has to be exported. See references to __asan_default_options
in
https://github.com/llvm/llvm-project/blob/main/compiler-rt/lib/asan/asan_flags.cpp.
GCC uses the same runtime library as does MSVC.
On Thu, Feb 16, 2023 at 5:38 AM Thomas Stüfe <thomas.stuefe at gmail.com>
wrote:
> I’m curious, why does the options function have to be exported? Who is
> consuming it?
>
> On Wed 15. Feb 2023 at 19:01, Justin King <jcking at openjdk.org> wrote:
>
>> Update build-related infrastructure to support building with ASan under
>> Microsoft Visual C++.
>>
>> -------------
>>
>> Commit messages:
>> - Move comment to appropriate location
>> - Use elif instead of separate if
>> - Only pass -fsanitize=address to linker for Clang/GCC
>> - Update asan_default_options.c with MSVC-specific extensions
>> - Support using ASan with MSVC
>>
>> Changes: https://git.openjdk.org/jdk/pull/12580/files
>> Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=12580&range=00
>> Issue: https://bugs.openjdk.org/browse/JDK-8302599
>> Stats: 25 lines in 2 files changed: 18 ins; 0 del; 7 mod
>> Patch: https://git.openjdk.org/jdk/pull/12580.diff
>> Fetch: git fetch https://git.openjdk.org/jdk pull/12580/head:pull/12580
>>
>> PR: https://git.openjdk.org/jdk/pull/12580
>>
>
--
[image: Google Logo]
Justin King
Software Engineer
jcking at google.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/build-dev/attachments/20230216/12b69aa8/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3999 bytes
Desc: S/MIME Cryptographic Signature
URL: <https://mail.openjdk.org/pipermail/build-dev/attachments/20230216/12b69aa8/smime.p7s>
More information about the build-dev
mailing list