Adds the -fsanitize plumbing for memtag-globals. Makes -fsanitize=memtag
imply -fsanitize=memtag-globals.
This has no effect on codegen for now.
Paths
| Differential D127163
[clang] Add -fsanitize=memtag-globals (no-op). ClosedPublic Authored by hctim on Jun 6 2022, 3:46 PM.
Details Summary Adds the -fsanitize plumbing for memtag-globals. Makes -fsanitize=memtag This has no effect on codegen for now.
Diff Detail
Unit TestsFailed Event TimelineComment Actions Why do we want this as a separate -fsanitize= Comment Actions I don't have a lot of arguments either way, do you? Comment Actions We already have -fsanitize=memtag that implies -fsanitize=memtag-heap and -fsanitize=memtag-stack. It makes the most sense IMHO in the world where we want heap MTE. -fsanitize=memtag-heap is the most reasonable instead of -fsanitize-memtag-heap, as "do i need -fsanitize=memtag as well, like MSan?" is never a question. Comment Actions
I see, thanks for explaining. hctim added inline comments.
This revision is now accepted and ready to land.Jun 14 2022, 4:45 PM This revision was landed with ongoing or failed builds.Jun 15 2022, 10:08 AM Closed by commit rG45d88cd00846: [clang] Add -fsanitize=memtag-globals (no-op). (authored by hctim). · Explain Why This revision was automatically updated to reflect the committed changes. Comment Actions FYI: If you change serialized opts in a def file, you have to bump the pch version, else with builds that don't embed the llvm revision (LLVM_APPEND_VC_REV=OFF) won't notice they have to invalidate pchs. (In this case, I did this in https://github.com/llvm/llvm-project/commit/307109266f6c7598dfc69b6388fa271662de9388 for this change.) Comment Actions
Thanks!
Revision Contents
Diff 436059 clang/include/clang/Basic/Features.def
clang/include/clang/Basic/Sanitizers.def
clang/include/clang/Driver/SanitizerArgs.h
clang/lib/Driver/SanitizerArgs.cpp
clang/test/Driver/fsanitize.c
|