output: macho -- Add support for N_PEXT in macho output
[nasm.git] / test / mpx.asm
blob4e98156823ecaeeb770fe07c6f1451a8421e3794
1 ;Testname=mpx; Arguments=-felf -ompx.o -O0; Files=stdout stderr mpx.o
2 BITS 32
4 bndmk bnd1, [eax]
5 bndmk bnd1, [0x399]
6 bndmk bnd1, [ecx+0x3]
7 bndmk bnd1, [eax+ecx]
8 bndmk bnd1, [ecx*1]
9 bndmk bnd1, [edx+1*eax+0x3]
11 ; bndmov
12 bndmov bnd1, [eax]
13 bndmov bnd1, [0x399]
14 bndmov bnd1, [ecx+0x3]
15 bndmov bnd1, [eax+ecx]
16 bndmov bnd1, [ecx*1]
17 bndmov bnd1, [edx+1*eax+0x3]
18 bndmov bnd0, bnd1
20 bndmov [eax], bnd1
21 bndmov [0x399], bnd1
22 bndmov [ecx+0x3], bnd1
23 bndmov [eax+ecx], bnd1
24 bndmov [ecx*1], bnd1
25 bndmov [edx+1*eax+0x3], bnd1
26 bndmov bnd1, bnd0
28 ; bndcl
29 bndcl bnd1, [eax]
30 bndcl bnd1, ecx
31 bndcl bnd1, [0x399]
32 bndcl bnd1, [ecx+0x3]
33 bndcl bnd1, [eax+ecx]
34 bndcl bnd1, [ecx*1]
35 bndcl bnd1, [edx+1*eax+0x3]
37 ; bndcu
38 bndcu bnd1, [eax]
39 bndcu bnd1, ecx
40 bndcu bnd1, [0x399]
41 bndcu bnd1, [ecx+0x3]
42 bndcu bnd1, [eax+ecx]
43 bndcu bnd1, [ecx*1]
44 bndcu bnd1, [edx+1*eax+0x3]
46 ; bndcn
47 bndcn bnd1, [eax]
48 bndcn bnd1, ecx
49 bndcn bnd1, [0x399]
50 bndcn bnd1, [ecx+0x3]
51 bndcn bnd1, [eax+ecx]
52 bndcn bnd1, [ecx*1]
53 bndcn bnd1, [edx+1*eax+0x3]
55 ; bndstx
56 bndstx [eax+ebx*1+0x3], bnd0
57 bndstx [eax+0x3,ebx], bnd0
58 bndstx [eax+0x3], bnd0, ebx
59 bndstx [eax+0x3], ebx, bnd0
60 bndstx [ecx*1], bnd2
61 bndstx [,ecx*1], bnd2
62 bndstx [0,ecx*1], bnd2
63 bndstx [0], bnd2, ecx
64 bndstx [0], ecx, bnd2
65 bndstx [edx+0x399], bnd3
66 bndstx [1*ebx+3], bnd2
67 bndstx [3,1*ebx], bnd2
68 bndstx [3], ebx, bnd2
69 bndstx [edx], bnd1
71 ; bndldx
72 bndldx bnd0, [eax+ebx*1+0x3]
73 bndldx bnd2, [ebx+edx+3]
74 bndldx bnd2, [ecx*1]
75 bndldx bnd3, [edx+0x399]
76 bndldx bnd2, [1*ebx+3]
77 bndldx bnd2, [3], ebx
78 bndldx bnd1, [edx]
80 ; bnd
81 bnd ret
82 bnd call foo
83 bnd jmp foo ; when it becomes a Jb form - short jmp (eb),
84 ; bnd prefix is silently dropped
85 bnd jmp near 0 ; near jmp (opcode e9)
86 ; bnd jmp short 0 ; explicit short jmp (opcode eb) : error
87 bnd jno foo
89 foo: bnd ret