[PATCH] D147432: [asan][test][win] Port trivial tests to not use clang-cl on MinGW
Alvin Wong via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Apr 15 06:15:52 PDT 2023
alvinhochun added a comment.
In D147432#4266456 <https://reviews.llvm.org/D147432#4266456>, @MaskRay wrote:
> IIUC `-Od` in MSVC (disable optimizations) is the default. `-O0` is the default in Clang. Can we remove `%Od ` from RUN lines?
I'm not sure. Digging through the history shows they were previously using `-O0` until that flag was replaced in https://reviews.llvm.org/D64506. The first instance of `-O0` being added to the asan tests was https://reviews.llvm.org/D3767 with no explanation why it was needed. Curiously it seems only Windows tests using clang-cl had this flag. Was the default opt level for clang-cl different back then?
For cl.exe, https://learn.microsoft.com/en-us/cpp/build/reference/o-options-optimize-code?view=msvc-170 seems to indicate that `/Ot` is the default. Of course clang-cl doesn't have to match that, but I wonder if there is a possibility it may change in the future.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D147432/new/
https://reviews.llvm.org/D147432
More information about the llvm-commits
mailing list