[PATCH] D26177: [tsan] Add support for C++ exceptions into TSan (call __tsan_func_exit during unwinding)
Kuba Brecka via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 2 15:12:13 PDT 2016
kubabrecka removed rL LLVM as the repository for this revision.
kubabrecka updated this revision to Diff 76796.
kubabrecka added a comment.
Herald added subscribers: modocache, mgorny.
Updating patch. Added some helper function to EHPersonalitites.h/.cpp. I still kept `getDefaultEHPersonality` always return `EHPersonality::GNU_C` -- please advise what the behavior should be. Annotated all TSan callbacks as "nounwind", which means we don't need to transform leaf functions. Extracted the BB splitting and CallInst-to-InvokeInst logic from InlineFunction.cpp into Utils/Local.cpp. Removed the state machine from EscapeEnumerator.
I'll look into the size optimizations later, but shouldn't the optimizer already do what you describe for higher -O levels?
https://reviews.llvm.org/D26177
Files:
include/llvm/Analysis/EHPersonalities.h
include/llvm/Transforms/Utils/EscapeEnumerator.h
include/llvm/Transforms/Utils/Local.h
lib/Analysis/EHPersonalities.cpp
lib/CodeGen/ShadowStackGCLowering.cpp
lib/Transforms/Instrumentation/ThreadSanitizer.cpp
lib/Transforms/Utils/CMakeLists.txt
lib/Transforms/Utils/EscapeEnumerator.cpp
lib/Transforms/Utils/InlineFunction.cpp
lib/Transforms/Utils/Local.cpp
projects/compiler-rt/lib/tsan/rtl/tsan_rtl.cc
projects/compiler-rt/test/tsan/exceptions.cc
projects/compiler-rt/test/tsan/test.h
test/Instrumentation/ThreadSanitizer/no_sanitize_thread.ll
test/Instrumentation/ThreadSanitizer/str-nobuiltin.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D26177.76796.patch
Type: text/x-patch
Size: 30313 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161102/9a70772b/attachment.bin>
More information about the llvm-commits
mailing list