1 #include "sanitizer_common/sanitizer_asm.h"
5 .comm _ZN14__interception11real_setjmpE,8,8
6 .globl ASM_SYMBOL_INTERCEPTOR(setjmp)
7 ASM_TYPE_FUNCTION(ASM_SYMBOL_INTERCEPTOR(setjmp))
8 ASM_SYMBOL_INTERCEPTOR(setjmp):
11 // Save frame pointer and return address register
15 CFI_DEF_CFA_OFFSET (32)
19 // Adjust the SP for previous frame
21 CFI_DEF_CFA_REGISTER (8)
27 // Obtain SP, first argument to `void __tsan_setjmp(uptr sp)`
30 // call tsan interceptor
31 call ASM_SYMBOL(__tsan_setjmp)
33 // Restore env parameter
37 // Restore frame/link register
45 // tail jump to libc setjmp
46 la t1, _ZN14__interception11real_setjmpE
51 ASM_SIZE(ASM_SYMBOL_INTERCEPTOR(setjmp))
53 .comm _ZN14__interception12real__setjmpE,8,8
54 .globl ASM_SYMBOL_INTERCEPTOR(_setjmp)
55 ASM_TYPE_FUNCTION(ASM_SYMBOL_INTERCEPTOR(_setjmp))
56 ASM_SYMBOL_INTERCEPTOR(_setjmp):
59 // Save frame pointer and return address register
63 CFI_DEF_CFA_OFFSET (32)
67 // Adjust the SP for previous frame
69 CFI_DEF_CFA_REGISTER (8)
75 // Obtain SP, first argument to `void __tsan_setjmp(uptr sp)`
78 // call tsan interceptor
79 call ASM_SYMBOL(__tsan_setjmp)
81 // Restore env parameter
85 // Restore frame/link register
93 // tail jump to libc setjmp
94 la t1, _ZN14__interception12real__setjmpE
99 ASM_SIZE(ASM_SYMBOL_INTERCEPTOR(_setjmp))
101 .comm _ZN14__interception14real_sigsetjmpE,8,8
102 .globl ASM_SYMBOL_INTERCEPTOR(sigsetjmp)
103 ASM_TYPE_FUNCTION(ASM_SYMBOL_INTERCEPTOR(sigsetjmp))
104 ASM_SYMBOL_INTERCEPTOR(sigsetjmp):
107 // Save frame pointer and return address register
111 CFI_DEF_CFA_OFFSET (32)
115 // Adjust the SP for previous frame
117 CFI_DEF_CFA_REGISTER (8)
119 // Save env parameter
125 // Obtain SP, first argument to `void __tsan_setjmp(uptr sp)`
128 // call tsan interceptor
129 call ASM_SYMBOL(__tsan_setjmp)
131 // Restore env parameter
137 // Restore frame/link register
145 // tail jump to libc setjmp
146 la t1, _ZN14__interception14real_sigsetjmpE
151 ASM_SIZE(ASM_SYMBOL_INTERCEPTOR(sigsetjmp))
153 .comm _ZN14__interception16real___sigsetjmpE,8,8
154 .globl ASM_SYMBOL_INTERCEPTOR(__sigsetjmp)
155 ASM_TYPE_FUNCTION(ASM_SYMBOL_INTERCEPTOR(__sigsetjmp))
156 ASM_SYMBOL_INTERCEPTOR(__sigsetjmp):
159 // Save frame pointer and return address register
163 CFI_DEF_CFA_OFFSET (32)
167 // Adjust the SP for previous frame
169 CFI_DEF_CFA_REGISTER (8)
171 // Save env parameter
177 // Obtain SP, first argument to `void __tsan_setjmp(uptr sp)`
180 // call tsan interceptor
181 call ASM_SYMBOL(__tsan_setjmp)
183 // Restore env parameter
189 // Restore frame/link register
197 // tail jump to libc setjmp
198 la t1, _ZN14__interception16real___sigsetjmpE
203 ASM_SIZE(ASM_SYMBOL_INTERCEPTOR(__sigsetjmp))