[PATCH] D14947: [tsan] Port tsan_rtl_amd64.S to OS X to add support for setjmp/longjmp
Kuba Brecka via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 24 05:22:57 PST 2015
kubabrecka created this revision.
kubabrecka added reviewers: dvyukov, samsonov, kcc, glider.
kubabrecka added subscribers: llvm-commits, zaks.anna, ismailp.
This patch ports the assembly file tsan_rtl_amd64.S to OS X, where we need several changes:
* Some assembler directives are not available on OS X (.hidden, .type, .size)
* Symbol names need to start with an underscore (added a ASM_TSAN_SYMBOL macro for that).
* To make the interceptors work, we ween to name the function "_wrap_setjmp" (added ASM_TSAN_SYMBOL_INTERCEPTOR for that).
* Calling the original setjmp is done with a simple "jmp _setjmp".
* __sigsetjmp doesn't exist on OS X.
http://reviews.llvm.org/D14947
Files:
lib/sanitizer_common/sanitizer_asm.h
lib/tsan/CMakeLists.txt
lib/tsan/rtl/tsan_interceptors.cc
lib/tsan/rtl/tsan_rtl_amd64.S
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D14947.41028.patch
Type: text/x-patch
Size: 8243 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151124/fb045dc7/attachment.bin>
More information about the llvm-commits
mailing list