Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
I got asan to fire on some out of bounds stuff with this change, but couldn't get ubsan to trigger on integer overflow for some reason. -fsanitize=undefined is in the ninja files, so maybe I just didn't trip it in the right way.
maybe because "-fsanitize=local-bounds is not included in -fsanitize=undefined" https://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html
I assume you are asking about the same code which triggers asan and you expect some ubsan report there.
Never mind if the question was about -fsanitize=signed-integer-overflow
Poorly worded on my part, I meant -fsanitize=signed-integer-overflow on different code. (I was trying to repro a bot failure caught by ubsan but couldn't repro it with this, I was wondering if I got something wrong, but separately was able to get asan to trigger on some bad code, so at least I know that the flags are probably correct)
Looks good to me. My only question is whether to optimistically assume these work out of the box on Mac, and to relax the asserts. Let's wait for input from Nico, though.
I believe I used this (by hacking up the gn files) locally on mac a while ago, but I'm not sure. LG, I'll try asan on mac and relax the assert if it works.
Naming-wise, it's maybe unclear if use_?san turns on the sanitizer for building llvm itself or for the output of clang or what, but it's consistent with the existing is_clang so maybe let's not worry about this too much for now.