0CodErr
member
Posts
201
Threads
37
Location
Unknown
Post #1814
2015-03-02 10:17:28 UTC
Maybe it would be useful to save flags by this way:
using flags {
}
function MyFunction() : sysword {
uses flags;
}
And it can be replaced with
pushf
//......
popf
Colin
admin
Posts
928
Threads
49
Location
Bulgaria
Post #1825
2015-03-10 12:58:25 UTC
This is added for next release.
0CodErr
member
Posts
201
Threads
37
Location
Unknown
Post #1849
2016-05-03 11:47:43 UTC
Also this must not be translated:
if (AF == TRUE){}
if (DF == TRUE){}
if (TF == TRUE){}
if (AF == FALSE){}
if (DF == FALSE){}
if (TF == FALSE){}
if (AF <> TRUE){}
if (DF <> TRUE){}
if (TF <> TRUE){}
if (AF <> FALSE){}
if (DF <> FALSE){}
if (TF <> FALSE){}
But currently result is
00000000 7400 jz 0x2
00000002 7400 jz 0x4
00000004 7400 jz 0x6
00000006 7500 jnz 0x8
00000008 7500 jnz 0xa
0000000A 7500 jnz 0xc
0000000C 7500 jnz 0xe
0000000E 7500 jnz 0x10
00000010 7500 jnz 0x12
00000012 7400 jz 0x14
00000014 7400 jz 0x16
00000016 7400 jz 0x18
0CodErr
member
Posts
201
Threads
37
Location
Unknown
Post #1853
2016-05-03 18:15:17 UTC
Currently
function test() {
uses flags;
}
produces
00000000 E800000000 call dword 0x5
00000005 55 push ebp
00000006 8BEC mov ebp,esp
00000008 669C pushfw
0000000A 669D popfw
0000000C 8BE5 mov esp,ebp
0000000E 5D pop ebp
0000000F C3 ret
Is it possible to do 'pushfd \popfd ' instead of 'pushfw \popfw '?
Also here
function test() {
using flags{
}
}
error occured
Unexpected ident flags in [using]