notaz.gp2x.de
/
ia32rtools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
translate: fcom and more
[ia32rtools.git]
/
tests
/
x87.expect.c
diff --git
a/tests/x87.expect.c
b/tests/x87.expect.c
index
bec8c96
..
25223ee
100644
(file)
--- a/
tests/x87.expect.c
+++ b/
tests/x87.expect.c
@@
-1,10
+1,12
@@
int sub_test(int a1, int a2)
{
int sub_test(int a1, int a2)
{
- union { u32 d[8]; u8 b[32]; double q[4]; } sf;
+ union { u32 d[8]; u
16 w[16]; u
8 b[32]; double q[4]; } sf;
u32 eax;
u32 edx;
double f_st0;
double f_st1;
u32 eax;
u32 edx;
double f_st0;
double f_st1;
+ u16 f_sw;
+ u32 cond_z;
f_st0 = (double)(s32)sf.d[0]; // var_20 fild
f_st0 /= (double)(s32)a1; // arg_0
f_st0 = (double)(s32)sf.d[0]; // var_20 fild
f_st0 /= (double)(s32)a1; // arg_0
@@
-12,6
+14,12
@@
int sub_test(int a1, int a2)
f_st1 = f_st0; f_st0 = (double)(s32)sf.d[0]; // var_20 fild
f_st1 /= f_st0;
f_st0 = f_st1 + f_st0;
f_st1 = f_st0; f_st0 = (double)(s32)sf.d[0]; // var_20 fild
f_st1 /= f_st0;
f_st0 = f_st1 + f_st0;
+ f_sw = f_st0 <= *((double *)(u32)&sf.q[1]) ? 0x4100 : 0; // var_18 z_chk_det
+ eax = 0;
+ LOWORD(eax) = f_sw;
+ cond_z = ((u8)((u8)(eax >> 8) & 0x41) == 0);
+ eax = 0;
+ LOBYTE(eax) = (cond_z);
f_st1 = f_st0; f_st0 = 1.0;
f_st0 = *((double *)(u32)&sf.q[1]) / f_st0; // var_18
{ double t = f_st0; f_st0 = f_st1; f_st1 = t; } // fxch
f_st1 = f_st0; f_st0 = 1.0;
f_st0 = *((double *)(u32)&sf.q[1]) / f_st0; // var_18
{ double t = f_st0; f_st0 = f_st1; f_st1 = t; } // fxch
@@
-20,8
+28,8
@@
int sub_test(int a1, int a2)
f_st1 = f_st0; // fld st
f_st0 = f_st1 * log2(f_st0);
f_st1 = f_st0; // fld st
f_st1 = f_st0; // fld st
f_st0 = f_st1 * log2(f_st0);
f_st1 = f_st0; // fld st
-
*((double *)(u32)&sf.q[1]) = f_st0; f_st0 = f_st1; // var_18 f
st
- *((
float *)(u32)&sf.d[0]) = f_st0; // var_20
fst
+
sf.d[0] = (s32)f_st0; f_st0 = f_st1; // var_20 fi
st
+ *((
double *)(u32)&sf.q[1]) = f_st0; // var_18
fst
eax = (s32)f_st0; // ftol
return eax;
}
eax = (s32)f_st0; // ftol
return eax;
}