fix stack trace crash, see #39492

This commit is contained in:
Benito van der Zander 2022-06-07 19:44:31 +00:00 committed by florian
parent dd13b46088
commit 7704fe9319

View File

@ -165,10 +165,7 @@ procedure fpc_cpuinit;
function get_caller_addr(framebp:pointer;addr:pointer=nil):pointer;assembler; nostackframe;
asm
cbz x0, .Lcaller_addr_invalid
ldur x0, [x0]
{$ifndef cpullvm}
cbz x0, .Lcaller_addr_invalid
{$else cpullvm}
{$ifdef cpullvm}
movn w1, #0
cmp x0, x1
csel x0, xzr, x0, ls
@ -178,7 +175,6 @@ function get_caller_addr(framebp:pointer;addr:pointer=nil):pointer;assembler; no
.Lcaller_addr_invalid:
end;
{$define FPC_SYSTEM_HAS_GET_CALLER_FRAME}
function get_caller_frame(framebp:pointer;addr:pointer=nil):pointer;assembler; nostackframe;
asm