This repository was archived by the owner on Apr 23, 2020. It is now read-only.
Commit aa805e4
committed
X86: swap EBP, ESP on !APPLE
Restore the `libunwind.h` enumeration values back to the inverted
values. This diverges from the DWARF definition of the register values.
However, this allows our header to be compatible with other unwind
implementations (e.g. HP, GNU Savannah, GCC).
The register IDs are only swapped in the header and need to be unswapped
when accessing the unwind register file. The flipped EBP and ESP only
applies on non-Apple x86 targets.
When optimizations were enabled, EBP and ESP would no longer be
equivalent. As a result, the incorrect access on Linux would manifest
as a failure to unwind the stack. We can now unwind the stack with and
without FPO on Linux x86.
Resolves PR30879!
git-svn-id: https://llvm.org/svn/llvm-project/libunwind/trunk@292723 91177308-0d34-0410-b5e6-96231b3b80d81 parent e1d4b2e commit aa805e4
2 files changed
+16
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
165 | 165 | | |
166 | 166 | | |
167 | 167 | | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | 168 | | |
173 | 169 | | |
174 | | - | |
175 | 170 | | |
176 | 171 | | |
177 | 172 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
122 | 122 | | |
123 | 123 | | |
124 | 124 | | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
125 | 128 | | |
| 129 | + | |
126 | 130 | | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
127 | 134 | | |
| 135 | + | |
128 | 136 | | |
129 | 137 | | |
130 | 138 | | |
| |||
154 | 162 | | |
155 | 163 | | |
156 | 164 | | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
157 | 168 | | |
| 169 | + | |
158 | 170 | | |
159 | 171 | | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
160 | 175 | | |
| 176 | + | |
161 | 177 | | |
162 | 178 | | |
163 | 179 | | |
| |||
0 commit comments