gas/
[external/binutils.git] / gas / testsuite / gas / i386 / intelbad.s
1         .intel_syntax noprefix
2         .text
3 start:
4         add     eax, byte ptr [eax]
5         add     eax, qword ptr [eax]
6         add     [eax], 1
7         add     qword ptr [eax], 1
8         addpd   xmm0, dword ptr [eax]
9         addpd   xmm0, qword ptr [eax]
10         addpd   xmm0, tbyte ptr [eax]
11         addps   xmm0, dword ptr [eax]
12         addps   xmm0, qword ptr [eax]
13         addps   xmm0, tbyte ptr [eax]
14         addsd   xmm0, dword ptr [eax]
15         addsd   xmm0, tbyte ptr [eax]
16         addsd   xmm0, xmmword ptr [eax]
17         addss   xmm0, qword ptr [eax]
18         addss   xmm0, tbyte ptr [eax]
19         addss   xmm0, xmmword ptr [eax]
20         call    byte ptr [eax]
21         call    qword ptr [eax]
22         call    tbyte ptr [eax]
23         call    xword ptr [eax]
24         cmps    [esi], es:[edi]
25         cmps    dword ptr [esi], word ptr es:[edi]
26         cmpxchg8b dword ptr [eax]
27         fadd    [eax]
28         fadd    word ptr [eax]
29         fadd    tbyte ptr [eax]
30         fbld    byte ptr [eax]
31         fbld    word ptr [eax]
32         fbstp   dword ptr [eax]
33         fbstp   qword ptr [eax]
34         fiadd   [eax]
35         fiadd   byte ptr [eax]
36         fild    [eax]
37         fild    byte ptr [eax]
38         fild    tbyte ptr [eax]
39         fist    [eax]
40         fist    byte ptr [eax]
41         fist    qword ptr [eax]
42         fistp   [eax]
43         fistp   byte ptr [eax]
44         fisttp  [eax]
45         fisttp  byte ptr [eax]
46         fld     [eax]
47         fld     word ptr [eax]
48         fldcw   dword ptr [eax]
49         fst     [eax]
50         fst     word ptr [eax]
51         fst     tbyte ptr [eax]
52         fstp    [eax]
53         fstp    word ptr [eax]
54         ins     es:[edi], dx
55         lds     ax, word ptr [eax]
56         lds     eax, dword ptr [eax]
57         lods    [esi]
58         movs    es:[edi], [esi]
59         movs    dword ptr es:[edi], word ptr [esi]
60         movsx   eax, [eax]
61         movsx   eax, dword ptr [eax]
62         outs    dx, [esi]
63         paddb   mm0, dword ptr [eax]
64         paddb   mm0, xmmword ptr [eax]
65         paddb   xmm0, dword ptr [eax]
66         paddb   xmm0, qword ptr [eax]
67         pinsrw  mm0, byte ptr [eax], 3
68         pinsrw  mm0, dword ptr [eax], 3
69         pinsrw  mm0, qword ptr [eax], 3
70         pinsrw  xmm0, dword ptr [eax], 7
71         pinsrw  xmm0, qword ptr [eax], 7
72         pinsrw  xmm0, xmmword ptr [eax], 7
73         push    byte ptr [eax]
74         push    qword ptr [eax]
75         scas    es:[edi]
76 #XXX?   shl     eax
77         stos    es:[edi]
78         xlat    word ptr [ebx]
79 #XXX?   xlatb   [ebx]
80
81         # expressions
82 #XXX?   push    ~ 1
83 #XXX?   push    1 % 1
84 #XXX?   push    1 << 1
85 #XXX?   push    1 >> 1
86 #XXX?   push    1 & 1
87 #XXX?   push    1 ^ 1
88 #XXX?   push    1 | 1
89         push    1 1
90         push    1 +
91         push    1 * * 1
92
93         # memory references
94         mov     eax, [ecx*3]
95         mov     eax, [3*ecx]
96         mov     eax, [-1*ecx + 1]
97         mov     eax, [esp + esp]
98         mov     eax, [eax - 1*ecx + 1]
99         mov     eax, [(eax-1) * (eax-1)]
100         mov     eax, [eax-1 xor eax-1]
101         mov     eax, [(eax-1) xor (eax-1)]
102         mov     eax, [not eax + 1]
103         mov     eax, [ecx*2 + edx*4]
104         mov     eax, [2*ecx + 4*edx]
105         mov     eax, [eax]1[ecx]                # ugly diag
106         mov     eax, [eax][ecx]1                # ugly diag
107         mov     eax, eax[ecx]                   # ugly diag
108         mov     eax, es[ecx]
109         mov     eax, cr0[ecx]
110         mov     eax, [eax]ecx
111         mov     eax, [eax]+ecx
112         mov     eax, [eax]+ecx*2
113         mov     eax, [eax]+2*ecx
114         mov     eax, [[eax]ecx]
115         mov     eax, eax:[ecx]
116         lea     eax, [bx+si*1]
117         lea     eax, [bp+si*2]
118         lea     eax, [bx+di*4]
119         lea     eax, [bp+di*8]
120         lea     eax, [bx+1*si]
121         lea     eax, [bp+2*si]
122         lea     eax, [bx+4*di]
123         lea     eax, [bp+8*di]
124         mov     eax, [ah]
125         mov     eax, [ax]
126         mov     eax, [eax+bx]
127         mov     eax, offset [1*eax]
128         mov     eax, offset 1*eax
129         mov     eax, offset x[eax]              # ugly diag
130         mov     eax, offset [x][eax]            # ugly diag
131         mov     eax, flat x
132         mov     eax, flat [x]
133         mov     eax, es:eax
134
135         mov     eax, offset [eax]
136         mov     eax, offset eax
137         mov     eax, offset offset eax
138         mov     eax, es:ss:[eax]
139         mov     eax, es:[eax]+ss:[eax]
140
141         mov     eax, 3:5
142         call    3:[5]