Commit 6132474c authored by Gregg Mattinson's avatar Gregg Mattinson Committed by Alexandre Julliard

Fixed __builtin_return_address.

parent e1db8bd0
...@@ -1142,9 +1142,15 @@ typedef CONTEXT *PCONTEXT; ...@@ -1142,9 +1142,15 @@ typedef CONTEXT *PCONTEXT;
static DWORD __builtin_return_address(int p_iDepth) static DWORD __builtin_return_address(int p_iDepth)
{ {
asm("ta 3"); asm("ta 3");
asm("tst %i0");
asm("be End");
asm("mov %fp, %l0"); asm("mov %fp, %l0");
while (p_iDepth--) asm("Start:");
asm("ld [%l0+56], %l0"); asm("sub %i0, 1, %i0");
asm("tst %i0");
asm("bne Start");
asm("ld [%l0+56], %l0");
asm("End:");
asm("ld [%l0+60], %i0"); asm("ld [%l0+60], %i0");
} }
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment