aboutsummaryrefslogtreecommitdiff
path: root/gas/testsuite
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@novell.com>2009-04-20 06:31:50 +0000
committerJan Beulich <jbeulich@novell.com>2009-04-20 06:31:50 +0000
commitee86248ceef0286d7b2b074a88718176ebd6ada6 (patch)
treeee530c29f83602fa33bbeea24f955312896842f0 /gas/testsuite
parentfcaed75e5235a983da6edd87da4eadcf27b99fb7 (diff)
downloadgdb-ee86248ceef0286d7b2b074a88718176ebd6ada6.zip
gdb-ee86248ceef0286d7b2b074a88718176ebd6ada6.tar.gz
gdb-ee86248ceef0286d7b2b074a88718176ebd6ada6.tar.bz2
gas/
2009-04-20 Jan Beulich <jbeulich@novell.com> * Makefile.am: Add explicit dependency of tc-i386.o on tc-i386-intel.c. * Makefile.in: Likewise. * config/tc-i386.c (i386_finalize_immediate): Declare, broken out from i386_immediate. (i386_immediate): Slightly re-arrange, call i386_finalize_immediate. (i386_finalize_displacement): Declare, broken out from i386_displacement. (i386_displacement): Slightly re-arrange, call i386_finalize_displacement. (i386_intel_simplify, i386_intel_parse_name): Declare. (this_operand): Initialize to -1. (set_intel_syntax): Set expression rank for O_full_ptr. (md_assemble): Set this_operand back to -1 after parsing operands. (x86_cons): Negate intel_syntax to indicate state. Call i386_intel_simplify. (md_operand): Convert if to switch. Handle '[' for Intel syntax. (i386_intel_operand): Delete, including all helper functions and data. * config/tc-i386-intel.c: New file, all new code. * config/tc-i386.h (i386_operator): Declare. (md_operator): Define to i386_operator. (i386_need_index_operator): Declare. (md_need_index_operator): Define to i386_need_index_operator. (O_full_ptr): Define. gas/testsuite/ 2009-04-20 Jan Beulich <jbeulich@novell.com> * gas/i386/equ.s: Adjust. * gas/i386/equ.d: Remove reference to equ.e. * gas/i386/equ.e: Delete. * gas/i386/intel-expr.s: New. * gas/i386/intel-expr.d: New. * gas/i386/i386.exp: Run new test. * gas/i386/intel.s: Adjust. * gas/i386/intel.e: Remove no longer valid warning messages. * gas/i386/intel16.s: Adjust. * gas/i386/intel16.d: Remove reference to intel16.e. * gas/i386/intel16.e: Delete. * gas/i386/intelbad.s: Add more tests. * gas/i386/intelbad.l: Adjust. * gas/i386/intelok.s: Remove now unneeded equates. Add more tests. * gas/i386/intelok.d: Remove reference to intelok.e. Adjust. * gas/i386/intelok.e: Delete. * gas/i386/x86_64.s: Adjust. * gas/i386/x86_64.d: Remove reference to x86_64.e. * gas/i386/x86_64.e: Delete.
Diffstat (limited to 'gas/testsuite')
-rw-r--r--gas/testsuite/ChangeLog23
-rw-r--r--gas/testsuite/gas/i386/equ.d1
-rw-r--r--gas/testsuite/gas/i386/equ.e2
-rw-r--r--gas/testsuite/gas/i386/equ.s2
-rw-r--r--gas/testsuite/gas/i386/i386.exp1
-rw-r--r--gas/testsuite/gas/i386/intel.e6
-rw-r--r--gas/testsuite/gas/i386/intel.s24
-rw-r--r--gas/testsuite/gas/i386/intel16.d1
-rw-r--r--gas/testsuite/gas/i386/intel16.e7
-rw-r--r--gas/testsuite/gas/i386/intel16.s12
-rw-r--r--gas/testsuite/gas/i386/intelbad.l23
-rw-r--r--gas/testsuite/gas/i386/intelbad.s23
-rw-r--r--gas/testsuite/gas/i386/intelok.d74
-rw-r--r--gas/testsuite/gas/i386/intelok.e8
-rw-r--r--gas/testsuite/gas/i386/intelok.s53
-rw-r--r--gas/testsuite/gas/i386/x86_64.d1
-rw-r--r--gas/testsuite/gas/i386/x86_64.e9
-rw-r--r--gas/testsuite/gas/i386/x86_64.s16
18 files changed, 167 insertions, 119 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 66a68b9..ad97bc9 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,26 @@
+2009-04-20 Jan Beulich <jbeulich@novell.com>
+
+ * gas/i386/equ.s: Adjust.
+ * gas/i386/equ.d: Remove reference to equ.e.
+ * gas/i386/equ.e: Delete.
+ * gas/i386/intel-expr.s: New.
+ * gas/i386/intel-expr.d: New.
+ * gas/i386/i386.exp: Run new test.
+ * gas/i386/intel.s: Adjust.
+ * gas/i386/intel.e: Remove no longer valid warning messages.
+ * gas/i386/intel16.s: Adjust.
+ * gas/i386/intel16.d: Remove reference to intel16.e.
+ * gas/i386/intel16.e: Delete.
+ * gas/i386/intelbad.s: Add more tests.
+ * gas/i386/intelbad.l: Adjust.
+ * gas/i386/intelok.s: Remove now unneeded equates. Add more
+ tests.
+ * gas/i386/intelok.d: Remove reference to intelok.e. Adjust.
+ * gas/i386/intelok.e: Delete.
+ * gas/i386/x86_64.s: Adjust.
+ * gas/i386/x86_64.d: Remove reference to x86_64.e.
+ * gas/i386/x86_64.e: Delete.
+
2009-04-16 Alan Modra <amodra@bigpond.net.au>
* gas/all/gas.exp: Disable assign and assign-ok tests on blackfin.
diff --git a/gas/testsuite/gas/i386/equ.d b/gas/testsuite/gas/i386/equ.d
index f023abf..c23616f 100644
--- a/gas/testsuite/gas/i386/equ.d
+++ b/gas/testsuite/gas/i386/equ.d
@@ -1,6 +1,5 @@
#objdump: -drw
#name: i386 equates
-#stderr: equ.e
.*: +file format .*
diff --git a/gas/testsuite/gas/i386/equ.e b/gas/testsuite/gas/i386/equ.e
deleted file mode 100644
index 8a485d1..0000000
--- a/gas/testsuite/gas/i386/equ.e
+++ /dev/null
@@ -1,2 +0,0 @@
-.*: Assembler messages:
-.*:30: Warning: Treating .* as memory reference
diff --git a/gas/testsuite/gas/i386/equ.s b/gas/testsuite/gas/i386/equ.s
index 1b7a796..94ec81d 100644
--- a/gas/testsuite/gas/i386/equ.s
+++ b/gas/testsuite/gas/i386/equ.s
@@ -27,7 +27,7 @@ _start:
.equ r, -2
.equ s, -2
mov eax, r
- mov eax, [r]
+ mov eax, FLAT:[r]
.equ r, xtrn
mov eax, offset r
mov eax, [r]
diff --git a/gas/testsuite/gas/i386/i386.exp b/gas/testsuite/gas/i386/i386.exp
index 09d773a..5352bac 100644
--- a/gas/testsuite/gas/i386/i386.exp
+++ b/gas/testsuite/gas/i386/i386.exp
@@ -197,6 +197,7 @@ if [expr ([istarget "i*86-*-*"] || [istarget "x86_64-*-*"]) && [gas_32_check]]
}
if [expr [istarget "i*86-*-*"] || [istarget "x86_64-*-*"]] then {
+ run_dump_test "intel-expr"
run_dump_test "string-ok"
run_list_test "string-bad" ""
}
diff --git a/gas/testsuite/gas/i386/intel.e b/gas/testsuite/gas/i386/intel.e
index 6f7b365..9c0e76c 100644
--- a/gas/testsuite/gas/i386/intel.e
+++ b/gas/testsuite/gas/i386/intel.e
@@ -1,10 +1,4 @@
.*: Assembler messages:
-.*:154: Warning: Treating `\[0x90909090\]' as memory reference
-.*:155: Warning: Treating `\[0x90909090\]' as memory reference
-.*:156: Warning: Treating `\[0x90909090\]' as memory reference
-.*:157: Warning: Treating `\[0x90909090\]' as memory reference
-.*:494: Warning: Treating `\[0x90909090\]' as memory reference
-.*:495: Warning: Treating `\[0x90909090\]' as memory reference
.*:635: Warning: translating to `faddp'
.*:644: Warning: translating to `fdivp'
.*:653: Warning: translating to `fdivp st\(3\),st'
diff --git a/gas/testsuite/gas/i386/intel.s b/gas/testsuite/gas/i386/intel.s
index 7c247e9..a3a07b3 100644
--- a/gas/testsuite/gas/i386/intel.s
+++ b/gas/testsuite/gas/i386/intel.s
@@ -145,16 +145,16 @@ foo:
xchg edi, eax
cwde
cdq
- call 0x9090,0x90909090
+ call 0x9090:0x90909090
fwait
pushf
popf
sahf
lahf
- mov al, [0x90909090]
- mov eax, [0x90909090]
- mov [0x90909090], al
- mov [0x90909090], eax
+ mov al, FLAT:[0x90909090]
+ mov eax, FLAT:[0x90909090]
+ mov FLAT:[0x90909090], al
+ mov FLAT:[0x90909090], eax
movs byte ptr es:[edi], byte ptr ds:[esi]
movs dword ptr es:[edi], dword ptr ds:[esi]
cmps byte ptr ds:[esi], byte ptr es:[edi]
@@ -226,7 +226,7 @@ foo:
out 0x90, eax
call .+5+0x90909090
jmp .+5+0x90909090
- jmp 0x9090,0x90909090
+ jmp 0x9090:0x90909090
jmp .+2-0x70
in al, dx
in eax, dx
@@ -488,11 +488,11 @@ foo:
xchg di, ax
cbw
cwd
- callw 0x9090,0x9090
+ callw 0x9090:0x9090
pushfw
popfw
- mov ax, [0x90909090]
- mov [0x90909090], ax
+ mov ax, FLAT:[0x90909090]
+ mov FLAT:[0x90909090], ax
movs word ptr es:[edi], word ptr ds:[esi]
cmps word ptr ds:[esi], word ptr es:[edi]
test ax, 0x9090
@@ -525,7 +525,7 @@ foo:
in ax, 0x90
out 0x90, ax
callw .+3+0x9090
- jmpw 0x9090,0x9090
+ jmpw 0x9090:0x9090
in ax, dx
out dx, ax
not word ptr 0x90909090[eax]
@@ -599,7 +599,7 @@ rot5:
mov eax, [ebx*2]
adc BYTE PTR [eax*4+0x90909090], dl
das
- jmp 0x9090,0x90909090
+ jmp 0x9090:0x90909090
movs WORD PTR es:[edi], WORD PTR ds:[esi]
jo .+2-0x70
@@ -617,7 +617,7 @@ rot5:
mov ax, word ptr [ebx+2*eax+(2*(4095+1)*2)]
jmp eax
jmp [eax]
- jmp [bar]
+ jmp FLAT:[bar]
jmp bar
# Check arithmetic operators
diff --git a/gas/testsuite/gas/i386/intel16.d b/gas/testsuite/gas/i386/intel16.d
index e6d0ee2..45bb203 100644
--- a/gas/testsuite/gas/i386/intel16.d
+++ b/gas/testsuite/gas/i386/intel16.d
@@ -1,6 +1,5 @@
#objdump: -dw -mi8086
#name: i386 intel16
-#stderr: intel16.e
.*: +file format .*
diff --git a/gas/testsuite/gas/i386/intel16.e b/gas/testsuite/gas/i386/intel16.e
deleted file mode 100644
index 62da8a7..0000000
--- a/gas/testsuite/gas/i386/intel16.e
+++ /dev/null
@@ -1,7 +0,0 @@
-.*: Assembler messages:
-.*:5: Warning: Treating .word ptr \[0\]. as memory reference
-.*:6: Warning: Treating .byte ptr \[0\]. as memory reference
-.*:7: Warning: Treating .byte ptr \[0\]. as memory reference
-.*:8: Warning: Treating .word ptr \[0\]. as memory reference
-.*:9: Warning: Treating .byte ptr \[0\]. as memory reference
-.*:10: Warning: Treating .byte ptr \[0\]. as memory reference
diff --git a/gas/testsuite/gas/i386/intel16.s b/gas/testsuite/gas/i386/intel16.s
index e27b017..14a9792 100644
--- a/gas/testsuite/gas/i386/intel16.s
+++ b/gas/testsuite/gas/i386/intel16.s
@@ -2,12 +2,12 @@
.code16
.text
- movsx eax,word ptr [0]
- movsx eax,byte ptr [0]
- movsx ax,byte ptr [0]
- movzx eax,word ptr [0]
- movzx eax,byte ptr [0]
- movzx ax,byte ptr [0]
+ movsx eax,word ptr ds:[0]
+ movsx eax,byte ptr ds:[0]
+ movsx ax,byte ptr ds:[0]
+ movzx eax,word ptr ds:[0]
+ movzx eax,byte ptr ds:[0]
+ movzx ax,byte ptr ds:[0]
lea ax, [si+bx]
lea ax, [si+bp]
diff --git a/gas/testsuite/gas/i386/intelbad.l b/gas/testsuite/gas/i386/intelbad.l
index b10a6c4..bdc2645 100644
--- a/gas/testsuite/gas/i386/intelbad.l
+++ b/gas/testsuite/gas/i386/intelbad.l
@@ -76,8 +76,9 @@
.*:79: Error: .*
.*:80: Error: .*
.*:91: Error: .*
-.*:92: Error: .*
+.*:92: (Warning|Error): .*
.*:93: Error: .*
+#...
.*:96: Error: .*
.*:97: Error: .*
.*:98: Error: .*
@@ -99,6 +100,7 @@
.*:114: Error: .*
.*:115: Error: .*
.*:116: Error: .*
+#...
.*:117: Error: .*
.*:119: Error: .*
.*:120: Error: .*
@@ -131,18 +133,23 @@
.*:151: Error: .*
.*:152: Error: .*
.*:153: Error: .*
-#...
.*:154: Error: .*
-#...
.*:155: Error: .*
.*:156: Error: .*
-.*:157: Error: .*
-.*:158: Error: .*
+#XXX? .*:157: Error: .*
+#XXX? .*:158: Error: .*
+.*:159: Error: .*
+#...
.*:160: Error: .*
.*:161: Error: .*
.*:162: Error: .*
-.*:163: Warning: .*
-.*:164: Warning: .*
+.*:163: Error: .*
+.*:164: Error: .*
+.*:165: Error: .*
.*:166: Error: .*
-.*:167: Warning: .*
+#...
.*:167: Error: .*
+.*:168: Error: .*
+.*:169: Error: .*
+.*:170: Error: .*
+.*:172: Error: .*
diff --git a/gas/testsuite/gas/i386/intelbad.s b/gas/testsuite/gas/i386/intelbad.s
index 2489c12..9df2aa2 100644
--- a/gas/testsuite/gas/i386/intelbad.s
+++ b/gas/testsuite/gas/i386/intelbad.s
@@ -149,19 +149,24 @@ start:
mov eax, [ah]
mov eax, [ax]
mov eax, [eax+bx]
+ mov eax, offset [eax]
+ mov eax, offset eax
+ mov eax, offset offset eax
mov eax, offset [1*eax]
mov eax, offset 1*eax
- mov eax, offset x[eax] # ugly diag
- mov eax, offset [x][eax] # ugly diag
+#XXX? mov eax, offset x[eax]
+#XXX? mov eax, offset [x][eax]
mov eax, flat x
mov eax, flat [x]
mov eax, es:eax
-
- mov eax, offset [eax]
- mov eax, offset eax
- mov eax, offset offset eax
- mov eax, es:ss:[eax]
- mov eax, es:[eax]+ss:[eax]
+ mov eax, eax[ebp]
+ movzx eax, 1 ptr [eax]
+ movzx eax, byte word ptr [eax]
+ movzx eax, [byte ptr eax]
+ movzx eax, byte [ptr [eax]]
+ movzx eax, byte ptr [gs:eax]
+ movzx eax, byte gs:ptr [eax]
+ movzx eax, byte ptr 1
+ movzx eax, byte ptr [1]
mov eax, 3:5
- call 3:[5]
diff --git a/gas/testsuite/gas/i386/intelok.d b/gas/testsuite/gas/i386/intelok.d
index 27f1217..e4ede94 100644
--- a/gas/testsuite/gas/i386/intelok.d
+++ b/gas/testsuite/gas/i386/intelok.d
@@ -1,7 +1,6 @@
#as: -J --divide
#objdump: -dwMintel
#name: i386 intel-ok
-#stderr: intelok.e
.*: +file format .*
@@ -108,6 +107,19 @@ Disassembly of section .text:
[ ]*[0-9a-f]+: 8b 40 12[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\+0x12\]
[ ]*[0-9a-f]+: 8b 04 85 02 00 00 00[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\*4\+(0x)?2\]
[ ]*[0-9a-f]+: 8b 04 85 02 00 00 00[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\*4\+(0x)?2\]
+[ ]*[0-9a-f]+: 0f b7 00[ ]+movzx[ ]+eax,WORD PTR \[eax\]
+[ ]*[0-9a-f]+: 0f b6 00[ ]+movzx[ ]+eax,BYTE PTR \[eax\]
+[ ]*[0-9a-f]+: 26 0f b7 00[ ]+movzx[ ]+eax,WORD PTR es:\[eax\]
+[ ]*[0-9a-f]+: 64 0f b6 00[ ]+movzx[ ]+eax,BYTE PTR fs:\[eax\]
+[ ]*[0-9a-f]+: 65 0f b7 00[ ]+movzx[ ]+eax,WORD PTR gs:\[eax\]
+[ ]*[0-9a-f]+: a1 01 00 00 00[ ]+mov[ ]+eax,ds:(0x)?1
+[ ]*[0-9a-f]+: a1 01 00 00 00[ ]+mov[ ]+eax,ds:(0x)?1
+[ ]*[0-9a-f]+: 65 a1 01 00 00 00[ ]+mov[ ]+eax,gs:(0x)?1
+[ ]*[0-9a-f]+: 65 a1 01 00 00 00[ ]+mov[ ]+eax,gs:(0x)?1
+[ ]*[0-9a-f]+: a1 00 00 00 00[ ]+mov[ ]+eax,ds:(0x)?0
+[ ]*[0-9a-f]+: a1 00 00 00 00[ ]+mov[ ]+eax,ds:(0x)?0
+[ ]*[0-9a-f]+: 65 a1 00 00 00 00[ ]+mov[ ]+eax,gs:(0x)?0
+[ ]*[0-9a-f]+: a1 00 00 00 00[ ]+mov[ ]+eax,ds:(0x)?0
[ ]*[0-9a-f]+: 8b 04 05 00 00 00 00[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\*1\+(0x)?0]
[ ]*[0-9a-f]+: 8b 04 05 00 00 00 00[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\*1\+(0x)?0]
[ ]*[0-9a-f]+: 8b 04 05 00 00 00 00[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\*1\+(0x)?0]
@@ -123,15 +135,20 @@ Disassembly of section .text:
[ ]*[0-9a-f]+: 8b 40 10[ ]+mov[ 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]*[0-9a-f]+: 8b 44 88 08[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\+ecx\*4\+(0x)?8\]
[ ]*[0-9a-f]+: 8b 00[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\]
[ ]*[0-9a-f]+: 8b 04 08[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\+ecx\*1\]
[ ]*[0-9a-f]+: 8b 04 08[ ]+mov[ ]+eax,(DWORD PTR )?\[eax\+ecx\*1\]
[ ]*[0-9a-f]+: 26 8b 00[ ]+mov[ ]+eax,(DWORD PTR )?es:\[eax\]
+[ ]*[0-9a-f]+: 64 8b 00[ ]+mov[ ]+eax,(DWORD PTR )?fs:\[eax\]
[ ]*[0-9a-f]+: 6a 01[ ]+push[ ]+0x1
[ ]*[0-9a-f]+: 6a ff[ ]+push[ ]+0xffffffff
[ ]*[0-9a-f]+: 6a fe[ ]+push[ ]+0xfffffffe
@@ -151,31 +168,40 @@ Disassembly of section .text:
[ ]*[0-9a-f]+: 6a fb[ ]+push[ ]+0xfffffffb
[ ]*[0-9a-f]+: 6a 03[ ]+push[ ]+0x3
[ ]*[0-9a-f]+: 6a 04[ ]+push[ ]+0x4
-[ ]*[0-9a-f]+: b8 00 00 00 00[ ]+mov[ ]+eax,0x0
-[ ]*[0-9a-f]+: b8 00 00 00 00[ ]+mov[ ]+eax,0x0
-[ ]*[0-9a-f]+: b8 00 00 00 00[ ]+mov[ ]+eax,0x0
-[ ]*[0-9a-f]+: b8 00 00 00 00[ ]+mov[ ]+eax,0x0
-[ ]*[0-9a-f]+: b8 00 00 00 00[ ]+mov[ ]+eax,0x0
-[ ]*[0-9a-f]+: b8 00 00 00 00[ ]+mov[ ]+eax,0x0
-[ ]*[0-9a-f]+: b8 00 00 00 00[ ]+mov[ ]+eax,0x0
+[ ]*[0-9a-f]+: b8 01 00 00 00[ ]+mov[ ]+eax,(0x)?1
+[ ]*[0-9a-f]+: b8 01 00 00 00[ ]+mov[ ]+eax,(0x)?1
+[ ]*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9a 05 00 00 00 03 00[ ]+l?call[ ]+0x3[,:]0x5
[ ]*[0-9a-f]+: ea 03 00 00 00 05 00[ ]+l?jmp[ ]+0x5[,:]0x3
-[ ]*[0-9a-f]+: ff 15 00 00 00 00[ ]+call[ ]+(DWORD PTR )?(ds:)?0x0
-[ ]*[0-9a-f]+: 66 ff 25 00 00 00 00[ ]+jmp[ ]+(WORD PTR )?(ds:)?0x0
+[ ]*[0-9a-f]+: ff 15 00 00 00 00[ ]+call[ ]+DWORD PTR (ds:)?(0x)?0
+[ ]*[0-9a-f]+: 66 ff 25 00 00 00 00[ ]+jmp[ ]+WORD PTR (ds:)?(0x)?0
#pass
diff --git a/gas/testsuite/gas/i386/intelok.e b/gas/testsuite/gas/i386/intelok.e
deleted file mode 100644
index e49436e..0000000
--- a/gas/testsuite/gas/i386/intelok.e
+++ /dev/null
@@ -1,8 +0,0 @@
-.*: Assembler messages:
-.*:175: Warning: .* taken to mean just .*
-.*:182: Warning: Treating .* as memory reference
-.*:183: Warning: .* taken to mean just .*
-.*:183: Warning: Treating .* as memory reference
-.*:186: Warning: Treating .* as memory reference
-.*:187: Warning: Treating .* as memory reference
-.*:190: Warning: Treating .* as memory reference
diff --git a/gas/testsuite/gas/i386/intelok.s b/gas/testsuite/gas/i386/intelok.s
index 2f78929..00cf4da 100644
--- a/gas/testsuite/gas/i386/intelok.s
+++ b/gas/testsuite/gas/i386/intelok.s
@@ -1,12 +1,4 @@
.intel_syntax noprefix
- .equiv byte, 1
- .equiv word, 2
- .equiv dword, 4
- .equiv fword, 6
- .equiv qword, 8
- .equiv tbyte, 10
- .equiv oword, 16
- .equiv xmmword, 16
.text
start:
@@ -115,6 +107,20 @@ start:
mov eax, tbyte[eax+dword*2]
mov eax, [word+eax*dword]
mov eax, word[eax*dword]
+ movzx eax, word ptr byte ptr [eax]
+ movzx eax, byte ptr [word ptr [eax]]
+ movzx eax, word ptr es:[eax]
+ movzx eax, byte ptr [fs:[eax]]
+ movzx eax, gs:word ptr [eax]
+
+ mov eax, FLAT:1
+ mov eax, FLAT:[1]
+ mov eax, gs:1
+ mov eax, gs:[1]
+ mov eax, x
+ mov eax, FLAT:x
+ mov eax, gs:x
+ mov eax, [x]
mov eax, [eax*1]
mov eax, [eax*+1]
@@ -127,19 +133,24 @@ start:
mov eax, [eax]+1
mov eax, [eax - 5 + ecx]
mov eax, [eax + 5 and 3 + ecx]
- mov eax, [eax + 5*3 + ecx]
+ mov eax, [eax + 5 * 3 + ecx]
mov eax, [oword][eax]
mov eax, [eax][oword]
mov eax, xmmword[eax][ecx]
+ mov eax, [eax]+[ecx]
mov eax, [eax]+1[ecx]
- mov eax, [eax][ecx]+1
- mov eax, [1][eax][ecx]
- mov eax, [eax][1][ecx]
- mov eax, [eax][ecx][1]
+ mov eax, [eax+2[ecx]]
+ mov eax, [eax][ecx]+3
+ mov eax, [4][eax][ecx]
+ mov eax, [eax][5][ecx]
+ mov eax, [eax][ecx][6]
+ mov eax, [eax+ecx*(2+2)+7]
+ mov eax, [eax+(ecx+2)*4]
mov eax, [[eax]]
mov eax, [eax[ecx]]
mov eax, [[eax][ecx]]
mov eax, es:[eax]
+ mov eax, fs:gs:[eax]
# expressions
@@ -166,6 +177,10 @@ start:
# offset expressions
+ mov eax, 1
+ mov eax, [1]
+ mov eax, dword ptr 1
+ mov eax, dword ptr [1]
mov eax, offset x
mov eax, offset flat:x
mov eax, offset gs:x
@@ -173,10 +188,17 @@ start:
mov eax, offset flat:[x]
mov eax, offset gs:[x]
mov eax, [offset x]
+ mov eax, [offset [x]]
+ mov eax, dword ptr [offset [x]]
+ mov eax, FLAT:[offset [x]]
+ mov eax, gs:[offset [x]]
+ mov eax, offset [dword ptr [x]]
+ mov eax, offset [gs:[x]]
mov eax, [eax + offset x]
mov eax, [eax + offset 1]
mov eax, [offset x + eax]
- mov eax, offset x+1[eax]
+ mov eax, [offset 1 + eax]
+ mov eax, offset x + 1[eax]
mov eax, [eax] + offset x
mov eax, [eax] + offset 1
mov eax, offset x + [1]
@@ -187,11 +209,10 @@ start:
mov eax, [5] + [offset x]
mov eax, ss:[6] + offset x
mov eax, ss:[7] + [offset x]
- mov eax, dword ptr [8]
# other operands
call 3:5
- jmp 5:3
+ jmp 5:[3]
call dword ptr xtrn
jmp word ptr xtrn
diff --git a/gas/testsuite/gas/i386/x86_64.d b/gas/testsuite/gas/i386/x86_64.d
index cbf769a..086cc3a 100644
--- a/gas/testsuite/gas/i386/x86_64.d
+++ b/gas/testsuite/gas/i386/x86_64.d
@@ -1,7 +1,6 @@
#as: -J
#objdump: -dw
#name: x86_64
-#stderr: x86_64.e
.*: +file format .*
Disassembly of section .text:
diff --git a/gas/testsuite/gas/i386/x86_64.e b/gas/testsuite/gas/i386/x86_64.e
deleted file mode 100644
index e11e903..0000000
--- a/gas/testsuite/gas/i386/x86_64.e
+++ /dev/null
@@ -1,9 +0,0 @@
-.*.s: Assembler messages:
-.*:51: Warning: Treating .\[0x22222222\]. as memory reference
-.*:89: Warning: Treating .DWORD PTR \[0x22222222\]. as memory reference
-.*:91: Warning: Treating .\[0x8877665544332211\]. as memory reference
-.*:92: Warning: Treating .\[0x8877665544332211\]. as memory reference
-.*:93: Warning: Treating .\[0x8877665544332211\]. as memory reference
-.*:94: Warning: Treating .\[0x8877665544332211\]. as memory reference
-.*:95: Warning: Treating .\[0x8877665544332211\]. as memory reference
-.*:96: Warning: Treating .\[0x8877665544332211\]. as memory reference
diff --git a/gas/testsuite/gas/i386/x86_64.s b/gas/testsuite/gas/i386/x86_64.s
index 34c8cdf..ef887d5 100644
--- a/gas/testsuite/gas/i386/x86_64.s
+++ b/gas/testsuite/gas/i386/x86_64.s
@@ -48,7 +48,7 @@ ADD R8D,[R8]
ADD RAX,[R8]
ADD EAX,[0x22222222+RIP]
ADD EAX,[RBP+0x00]
-ADD EAX,[0x22222222]
+ADD EAX,FLAT:[0x22222222]
ADD EAX,[R13+0]
ADD EAX,[RAX+RAX*4]
ADD EAX,[R8+RAX*4]
@@ -86,14 +86,14 @@ ADD DWORD PTR [RAX*8+0x22222222],0x33
ADD DWORD PTR [RAX+0x22222222],0x33
ADD DWORD PTR [RAX+0x22222222],0x33
ADD DWORD PTR [R8+RBP*8],0x33
-ADD DWORD PTR [0x22222222],0x33
+ADD DWORD PTR FLAT:[0x22222222],0x33
#new instructions
-MOVABS AL,[0x8877665544332211]
-MOVABS EAX,[0x8877665544332211]
-MOVABS [0x8877665544332211],AL
-MOVABS [0x8877665544332211],EAX
-MOVABS RAX,[0x8877665544332211]
-MOVABS [0x8877665544332211],RAX
+MOVABS AL,FLAT:[0x8877665544332211]
+MOVABS EAX,FLAT:[0x8877665544332211]
+MOVABS FLAT:[0x8877665544332211],AL
+MOVABS FLAT:[0x8877665544332211],EAX
+MOVABS RAX,FLAT:[0x8877665544332211]
+MOVABS FLAT:[0x8877665544332211],RAX
cqo
cdqe
movsx rax, eax