File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change 46
46
47
47
#if defined(__linux__) || defined(__APPLE__)
48
48
MORESTACK:
49
+ #ifdef __linux__
50
+ .cfi_startproc
51
+
52
+ // Some magic that explains to the unwinder the unusal nature
53
+ // of this stack frame. Copied verbatim from libgcc, which
54
+ // has comments explaining it.
55
+ .cfi_offset 8 , 8
56
+ .cfi_escape 0x15 , 4 , 0x7d
57
+ #endif
49
58
50
59
pushl %ebp
60
+ #ifdef __linux__
61
+ .cfi_def_cfa_offset 8
62
+ .cfi_offset %ebp , -8
63
+ #endif
51
64
movl %esp , %ebp
65
+ #ifdef __linux__
66
+ .cfi_def_cfa_register %ebp
67
+ #endif
52
68
53
69
// FIXME (1226): main is compiled with the split-stack prologue,
54
70
// causing it to call __morestack, so we have to jump back out
@@ -105,7 +121,12 @@ MORESTACK:
105
121
call UPCALL_CALL_C
106
122
107
123
addl $16 ,%esp
124
+
108
125
popl %ebp
126
+ #ifdef __linux__
127
+ .cfi_restore %ebp
128
+ .cfi_def_cfa %esp , 4
129
+ #endif
109
130
retl $8
110
131
111
132
.L$bail:
@@ -118,6 +139,9 @@ MORESTACK:
118
139
119
140
jmpl *%edx
120
141
142
+ #ifdef __linux__
143
+ .cfi_endproc
144
+ #endif
121
145
122
146
#else
123
147
MORESTACK:
You can’t perform that action at this time.
0 commit comments