mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-07 18:47:52 +02:00
* fixed pushing of words in intel assembler (indirectly related to
wrong bug report 7808) git-svn-id: trunk@6274 -
This commit is contained in:
parent
b16b9d5251
commit
1a32e4fdf5
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -7980,6 +7980,7 @@ tests/webtbs/tw7719.pp svneol=native#text/plain
|
||||
tests/webtbs/tw7756.pp svneol=native#text/plain
|
||||
tests/webtbs/tw7803.pp svneol=native#text/plain
|
||||
tests/webtbs/tw7806.pp svneol=native#text/plain
|
||||
tests/webtbs/tw7808.pp svneol=native#text/plain
|
||||
tests/webtbs/tw7817a.pp svneol=native#text/plain
|
||||
tests/webtbs/tw7817b.pp svneol=native#text/plain
|
||||
tests/webtbs/tw7847.pp svneol=native#text/plain
|
||||
|
@ -1972,6 +1972,10 @@ Unit Rax86int;
|
||||
if instr.operands[i].opr.typ=OPR_NONE then
|
||||
Message(asmr_e_syntax_error);
|
||||
end;
|
||||
{ e.g. for "push dword 1", "push word 6" }
|
||||
if (instr.ops=1) and
|
||||
(instr.operands[1].typesize<>0) then
|
||||
instr.operands[1].setsize(instr.operands[1].typesize,false);
|
||||
end;
|
||||
|
||||
|
||||
|
18
tests/webtbs/tw7808.pp
Normal file
18
tests/webtbs/tw7808.pp
Normal file
@ -0,0 +1,18 @@
|
||||
{ %cpu=i386 }
|
||||
{ %opt=-Sew }
|
||||
|
||||
{$mode delphi}
|
||||
|
||||
procedure test(l: longint); stdcall;
|
||||
begin
|
||||
if l<>longint($deadbeef) then
|
||||
halt(1);
|
||||
end;
|
||||
|
||||
begin
|
||||
asm
|
||||
push word $dead
|
||||
push word $beef
|
||||
call test
|
||||
end;
|
||||
end.
|
Loading…
Reference in New Issue
Block a user