aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/ChangeLog7
-rw-r--r--gas/testsuite/gas/i386/x86-64-sib-intel.d13
-rw-r--r--gas/testsuite/gas/i386/x86-64-sib.d13
-rw-r--r--gas/testsuite/gas/i386/x86-64-sib.s14
4 files changed, 46 insertions, 1 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 01739e2..c13d97b 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,10 @@
+2008-01-24 H.J. Lu <hongjiu.lu@intel.com>
+
+ * gas/i386/x86-64-sib.s: Add tests for r12.
+
+ * gas/i386/x86-64-sib-intel.d: Updated.
+ * gas/i386/x86-64-sib.d: Likewise.
+
2008-01-23 H.J. Lu <hongjiu.lu@intel.com>
* gas/i386/i386.exp : Run x86-64-arch-1 and x86-64-arch-10.
diff --git a/gas/testsuite/gas/i386/x86-64-sib-intel.d b/gas/testsuite/gas/i386/x86-64-sib-intel.d
index 1ae72ea..85180b5 100644
--- a/gas/testsuite/gas/i386/x86-64-sib-intel.d
+++ b/gas/testsuite/gas/i386/x86-64-sib-intel.d
@@ -28,9 +28,16 @@ Disassembly of section .text:
[ ]*[a-f0-9]+: 8b 04 e3 mov eax,DWORD PTR \[rbx\+riz\*8\]
[ ]*[a-f0-9]+: 8b 04 24 mov eax,DWORD PTR \[rsp\]
[ ]*[a-f0-9]+: 8b 04 24 mov eax,DWORD PTR \[rsp\]
+[ ]*[a-f0-9]+: 8b 04 24 mov eax,DWORD PTR \[rsp\]
[ ]*[a-f0-9]+: 8b 04 64 mov eax,DWORD PTR \[rsp\+riz\*2\]
[ ]*[a-f0-9]+: 8b 04 a4 mov eax,DWORD PTR \[rsp\+riz\*4\]
[ ]*[a-f0-9]+: 8b 04 e4 mov eax,DWORD PTR \[rsp\+riz\*8\]
+[ ]*[a-f0-9]+: 41 8b 04 24 mov eax,DWORD PTR \[r12\]
+[ ]*[a-f0-9]+: 41 8b 04 24 mov eax,DWORD PTR \[r12\]
+[ ]*[a-f0-9]+: 41 8b 04 24 mov eax,DWORD PTR \[r12\]
+[ ]*[a-f0-9]+: 41 8b 04 64 mov eax,DWORD PTR \[r12\+riz\*2\]
+[ ]*[a-f0-9]+: 41 8b 04 a4 mov eax,DWORD PTR \[r12\+riz\*4\]
+[ ]*[a-f0-9]+: 41 8b 04 e4 mov eax,DWORD PTR \[r12\+riz\*8\]
[ ]*[a-f0-9]+: 8b 04 25 e2 ff ff ff mov eax,DWORD PTR ds:0xffffffffffffffe2
[ ]*[a-f0-9]+: 8b 04 65 e2 ff ff ff mov eax,DWORD PTR \[riz\*2-0x1e\]
[ ]*[a-f0-9]+: 8b 04 a5 e2 ff ff ff mov eax,DWORD PTR \[riz\*4-0x1e\]
@@ -50,4 +57,10 @@ Disassembly of section .text:
[ ]*[a-f0-9]+: 8b 04 64 mov eax,DWORD PTR \[rsp\+riz\*2\]
[ ]*[a-f0-9]+: 8b 04 a4 mov eax,DWORD PTR \[rsp\+riz\*4\]
[ ]*[a-f0-9]+: 8b 04 e4 mov eax,DWORD PTR \[rsp\+riz\*8\]
+[ ]*[a-f0-9]+: 41 8b 04 24 mov eax,DWORD PTR \[r12\]
+[ ]*[a-f0-9]+: 41 8b 04 24 mov eax,DWORD PTR \[r12\]
+[ ]*[a-f0-9]+: 41 8b 04 24 mov eax,DWORD PTR \[r12\]
+[ ]*[a-f0-9]+: 41 8b 04 64 mov eax,DWORD PTR \[r12\+riz\*2\]
+[ ]*[a-f0-9]+: 41 8b 04 a4 mov eax,DWORD PTR \[r12\+riz\*4\]
+[ ]*[a-f0-9]+: 41 8b 04 e4 mov eax,DWORD PTR \[r12\+riz\*8\]
#pass
diff --git a/gas/testsuite/gas/i386/x86-64-sib.d b/gas/testsuite/gas/i386/x86-64-sib.d
index f6d7315..3926624 100644
--- a/gas/testsuite/gas/i386/x86-64-sib.d
+++ b/gas/testsuite/gas/i386/x86-64-sib.d
@@ -27,9 +27,16 @@ Disassembly of section .text:
[ ]*[a-f0-9]+: 8b 04 e3 mov \(%rbx,%riz,8\),%eax
[ ]*[a-f0-9]+: 8b 04 24 mov \(%rsp\),%eax
[ ]*[a-f0-9]+: 8b 04 24 mov \(%rsp\),%eax
+[ ]*[a-f0-9]+: 8b 04 24 mov \(%rsp\),%eax
[ ]*[a-f0-9]+: 8b 04 64 mov \(%rsp,%riz,2\),%eax
[ ]*[a-f0-9]+: 8b 04 a4 mov \(%rsp,%riz,4\),%eax
[ ]*[a-f0-9]+: 8b 04 e4 mov \(%rsp,%riz,8\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 24 mov \(%r12\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 24 mov \(%r12\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 24 mov \(%r12\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 64 mov \(%r12,%riz,2\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 a4 mov \(%r12,%riz,4\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 e4 mov \(%r12,%riz,8\),%eax
[ ]*[a-f0-9]+: 8b 04 25 e2 ff ff ff mov 0xffffffffffffffe2,%eax
[ ]*[a-f0-9]+: 8b 04 65 e2 ff ff ff mov -0x1e\(,%riz,2\),%eax
[ ]*[a-f0-9]+: 8b 04 a5 e2 ff ff ff mov -0x1e\(,%riz,4\),%eax
@@ -49,4 +56,10 @@ Disassembly of section .text:
[ ]*[a-f0-9]+: 8b 04 64 mov \(%rsp,%riz,2\),%eax
[ ]*[a-f0-9]+: 8b 04 a4 mov \(%rsp,%riz,4\),%eax
[ ]*[a-f0-9]+: 8b 04 e4 mov \(%rsp,%riz,8\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 24 mov \(%r12\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 24 mov \(%r12\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 24 mov \(%r12\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 64 mov \(%r12,%riz,2\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 a4 mov \(%r12,%riz,4\),%eax
+[ ]*[a-f0-9]+: 41 8b 04 e4 mov \(%r12,%riz,8\),%eax
#pass
diff --git a/gas/testsuite/gas/i386/x86-64-sib.s b/gas/testsuite/gas/i386/x86-64-sib.s
index 38f4241..9562bb9 100644
--- a/gas/testsuite/gas/i386/x86-64-sib.s
+++ b/gas/testsuite/gas/i386/x86-64-sib.s
@@ -22,10 +22,17 @@ foo:
mov (%rbx,%riz,4),%eax
mov (%rbx,%riz,8),%eax
mov (%rsp),%eax
+ mov (%rsp,%riz),%eax
mov (%rsp,%riz,1),%eax
mov (%rsp,%riz,2),%eax
mov (%rsp,%riz,4),%eax
mov (%rsp,%riz,8),%eax
+ mov (%r12),%eax
+ mov (%r12,%riz),%eax
+ mov (%r12,%riz,1),%eax
+ mov (%r12,%riz,2),%eax
+ mov (%r12,%riz,4),%eax
+ mov (%r12,%riz,8),%eax
.intel_syntax noprefix
mov eax,DWORD PTR [riz*1-30]
mov eax,DWORD PTR [riz*2-30]
@@ -46,4 +53,9 @@ foo:
mov eax,DWORD PTR [rsp+riz*2]
mov eax,DWORD PTR [rsp+riz*4]
mov eax,DWORD PTR [rsp+riz*8]
- .p2align 4
+ mov eax,DWORD PTR [r12]
+ mov eax,DWORD PTR [r12+riz]
+ mov eax,DWORD PTR [r12+riz*1]
+ mov eax,DWORD PTR [r12+riz*2]
+ mov eax,DWORD PTR [r12+riz*4]
+ mov eax,DWORD PTR [r12+riz*8]