1 |
gbeauche |
1.4 |
#define DEFINE_X86_MACRO(name, value) \ |
2 |
gbeauche |
1.3 |
asm(".local " #name "\n\t" #name " = " #value) |
3 |
|
|
|
4 |
gbeauche |
1.4 |
DEFINE_X86_MACRO(BSUN, 0x00008000); |
5 |
|
|
DEFINE_X86_MACRO(SNAN, 0x00004000); |
6 |
|
|
DEFINE_X86_MACRO(OPERR, 0x00002000); |
7 |
|
|
DEFINE_X86_MACRO(OVFL, 0x00001000); |
8 |
|
|
DEFINE_X86_MACRO(UNFL, 0x00000800); |
9 |
|
|
DEFINE_X86_MACRO(DZ, 0x00000400); |
10 |
|
|
DEFINE_X86_MACRO(INEX2, 0x00000200); |
11 |
|
|
DEFINE_X86_MACRO(INEX1, 0x00000100); |
12 |
|
|
DEFINE_X86_MACRO(ACCR_IOP, 0x80); |
13 |
|
|
DEFINE_X86_MACRO(ACCR_OVFL, 0x40); |
14 |
|
|
DEFINE_X86_MACRO(ACCR_UNFL, 0x20); |
15 |
|
|
DEFINE_X86_MACRO(ACCR_DZ, 0x10); |
16 |
|
|
DEFINE_X86_MACRO(ACCR_INEX, 0x08); |
17 |
|
|
DEFINE_X86_MACRO(ROUND_CONTROL_MASK, 0x30); |
18 |
|
|
DEFINE_X86_MACRO(ROUND_TO_NEAREST, 0); |
19 |
|
|
DEFINE_X86_MACRO(ROUND_TO_ZERO, 0x10); |
20 |
|
|
DEFINE_X86_MACRO(ROUND_TO_NEGATIVE_INFINITY, 0x20); |
21 |
|
|
DEFINE_X86_MACRO(ROUND_TO_POSITIVE_INFINITY, 0x30); |
22 |
|
|
DEFINE_X86_MACRO(PRECISION_CONTROL_MASK, 0xC0); |
23 |
|
|
DEFINE_X86_MACRO(PRECISION_CONTROL_EXTENDED, 0); |
24 |
|
|
DEFINE_X86_MACRO(PRECISION_CONTROL_DOUBLE, 0x80); |
25 |
|
|
DEFINE_X86_MACRO(PRECISION_CONTROL_SINGLE, 0x40); |
26 |
|
|
DEFINE_X86_MACRO(PRECISION_CONTROL_UNDEFINED, 0xC0); |
27 |
|
|
DEFINE_X86_MACRO(CW_RESET, 0x0040); |
28 |
|
|
DEFINE_X86_MACRO(CW_FINIT, 0x037F); |
29 |
|
|
DEFINE_X86_MACRO(SW_RESET, 0x0000); |
30 |
|
|
DEFINE_X86_MACRO(SW_FINIT, 0x0000); |
31 |
|
|
DEFINE_X86_MACRO(TW_RESET, 0x5555); |
32 |
|
|
DEFINE_X86_MACRO(TW_FINIT, 0x0FFF); |
33 |
|
|
DEFINE_X86_MACRO(CW_X, 0x1000); |
34 |
|
|
DEFINE_X86_MACRO(CW_RC_ZERO, 0x0C00); |
35 |
|
|
DEFINE_X86_MACRO(CW_RC_UP, 0x0800); |
36 |
|
|
DEFINE_X86_MACRO(CW_RC_DOWN, 0x0400); |
37 |
|
|
DEFINE_X86_MACRO(CW_RC_NEAR, 0x0000); |
38 |
|
|
DEFINE_X86_MACRO(CW_PC_EXTENDED, 0x0300); |
39 |
|
|
DEFINE_X86_MACRO(CW_PC_DOUBLE, 0x0200); |
40 |
|
|
DEFINE_X86_MACRO(CW_PC_RESERVED, 0x0100); |
41 |
|
|
DEFINE_X86_MACRO(CW_PC_SINGLE, 0x0000); |
42 |
|
|
DEFINE_X86_MACRO(CW_PM, 0x0020); |
43 |
|
|
DEFINE_X86_MACRO(CW_UM, 0x0010); |
44 |
|
|
DEFINE_X86_MACRO(CW_OM, 0x0008); |
45 |
|
|
DEFINE_X86_MACRO(CW_ZM, 0x0004); |
46 |
|
|
DEFINE_X86_MACRO(CW_DM, 0x0002); |
47 |
|
|
DEFINE_X86_MACRO(CW_IM, 0x0001); |
48 |
|
|
DEFINE_X86_MACRO(SW_B, 0x8000); |
49 |
|
|
DEFINE_X86_MACRO(SW_C3, 0x4000); |
50 |
|
|
DEFINE_X86_MACRO(SW_TOP_7, 0x3800); |
51 |
|
|
DEFINE_X86_MACRO(SW_TOP_6, 0x3000); |
52 |
|
|
DEFINE_X86_MACRO(SW_TOP_5, 0x2800); |
53 |
|
|
DEFINE_X86_MACRO(SW_TOP_4, 0x2000); |
54 |
|
|
DEFINE_X86_MACRO(SW_TOP_3, 0x1800); |
55 |
|
|
DEFINE_X86_MACRO(SW_TOP_2, 0x1000); |
56 |
|
|
DEFINE_X86_MACRO(SW_TOP_1, 0x0800); |
57 |
|
|
DEFINE_X86_MACRO(SW_TOP_0, 0x0000); |
58 |
|
|
DEFINE_X86_MACRO(SW_C2, 0x0400); |
59 |
|
|
DEFINE_X86_MACRO(SW_C1, 0x0200); |
60 |
|
|
DEFINE_X86_MACRO(SW_C0, 0x0100); |
61 |
|
|
DEFINE_X86_MACRO(SW_ES, 0x0080); |
62 |
|
|
DEFINE_X86_MACRO(SW_SF, 0x0040); |
63 |
|
|
DEFINE_X86_MACRO(SW_PE, 0x0020); |
64 |
|
|
DEFINE_X86_MACRO(SW_UE, 0x0010); |
65 |
|
|
DEFINE_X86_MACRO(SW_OE, 0x0008); |
66 |
|
|
DEFINE_X86_MACRO(SW_ZE, 0x0004); |
67 |
|
|
DEFINE_X86_MACRO(SW_DE, 0x0002); |
68 |
|
|
DEFINE_X86_MACRO(SW_IE, 0x0001); |
69 |
|
|
DEFINE_X86_MACRO(X86_ROUNDING_MODE, 0x0C00); |
70 |
|
|
DEFINE_X86_MACRO(X86_ROUNDING_PRECISION, 0x0300); |
71 |
gbeauche |
1.3 |
|
72 |
gbeauche |
1.4 |
#undef DEFINE_X86_MACRO |