mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-20 19:29:26 +02:00
+ fix(?) stack return address with an ugly hack...
git-svn-id: trunk@9047 -
This commit is contained in:
parent
0a3591a2a5
commit
12bcb539e6
@ -1339,12 +1339,15 @@ unit cgcpu;
|
||||
begin
|
||||
if not nostackframe then
|
||||
begin
|
||||
writeln(current_procinfo.maxpushedparasize);
|
||||
localsize := current_procinfo.calc_stackframe_size;
|
||||
{$ifdef DEBUG_CHARLIE}
|
||||
writeln('proc exit with stackframe, size:',localsize,' parasize:',parasize);
|
||||
{$endif DEBUG_CHARLIE}
|
||||
list.concat(taicpu.op_reg(A_UNLK,S_NO,NR_FRAME_POINTER_REG));
|
||||
parasize := parasize - 8; { FIXME: ugly hack to correct the value...
|
||||
but the real fun is, that works for now.
|
||||
i wonder where the extra 8 size comes from.
|
||||
... maybe return address + framepointer size? (KB) }
|
||||
if (parasize<>0) then
|
||||
begin
|
||||
{ only 68020+ supports RTD, so this needs another code path
|
||||
|
Loading…
Reference in New Issue
Block a user