Also:
- add driver test (fsanitize-use-after-return.c)
- add basic IR test (asan-use-after-return.cpp)
- (NFC) cleaned up logic for generating table of __asan_stack_malloc depending on flag.
Paths
| Differential D104076
[clang-cl][sanitizer] Add -fsanitize-address-use-after-return to clang. ClosedPublic Authored by kda on Jun 10 2021, 4:49 PM.
Details Summary Also:
Diff Detail
Event TimelineHerald added subscribers: ormris, dexonsmith, dang, hiraditya. · View Herald TranscriptJun 10 2021, 4:49 PM Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJun 10 2021, 4:49 PM Comment Actions LGTM with some nits and if you extract FunctionStackPoisoner::initializeCallbacks into a separate patch
This revision is now accepted and ready to land.Jun 10 2021, 10:43 PM kda marked 9 inline comments as done. Comment Actions
This revision was landed with ongoing or failed builds.Jun 11 2021, 12:07 PM Closed by commit rGe0b469ffa142: [clang-cl][sanitizer] Add -fsanitize-address-use-after-return to clang. (authored by kda). · Explain Why This revision was automatically updated to reflect the committed changes. Comment Actions Note, clang-cl is an executable for a MSVC compatible compiler driver (ninja clang-cl), so using clang-cl in the subject can cause confusion.
Revision Contents
Diff 351527 clang/include/clang/Basic/CodeGenOptions.def
clang/include/clang/Basic/Sanitizers.h
clang/include/clang/Driver/Options.td
clang/include/clang/Driver/SanitizerArgs.h
clang/lib/Basic/Sanitizers.cpp
clang/lib/CodeGen/BackendUtil.cpp
clang/lib/Driver/SanitizerArgs.cpp
clang/test/CodeGen/asan-use-after-return.cpp
clang/test/Driver/cl-options.c
clang/test/Driver/fsanitize-use-after-return.c
llvm/include/llvm/Transforms/Instrumentation/AddressSanitizer.h
llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
|
I guess call{{.*}} can be removed from implicit-check-not?