Currently both ASAN and UBSAN are supported on Windows but only ASAN is enabled in LLVM build system. This patch enables the option to build LLVM with UBSAN on windows.
Tested with clang-cl released in LLVM16.
Differential D151511
[CMake] Enable building with UBSAN + clang-cl on windows dwang on May 25 2023, 3:40 PM. Authored by
Details Currently both ASAN and UBSAN are supported on Windows but only ASAN is enabled in LLVM build system. This patch enables the option to build LLVM with UBSAN on windows. Tested with clang-cl released in LLVM16.
Diff Detail
Event TimelineComment Actions
Comment Actions Apart from the two nits, the CMake changes LGTM, although I haven't tested the patch myself. I'm not particularly familiar with UBSAN, so can't really comment on the other changes to ubsan_ignorelist.txt.
Comment Actions For the ubsan ignore list, the newly added files reported ubsan crashes similiar to the one reported in: https://github.com/llvm/llvm-project/issues/61775
Comment Actions For the UBSAN crashes, I found an alternative workaround here: https://github.com/llvm/llvm-project/issues/31914. Since the errors only reproduce on windows, this seems like a cleaner fix. Comment Actions @pgousseau Thanks for the review! |
Perhaps supported by clang-cl?