* i386*: call and jmp read their first operand

* cgcal: deallocate hlper register only after call statement (fixes bug
    with "procedure of object" and optimizer reported to bugrep on
    2001/08/30) ('merged')
This commit is contained in:
Jonas Maebe 2001-09-01 23:02:30 +00:00
parent 181529df97
commit 8b3905de23
3 changed files with 14 additions and 8 deletions

View File

@ -178,7 +178,7 @@ rm32,imm \321\300\2\x0F\xBA\205\25 386,SB
[CALL,call]
; don't know value of any register
(Ch_All, Ch_None, Ch_None)
(Ch_ROp1, Ch_All, Ch_None)
imm \322\1\xE8\64 8086
imm|near \322\1\xE8\64 8086
imm|far \322\1\x9A\34\37 8086,ND
@ -965,7 +965,7 @@ imm \320\1\xE3\50 8086
imm \321\1\xE3\50 386
[JMP,jmpX]
(Ch_None, Ch_None, Ch_None)
(Ch_ROp1, Ch_None, Ch_None)
imm|short \1\xEB\50 8086
imm \322\1\xE9\64 8086,PASS2
imm|near \322\1\xE9\64 8086,ND,PASS2
@ -1058,7 +1058,7 @@ reg32,mem \321\301\2\x0F\xB5\110 386
mem \300\2\x0F\x01\203 286,PRIV
[LJMP,ljmp]
(Ch_None, Ch_None, Ch_None)
(Ch_ROp1, Ch_None, Ch_None)
mem|far \322\300\1\xFF\205 8086
mem16|far \320\300\1\xFF\205 8086
mem32|far \321\300\1\xFF\205 386

View File

@ -17,7 +17,7 @@
(Ch: (Ch_Mop2, Ch_Rop1, Ch_WFlags)),
(Ch: (Ch_Mop2, Ch_Rop1, Ch_WFlags)),
(Ch: (Ch_Mop2, Ch_Rop1, Ch_WFlags)),
(Ch: (Ch_All, Ch_None, Ch_None)),
(Ch: (Ch_ROp1, Ch_All, Ch_None)),
(Ch: (Ch_MEAX, Ch_None, Ch_None)),
(Ch: (Ch_MEAX, Ch_WEDX, Ch_None)),
(Ch: (Ch_WFlags, Ch_None, Ch_None)),
@ -162,7 +162,7 @@
(Ch: (Ch_All, Ch_None, Ch_None)),
(Ch: (Ch_RECX, Ch_None, Ch_None)),
(Ch: (Ch_RECX, Ch_None, Ch_None)),
(Ch: (Ch_None, Ch_None, Ch_None)),
(Ch: (Ch_ROp1, Ch_None, Ch_None)),
(Ch: (Ch_WEAX, Ch_RFlags, Ch_None)),
(Ch: (Ch_Wop2, Ch_None, Ch_None)),
(Ch: (Ch_All, Ch_None, Ch_None)),
@ -174,7 +174,7 @@
(Ch: (Ch_None, Ch_None, Ch_None)),
(Ch: (Ch_Wop2, Ch_Rop1, Ch_None)),
(Ch: (Ch_None, Ch_None, Ch_None)),
(Ch: (Ch_None, Ch_None, Ch_None)),
(Ch: (Ch_ROp1, Ch_None, Ch_None)),
(Ch: (Ch_None, Ch_None, Ch_None)),
(Ch: (Ch_None, Ch_None, Ch_None)),
(Ch: (Ch_All, Ch_None, Ch_None)),

View File

@ -1038,8 +1038,8 @@ implementation
emit_ref(A_CALL,S_NO,newreference(right.location.reference))
else
begin
ungetregister32(hregister);
emit_reg(A_CALL,S_NO,hregister);
ungetregister32(hregister);
end;
del_reference(right.location.reference);
@ -1584,7 +1584,13 @@ begin
end.
{
$Log$
Revision 1.31 2001-08-29 12:18:08 jonas
Revision 1.32 2001-09-01 23:02:30 jonas
* i386*: call and jmp read their first operand
* cgcal: deallocate hlper register only after call statement (fixes bug
with "procedure of object" and optimizer reported to bugrep on
2001/08/30) ('merged')
Revision 1.31 2001/08/29 12:18:08 jonas
+ new createinternres() constructor for tcallnode to support setting a
custom resulttype
* compilerproc typeconversions now set the resulttype from the type