diff options
-rw-r--r-- | gas/testsuite/ChangeLog | 15 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/katmai.d | 13 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/katmai.s | 4 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/simd-intel.d | 8 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/simd-suffix.d | 8 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/simd.d | 8 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/simd.s | 9 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-simd-intel.d | 74 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-simd-suffix.d | 74 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-simd.d | 74 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/x86-64-simd.s | 9 | ||||
-rw-r--r-- | opcodes/ChangeLog | 8 | ||||
-rw-r--r-- | opcodes/i386-dis.c | 50 |
13 files changed, 210 insertions, 144 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index 953f096..e18ddd4 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,18 @@ +2007-10-23 H.J. Lu <hongjiu.lu@intel.com> + + * gas/i386/katmai.s: Remove cmpps opcode test. + + * gas/i386/simd.s: Add tests for cmpss and cmpsd. + * gas/i386/x86-64-simd.s: Likewise. + + * gas/i386/katmai.d: Updated. + * gas/i386/simd-intel.d: Likewise. + * gas/i386/simd-suffix.d: Likewise. + * gas/i386/simd.d: Likewise. + * gas/i386/x86-64-simd-intel.d: Likewise. + * gas/i386/x86-64-simd-suffix.d: Likewise. + * gas/i386/x86-64-simd.d: Likewise. + 2007-10-19 Nick Clifton <nickc@redhat.com> * gas/mn10300/basic.exp: Run pr997 test. diff --git a/gas/testsuite/gas/i386/katmai.d b/gas/testsuite/gas/i386/katmai.d index fc7a89f..05e456b 100644 --- a/gas/testsuite/gas/i386/katmai.d +++ b/gas/testsuite/gas/i386/katmai.d @@ -160,12 +160,7 @@ Disassembly of section .text: 237: 0f 18 0c 98 [ ]*prefetcht0 \(%eax,%ebx,4\) 23b: 0f 18 12 [ ]*prefetcht1 \(%edx\) 23e: 0f 18 19 [ ]*prefetcht2 \(%ecx\) - 241: 2e 0f [ ]*\(bad\) - 243: c2 0a 08 [ ]*ret \$0x80a - 246: 90 [ ]*nop - 247: 90 [ ]*nop - 248: 65 [ ]*gs - 249: 0f ae[ ]*\(bad\).* - 24b: ff 00 [ ]*incl \(%eax\) - 24d: 00 00 [ ]*add %al,\(%eax\) - ... + 241: 65 [ ]*gs + 242: 0f ae[ ]*\(bad\).* + 244: ff 00 [ ]*incl \(%eax\) +#pass diff --git a/gas/testsuite/gas/i386/katmai.s b/gas/testsuite/gas/i386/katmai.s index 534d15d..5510417 100644 --- a/gas/testsuite/gas/i386/katmai.s +++ b/gas/testsuite/gas/i386/katmai.s @@ -157,10 +157,6 @@ foo: prefetcht1 (%edx) prefetcht2 (%ecx) -# A SIMD instruction with a bad extension byte -.byte 0x2E,0x0F,0xC2,0x0A,0x08 - nop - nop # A bad sfence modrm byte .byte 0x65,0x0F,0xAE,0xff # Pad out to good alignment diff --git a/gas/testsuite/gas/i386/simd-intel.d b/gas/testsuite/gas/i386/simd-intel.d index 9e3a080..8ed8927 100644 --- a/gas/testsuite/gas/i386/simd-intel.d +++ b/gas/testsuite/gas/i386/simd-intel.d @@ -89,6 +89,10 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 08 unpckhps xmm1,XMMWORD PTR \[eax\] [ ]*[a-f0-9]+: 66 0f 14 08 unpcklpd xmm1,XMMWORD PTR \[eax\] [ ]*[a-f0-9]+: 0f 14 08 unpcklps xmm1,XMMWORD PTR \[eax\] +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss xmm7,DWORD PTR \[eax\],0x10 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd xmm7,QWORD PTR \[eax\],0x10 [ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps xmm1,XMMWORD PTR ds:0x12345678 [ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd xmm1,QWORD PTR ds:0x12345678 [ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss xmm1,DWORD PTR ds:0x12345678 @@ -170,4 +174,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 00 unpckhps xmm0,XMMWORD PTR \[eax\] [ ]*[a-f0-9]+: 66 0f 14 00 unpcklpd xmm0,XMMWORD PTR \[eax\] [ ]*[a-f0-9]+: 0f 14 00 unpcklps xmm0,XMMWORD PTR \[eax\] +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss xmm7,DWORD PTR \[eax\],0x10 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd xmm7,QWORD PTR \[eax\],0x10 #pass diff --git a/gas/testsuite/gas/i386/simd-suffix.d b/gas/testsuite/gas/i386/simd-suffix.d index 633bf68..abae5b7 100644 --- a/gas/testsuite/gas/i386/simd-suffix.d +++ b/gas/testsuite/gas/i386/simd-suffix.d @@ -89,6 +89,10 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 08 unpckhps \(%eax\),%xmm1 [ ]*[a-f0-9]+: 66 0f 14 08 unpcklpd \(%eax\),%xmm1 [ ]*[a-f0-9]+: 0f 14 08 unpcklps \(%eax\),%xmm1 +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%eax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%eax\),%xmm7 [ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps 0x12345678,%xmm1 [ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd 0x12345678,%xmm1 [ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss 0x12345678,%xmm1 @@ -170,4 +174,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 00 unpckhps \(%eax\),%xmm0 [ ]*[a-f0-9]+: 66 0f 14 00 unpcklpd \(%eax\),%xmm0 [ ]*[a-f0-9]+: 0f 14 00 unpcklps \(%eax\),%xmm0 +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%eax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%eax\),%xmm7 #pass diff --git a/gas/testsuite/gas/i386/simd.d b/gas/testsuite/gas/i386/simd.d index d16d3c5..d355ffe 100644 --- a/gas/testsuite/gas/i386/simd.d +++ b/gas/testsuite/gas/i386/simd.d @@ -88,6 +88,10 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 08 unpckhps \(%eax\),%xmm1 [ ]*[a-f0-9]+: 66 0f 14 08 unpcklpd \(%eax\),%xmm1 [ ]*[a-f0-9]+: 0f 14 08 unpcklps \(%eax\),%xmm1 +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%eax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%eax\),%xmm7 [ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps 0x12345678,%xmm1 [ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd 0x12345678,%xmm1 [ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss 0x12345678,%xmm1 @@ -169,4 +173,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 00 unpckhps \(%eax\),%xmm0 [ ]*[a-f0-9]+: 66 0f 14 00 unpcklpd \(%eax\),%xmm0 [ ]*[a-f0-9]+: 0f 14 00 unpcklps \(%eax\),%xmm0 +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%eax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%eax\),%xmm7 #pass diff --git a/gas/testsuite/gas/i386/simd.s b/gas/testsuite/gas/i386/simd.s index dc7bae1..4854d60 100644 --- a/gas/testsuite/gas/i386/simd.s +++ b/gas/testsuite/gas/i386/simd.s @@ -85,6 +85,11 @@ _start: unpcklpd (%eax),%xmm1 unpcklps (%eax),%xmm1 +cmpss $0x10,%xmm7,%xmm6 +cmpss $0x10,(%eax),%xmm7 +cmpsd $0x10,%xmm7,%xmm6 +cmpsd $0x10,(%eax),%xmm7 + .intel_syntax noprefix addsubps xmm1,XMMWORD PTR ds:0x12345678 @@ -168,3 +173,7 @@ unpckhpd xmm0,XMMWORD PTR [eax] unpckhps xmm0,XMMWORD PTR [eax] unpcklpd xmm0,XMMWORD PTR [eax] unpcklps xmm0,XMMWORD PTR [eax] +cmpss xmm6,xmm7,0x10 +cmpss xmm7,DWORD PTR [eax],0x10 +cmpsd xmm6,xmm7,0x10 +cmpsd xmm7,QWORD PTR [eax],0x10 diff --git a/gas/testsuite/gas/i386/x86-64-simd-intel.d b/gas/testsuite/gas/i386/x86-64-simd-intel.d index dea1fc0..7b15257 100644 --- a/gas/testsuite/gas/i386/x86-64-simd-intel.d +++ b/gas/testsuite/gas/i386/x86-64-simd-intel.d @@ -95,39 +95,43 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 08 unpckhps xmm1,XMMWORD PTR \[rax\] [ ]*[a-f0-9]+: 66 0f 14 08 unpcklpd xmm1,XMMWORD PTR \[rax\] [ ]*[a-f0-9]+: 0f 14 08 unpcklps xmm1,XMMWORD PTR \[rax\] -[ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234586c <_start\+0x1234586c> -[ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd xmm1,QWORD PTR \[rip\+0x12345678\] # 12345874 <_start\+0x12345874> -[ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss xmm1,DWORD PTR \[rip\+0x12345678\] # 1234587b <_start\+0x1234587b> -[ ]*[a-f0-9]+: f3 0f e6 0d 78 56 34 12 cvtdq2pd xmm1,QWORD PTR \[rip\+0x12345678\] # 12345883 <_start\+0x12345883> -[ ]*[a-f0-9]+: f2 0f e6 0d 78 56 34 12 cvtpd2dq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234588b <_start\+0x1234588b> -[ ]*[a-f0-9]+: 0f 5a 0d 78 56 34 12 cvtps2pd xmm1,QWORD PTR \[rip\+0x12345678\] # 12345892 <_start\+0x12345892> -[ ]*[a-f0-9]+: f3 0f 5b 0d 78 56 34 12 cvttps2dq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234589a <_start\+0x1234589a> -[ ]*[a-f0-9]+: f2 0f 7c 0d 78 56 34 12 haddps xmm1,XMMWORD PTR \[rip\+0x12345678\] # 123458a2 <_start\+0x123458a2> -[ ]*[a-f0-9]+: f3 0f 7f 0d 78 56 34 12 movdqu XMMWORD PTR \[rip\+0x12345678\],xmm1 # 123458aa <_start\+0x123458aa> -[ ]*[a-f0-9]+: f3 0f 6f 0d 78 56 34 12 movdqu xmm1,XMMWORD PTR \[rip\+0x12345678\] # 123458b2 <_start\+0x123458b2> -[ ]*[a-f0-9]+: 66 0f 17 0d 78 56 34 12 movhpd QWORD PTR \[rip\+0x12345678\],xmm1 # 123458ba <_start\+0x123458ba> -[ ]*[a-f0-9]+: 66 0f 16 0d 78 56 34 12 movhpd xmm1,QWORD PTR \[rip\+0x12345678\] # 123458c2 <_start\+0x123458c2> -[ ]*[a-f0-9]+: 0f 17 0d 78 56 34 12 movhps QWORD PTR \[rip\+0x12345678\],xmm1 # 123458c9 <_start\+0x123458c9> -[ ]*[a-f0-9]+: 0f 16 0d 78 56 34 12 movhps xmm1,QWORD PTR \[rip\+0x12345678\] # 123458d0 <_start\+0x123458d0> -[ ]*[a-f0-9]+: 66 0f 13 0d 78 56 34 12 movlpd QWORD PTR \[rip\+0x12345678\],xmm1 # 123458d8 <_start\+0x123458d8> -[ ]*[a-f0-9]+: 66 0f 12 0d 78 56 34 12 movlpd xmm1,QWORD PTR \[rip\+0x12345678\] # 123458e0 <_start\+0x123458e0> -[ ]*[a-f0-9]+: 0f 13 0d 78 56 34 12 movlps QWORD PTR \[rip\+0x12345678\],xmm1 # 123458e7 <_start\+0x123458e7> -[ ]*[a-f0-9]+: 0f 12 0d 78 56 34 12 movlps xmm1,QWORD PTR \[rip\+0x12345678\] # 123458ee <_start\+0x123458ee> -[ ]*[a-f0-9]+: 66 0f d6 0d 78 56 34 12 movq QWORD PTR \[rip\+0x12345678\],xmm1 # 123458f6 <_start\+0x123458f6> -[ ]*[a-f0-9]+: f3 0f 7e 0d 78 56 34 12 movq xmm1,QWORD PTR \[rip\+0x12345678\] # 123458fe <_start\+0x123458fe> -[ ]*[a-f0-9]+: f3 0f 16 0d 78 56 34 12 movshdup xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345906 <_start\+0x12345906> -[ ]*[a-f0-9]+: f3 0f 12 0d 78 56 34 12 movsldup xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234590e <_start\+0x1234590e> -[ ]*[a-f0-9]+: f3 0f 70 0d 78 56 34 12 90 pshufhw xmm1,XMMWORD PTR \[rip\+0x12345678\],0x90 # 12345917 <_start\+0x12345917> -[ ]*[a-f0-9]+: f2 0f 70 0d 78 56 34 12 90 pshuflw xmm1,XMMWORD PTR \[rip\+0x12345678\],0x90 # 12345920 <_start\+0x12345920> -[ ]*[a-f0-9]+: 0f 60 0d 78 56 34 12 punpcklbw mm1,DWORD PTR \[rip\+0x12345678\] # 12345927 <_start\+0x12345927> -[ ]*[a-f0-9]+: 0f 62 0d 78 56 34 12 punpckldq mm1,DWORD PTR \[rip\+0x12345678\] # 1234592e <_start\+0x1234592e> -[ ]*[a-f0-9]+: 0f 61 0d 78 56 34 12 punpcklwd mm1,DWORD PTR \[rip\+0x12345678\] # 12345935 <_start\+0x12345935> -[ ]*[a-f0-9]+: 66 0f 60 0d 78 56 34 12 punpcklbw xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234593d <_start\+0x1234593d> -[ ]*[a-f0-9]+: 66 0f 62 0d 78 56 34 12 punpckldq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345945 <_start\+0x12345945> -[ ]*[a-f0-9]+: 66 0f 61 0d 78 56 34 12 punpcklwd xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234594d <_start\+0x1234594d> -[ ]*[a-f0-9]+: 66 0f 6c 0d 78 56 34 12 punpcklqdq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345955 <_start\+0x12345955> -[ ]*[a-f0-9]+: 66 0f 2e 0d 78 56 34 12 ucomisd xmm1,QWORD PTR \[rip\+0x12345678\] # 1234595d <_start\+0x1234595d> -[ ]*[a-f0-9]+: 0f 2e 0d 78 56 34 12 ucomiss xmm1,DWORD PTR \[rip\+0x12345678\] # 12345964 <_start\+0x12345964> +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss xmm7,DWORD PTR \[rax\],0x10 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd xmm7,QWORD PTR \[rax\],0x10 +[ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345880 <_start\+0x12345880> +[ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd xmm1,QWORD PTR \[rip\+0x12345678\] # 12345888 <_start\+0x12345888> +[ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss xmm1,DWORD PTR \[rip\+0x12345678\] # 1234588f <_start\+0x1234588f> +[ ]*[a-f0-9]+: f3 0f e6 0d 78 56 34 12 cvtdq2pd xmm1,QWORD PTR \[rip\+0x12345678\] # 12345897 <_start\+0x12345897> +[ ]*[a-f0-9]+: f2 0f e6 0d 78 56 34 12 cvtpd2dq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234589f <_start\+0x1234589f> +[ ]*[a-f0-9]+: 0f 5a 0d 78 56 34 12 cvtps2pd xmm1,QWORD PTR \[rip\+0x12345678\] # 123458a6 <_start\+0x123458a6> +[ ]*[a-f0-9]+: f3 0f 5b 0d 78 56 34 12 cvttps2dq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 123458ae <_start\+0x123458ae> +[ ]*[a-f0-9]+: f2 0f 7c 0d 78 56 34 12 haddps xmm1,XMMWORD PTR \[rip\+0x12345678\] # 123458b6 <_start\+0x123458b6> +[ ]*[a-f0-9]+: f3 0f 7f 0d 78 56 34 12 movdqu XMMWORD PTR \[rip\+0x12345678\],xmm1 # 123458be <_start\+0x123458be> +[ ]*[a-f0-9]+: f3 0f 6f 0d 78 56 34 12 movdqu xmm1,XMMWORD PTR \[rip\+0x12345678\] # 123458c6 <_start\+0x123458c6> +[ ]*[a-f0-9]+: 66 0f 17 0d 78 56 34 12 movhpd QWORD PTR \[rip\+0x12345678\],xmm1 # 123458ce <_start\+0x123458ce> +[ ]*[a-f0-9]+: 66 0f 16 0d 78 56 34 12 movhpd xmm1,QWORD PTR \[rip\+0x12345678\] # 123458d6 <_start\+0x123458d6> +[ ]*[a-f0-9]+: 0f 17 0d 78 56 34 12 movhps QWORD PTR \[rip\+0x12345678\],xmm1 # 123458dd <_start\+0x123458dd> +[ ]*[a-f0-9]+: 0f 16 0d 78 56 34 12 movhps xmm1,QWORD PTR \[rip\+0x12345678\] # 123458e4 <_start\+0x123458e4> +[ ]*[a-f0-9]+: 66 0f 13 0d 78 56 34 12 movlpd QWORD PTR \[rip\+0x12345678\],xmm1 # 123458ec <_start\+0x123458ec> +[ ]*[a-f0-9]+: 66 0f 12 0d 78 56 34 12 movlpd xmm1,QWORD PTR \[rip\+0x12345678\] # 123458f4 <_start\+0x123458f4> +[ ]*[a-f0-9]+: 0f 13 0d 78 56 34 12 movlps QWORD PTR \[rip\+0x12345678\],xmm1 # 123458fb <_start\+0x123458fb> +[ ]*[a-f0-9]+: 0f 12 0d 78 56 34 12 movlps xmm1,QWORD PTR \[rip\+0x12345678\] # 12345902 <_start\+0x12345902> +[ ]*[a-f0-9]+: 66 0f d6 0d 78 56 34 12 movq QWORD PTR \[rip\+0x12345678\],xmm1 # 1234590a <_start\+0x1234590a> +[ ]*[a-f0-9]+: f3 0f 7e 0d 78 56 34 12 movq xmm1,QWORD PTR \[rip\+0x12345678\] # 12345912 <_start\+0x12345912> +[ ]*[a-f0-9]+: f3 0f 16 0d 78 56 34 12 movshdup xmm1,XMMWORD PTR \[rip\+0x12345678\] # 1234591a <_start\+0x1234591a> +[ ]*[a-f0-9]+: f3 0f 12 0d 78 56 34 12 movsldup xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345922 <_start\+0x12345922> +[ ]*[a-f0-9]+: f3 0f 70 0d 78 56 34 12 90 pshufhw xmm1,XMMWORD PTR \[rip\+0x12345678\],0x90 # 1234592b <_start\+0x1234592b> +[ ]*[a-f0-9]+: f2 0f 70 0d 78 56 34 12 90 pshuflw xmm1,XMMWORD PTR \[rip\+0x12345678\],0x90 # 12345934 <_start\+0x12345934> +[ ]*[a-f0-9]+: 0f 60 0d 78 56 34 12 punpcklbw mm1,DWORD PTR \[rip\+0x12345678\] # 1234593b <_start\+0x1234593b> +[ ]*[a-f0-9]+: 0f 62 0d 78 56 34 12 punpckldq mm1,DWORD PTR \[rip\+0x12345678\] # 12345942 <_start\+0x12345942> +[ ]*[a-f0-9]+: 0f 61 0d 78 56 34 12 punpcklwd mm1,DWORD PTR \[rip\+0x12345678\] # 12345949 <_start\+0x12345949> +[ ]*[a-f0-9]+: 66 0f 60 0d 78 56 34 12 punpcklbw xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345951 <_start\+0x12345951> +[ ]*[a-f0-9]+: 66 0f 62 0d 78 56 34 12 punpckldq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345959 <_start\+0x12345959> +[ ]*[a-f0-9]+: 66 0f 61 0d 78 56 34 12 punpcklwd xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345961 <_start\+0x12345961> +[ ]*[a-f0-9]+: 66 0f 6c 0d 78 56 34 12 punpcklqdq xmm1,XMMWORD PTR \[rip\+0x12345678\] # 12345969 <_start\+0x12345969> +[ ]*[a-f0-9]+: 66 0f 2e 0d 78 56 34 12 ucomisd xmm1,QWORD PTR \[rip\+0x12345678\] # 12345971 <_start\+0x12345971> +[ ]*[a-f0-9]+: 0f 2e 0d 78 56 34 12 ucomiss xmm1,DWORD PTR \[rip\+0x12345678\] # 12345978 <_start\+0x12345978> [ ]*[a-f0-9]+: f2 0f c2 00 00 cmpeqsd xmm0,QWORD PTR \[rax\] [ ]*[a-f0-9]+: f3 0f c2 00 00 cmpeqss xmm0,DWORD PTR \[rax\] [ ]*[a-f0-9]+: 66 0f 2a 00 cvtpi2pd xmm0,QWORD PTR \[rax\] @@ -182,4 +186,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 00 unpckhps xmm0,XMMWORD PTR \[rax\] [ ]*[a-f0-9]+: 66 0f 14 00 unpcklpd xmm0,XMMWORD PTR \[rax\] [ ]*[a-f0-9]+: 0f 14 00 unpcklps xmm0,XMMWORD PTR \[rax\] +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss xmm7,DWORD PTR \[rax\],0x10 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd xmm6,xmm7,0x10 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd xmm7,QWORD PTR \[rax\],0x10 #pass diff --git a/gas/testsuite/gas/i386/x86-64-simd-suffix.d b/gas/testsuite/gas/i386/x86-64-simd-suffix.d index dfd3150..d653714 100644 --- a/gas/testsuite/gas/i386/x86-64-simd-suffix.d +++ b/gas/testsuite/gas/i386/x86-64-simd-suffix.d @@ -95,39 +95,43 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 08 unpckhps \(%rax\),%xmm1 [ ]*[a-f0-9]+: 66 0f 14 08 unpcklpd \(%rax\),%xmm1 [ ]*[a-f0-9]+: 0f 14 08 unpcklps \(%rax\),%xmm1 -[ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps 0x12345678\(%rip\),%xmm1 # 1234586c <_start\+0x1234586c> -[ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd 0x12345678\(%rip\),%xmm1 # 12345874 <_start\+0x12345874> -[ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss 0x12345678\(%rip\),%xmm1 # 1234587b <_start\+0x1234587b> -[ ]*[a-f0-9]+: f3 0f e6 0d 78 56 34 12 cvtdq2pd 0x12345678\(%rip\),%xmm1 # 12345883 <_start\+0x12345883> -[ ]*[a-f0-9]+: f2 0f e6 0d 78 56 34 12 cvtpd2dq 0x12345678\(%rip\),%xmm1 # 1234588b <_start\+0x1234588b> -[ ]*[a-f0-9]+: 0f 5a 0d 78 56 34 12 cvtps2pd 0x12345678\(%rip\),%xmm1 # 12345892 <_start\+0x12345892> -[ ]*[a-f0-9]+: f3 0f 5b 0d 78 56 34 12 cvttps2dq 0x12345678\(%rip\),%xmm1 # 1234589a <_start\+0x1234589a> -[ ]*[a-f0-9]+: f2 0f 7c 0d 78 56 34 12 haddps 0x12345678\(%rip\),%xmm1 # 123458a2 <_start\+0x123458a2> -[ ]*[a-f0-9]+: f3 0f 7f 0d 78 56 34 12 movdqu %xmm1,0x12345678\(%rip\) # 123458aa <_start\+0x123458aa> -[ ]*[a-f0-9]+: f3 0f 6f 0d 78 56 34 12 movdqu 0x12345678\(%rip\),%xmm1 # 123458b2 <_start\+0x123458b2> -[ ]*[a-f0-9]+: 66 0f 17 0d 78 56 34 12 movhpd %xmm1,0x12345678\(%rip\) # 123458ba <_start\+0x123458ba> -[ ]*[a-f0-9]+: 66 0f 16 0d 78 56 34 12 movhpd 0x12345678\(%rip\),%xmm1 # 123458c2 <_start\+0x123458c2> -[ ]*[a-f0-9]+: 0f 17 0d 78 56 34 12 movhps %xmm1,0x12345678\(%rip\) # 123458c9 <_start\+0x123458c9> -[ ]*[a-f0-9]+: 0f 16 0d 78 56 34 12 movhps 0x12345678\(%rip\),%xmm1 # 123458d0 <_start\+0x123458d0> -[ ]*[a-f0-9]+: 66 0f 13 0d 78 56 34 12 movlpd %xmm1,0x12345678\(%rip\) # 123458d8 <_start\+0x123458d8> -[ ]*[a-f0-9]+: 66 0f 12 0d 78 56 34 12 movlpd 0x12345678\(%rip\),%xmm1 # 123458e0 <_start\+0x123458e0> -[ ]*[a-f0-9]+: 0f 13 0d 78 56 34 12 movlps %xmm1,0x12345678\(%rip\) # 123458e7 <_start\+0x123458e7> -[ ]*[a-f0-9]+: 0f 12 0d 78 56 34 12 movlps 0x12345678\(%rip\),%xmm1 # 123458ee <_start\+0x123458ee> -[ ]*[a-f0-9]+: 66 0f d6 0d 78 56 34 12 movq %xmm1,0x12345678\(%rip\) # 123458f6 <_start\+0x123458f6> -[ ]*[a-f0-9]+: f3 0f 7e 0d 78 56 34 12 movq 0x12345678\(%rip\),%xmm1 # 123458fe <_start\+0x123458fe> -[ ]*[a-f0-9]+: f3 0f 16 0d 78 56 34 12 movshdup 0x12345678\(%rip\),%xmm1 # 12345906 <_start\+0x12345906> -[ ]*[a-f0-9]+: f3 0f 12 0d 78 56 34 12 movsldup 0x12345678\(%rip\),%xmm1 # 1234590e <_start\+0x1234590e> -[ ]*[a-f0-9]+: f3 0f 70 0d 78 56 34 12 90 pshufhw \$0x90,0x12345678\(%rip\),%xmm1 # 12345917 <_start\+0x12345917> -[ ]*[a-f0-9]+: f2 0f 70 0d 78 56 34 12 90 pshuflw \$0x90,0x12345678\(%rip\),%xmm1 # 12345920 <_start\+0x12345920> -[ ]*[a-f0-9]+: 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%mm1 # 12345927 <_start\+0x12345927> -[ ]*[a-f0-9]+: 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%mm1 # 1234592e <_start\+0x1234592e> -[ ]*[a-f0-9]+: 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%mm1 # 12345935 <_start\+0x12345935> -[ ]*[a-f0-9]+: 66 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%xmm1 # 1234593d <_start\+0x1234593d> -[ ]*[a-f0-9]+: 66 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%xmm1 # 12345945 <_start\+0x12345945> -[ ]*[a-f0-9]+: 66 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%xmm1 # 1234594d <_start\+0x1234594d> -[ ]*[a-f0-9]+: 66 0f 6c 0d 78 56 34 12 punpcklqdq 0x12345678\(%rip\),%xmm1 # 12345955 <_start\+0x12345955> -[ ]*[a-f0-9]+: 66 0f 2e 0d 78 56 34 12 ucomisd 0x12345678\(%rip\),%xmm1 # 1234595d <_start\+0x1234595d> -[ ]*[a-f0-9]+: 0f 2e 0d 78 56 34 12 ucomiss 0x12345678\(%rip\),%xmm1 # 12345964 <_start\+0x12345964> +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%rax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%rax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps 0x12345678\(%rip\),%xmm1 # 12345880 <_start\+0x12345880> +[ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd 0x12345678\(%rip\),%xmm1 # 12345888 <_start\+0x12345888> +[ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss 0x12345678\(%rip\),%xmm1 # 1234588f <_start\+0x1234588f> +[ ]*[a-f0-9]+: f3 0f e6 0d 78 56 34 12 cvtdq2pd 0x12345678\(%rip\),%xmm1 # 12345897 <_start\+0x12345897> +[ ]*[a-f0-9]+: f2 0f e6 0d 78 56 34 12 cvtpd2dq 0x12345678\(%rip\),%xmm1 # 1234589f <_start\+0x1234589f> +[ ]*[a-f0-9]+: 0f 5a 0d 78 56 34 12 cvtps2pd 0x12345678\(%rip\),%xmm1 # 123458a6 <_start\+0x123458a6> +[ ]*[a-f0-9]+: f3 0f 5b 0d 78 56 34 12 cvttps2dq 0x12345678\(%rip\),%xmm1 # 123458ae <_start\+0x123458ae> +[ ]*[a-f0-9]+: f2 0f 7c 0d 78 56 34 12 haddps 0x12345678\(%rip\),%xmm1 # 123458b6 <_start\+0x123458b6> +[ ]*[a-f0-9]+: f3 0f 7f 0d 78 56 34 12 movdqu %xmm1,0x12345678\(%rip\) # 123458be <_start\+0x123458be> +[ ]*[a-f0-9]+: f3 0f 6f 0d 78 56 34 12 movdqu 0x12345678\(%rip\),%xmm1 # 123458c6 <_start\+0x123458c6> +[ ]*[a-f0-9]+: 66 0f 17 0d 78 56 34 12 movhpd %xmm1,0x12345678\(%rip\) # 123458ce <_start\+0x123458ce> +[ ]*[a-f0-9]+: 66 0f 16 0d 78 56 34 12 movhpd 0x12345678\(%rip\),%xmm1 # 123458d6 <_start\+0x123458d6> +[ ]*[a-f0-9]+: 0f 17 0d 78 56 34 12 movhps %xmm1,0x12345678\(%rip\) # 123458dd <_start\+0x123458dd> +[ ]*[a-f0-9]+: 0f 16 0d 78 56 34 12 movhps 0x12345678\(%rip\),%xmm1 # 123458e4 <_start\+0x123458e4> +[ ]*[a-f0-9]+: 66 0f 13 0d 78 56 34 12 movlpd %xmm1,0x12345678\(%rip\) # 123458ec <_start\+0x123458ec> +[ ]*[a-f0-9]+: 66 0f 12 0d 78 56 34 12 movlpd 0x12345678\(%rip\),%xmm1 # 123458f4 <_start\+0x123458f4> +[ ]*[a-f0-9]+: 0f 13 0d 78 56 34 12 movlps %xmm1,0x12345678\(%rip\) # 123458fb <_start\+0x123458fb> +[ ]*[a-f0-9]+: 0f 12 0d 78 56 34 12 movlps 0x12345678\(%rip\),%xmm1 # 12345902 <_start\+0x12345902> +[ ]*[a-f0-9]+: 66 0f d6 0d 78 56 34 12 movq %xmm1,0x12345678\(%rip\) # 1234590a <_start\+0x1234590a> +[ ]*[a-f0-9]+: f3 0f 7e 0d 78 56 34 12 movq 0x12345678\(%rip\),%xmm1 # 12345912 <_start\+0x12345912> +[ ]*[a-f0-9]+: f3 0f 16 0d 78 56 34 12 movshdup 0x12345678\(%rip\),%xmm1 # 1234591a <_start\+0x1234591a> +[ ]*[a-f0-9]+: f3 0f 12 0d 78 56 34 12 movsldup 0x12345678\(%rip\),%xmm1 # 12345922 <_start\+0x12345922> +[ ]*[a-f0-9]+: f3 0f 70 0d 78 56 34 12 90 pshufhw \$0x90,0x12345678\(%rip\),%xmm1 # 1234592b <_start\+0x1234592b> +[ ]*[a-f0-9]+: f2 0f 70 0d 78 56 34 12 90 pshuflw \$0x90,0x12345678\(%rip\),%xmm1 # 12345934 <_start\+0x12345934> +[ ]*[a-f0-9]+: 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%mm1 # 1234593b <_start\+0x1234593b> +[ ]*[a-f0-9]+: 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%mm1 # 12345942 <_start\+0x12345942> +[ ]*[a-f0-9]+: 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%mm1 # 12345949 <_start\+0x12345949> +[ ]*[a-f0-9]+: 66 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%xmm1 # 12345951 <_start\+0x12345951> +[ ]*[a-f0-9]+: 66 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%xmm1 # 12345959 <_start\+0x12345959> +[ ]*[a-f0-9]+: 66 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%xmm1 # 12345961 <_start\+0x12345961> +[ ]*[a-f0-9]+: 66 0f 6c 0d 78 56 34 12 punpcklqdq 0x12345678\(%rip\),%xmm1 # 12345969 <_start\+0x12345969> +[ ]*[a-f0-9]+: 66 0f 2e 0d 78 56 34 12 ucomisd 0x12345678\(%rip\),%xmm1 # 12345971 <_start\+0x12345971> +[ ]*[a-f0-9]+: 0f 2e 0d 78 56 34 12 ucomiss 0x12345678\(%rip\),%xmm1 # 12345978 <_start\+0x12345978> [ ]*[a-f0-9]+: f2 0f c2 00 00 cmpeqsd \(%rax\),%xmm0 [ ]*[a-f0-9]+: f3 0f c2 00 00 cmpeqss \(%rax\),%xmm0 [ ]*[a-f0-9]+: 66 0f 2a 00 cvtpi2pd \(%rax\),%xmm0 @@ -182,4 +186,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 00 unpckhps \(%rax\),%xmm0 [ ]*[a-f0-9]+: 66 0f 14 00 unpcklpd \(%rax\),%xmm0 [ ]*[a-f0-9]+: 0f 14 00 unpcklps \(%rax\),%xmm0 +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%rax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%rax\),%xmm7 #pass diff --git a/gas/testsuite/gas/i386/x86-64-simd.d b/gas/testsuite/gas/i386/x86-64-simd.d index 94b6e37..65f832f 100644 --- a/gas/testsuite/gas/i386/x86-64-simd.d +++ b/gas/testsuite/gas/i386/x86-64-simd.d @@ -94,39 +94,43 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 08 unpckhps \(%rax\),%xmm1 [ ]*[a-f0-9]+: 66 0f 14 08 unpcklpd \(%rax\),%xmm1 [ ]*[a-f0-9]+: 0f 14 08 unpcklps \(%rax\),%xmm1 -[ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps 0x12345678\(%rip\),%xmm1 # 1234586c <_start\+0x1234586c> -[ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd 0x12345678\(%rip\),%xmm1 # 12345874 <_start\+0x12345874> -[ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss 0x12345678\(%rip\),%xmm1 # 1234587b <_start\+0x1234587b> -[ ]*[a-f0-9]+: f3 0f e6 0d 78 56 34 12 cvtdq2pd 0x12345678\(%rip\),%xmm1 # 12345883 <_start\+0x12345883> -[ ]*[a-f0-9]+: f2 0f e6 0d 78 56 34 12 cvtpd2dq 0x12345678\(%rip\),%xmm1 # 1234588b <_start\+0x1234588b> -[ ]*[a-f0-9]+: 0f 5a 0d 78 56 34 12 cvtps2pd 0x12345678\(%rip\),%xmm1 # 12345892 <_start\+0x12345892> -[ ]*[a-f0-9]+: f3 0f 5b 0d 78 56 34 12 cvttps2dq 0x12345678\(%rip\),%xmm1 # 1234589a <_start\+0x1234589a> -[ ]*[a-f0-9]+: f2 0f 7c 0d 78 56 34 12 haddps 0x12345678\(%rip\),%xmm1 # 123458a2 <_start\+0x123458a2> -[ ]*[a-f0-9]+: f3 0f 7f 0d 78 56 34 12 movdqu %xmm1,0x12345678\(%rip\) # 123458aa <_start\+0x123458aa> -[ ]*[a-f0-9]+: f3 0f 6f 0d 78 56 34 12 movdqu 0x12345678\(%rip\),%xmm1 # 123458b2 <_start\+0x123458b2> -[ ]*[a-f0-9]+: 66 0f 17 0d 78 56 34 12 movhpd %xmm1,0x12345678\(%rip\) # 123458ba <_start\+0x123458ba> -[ ]*[a-f0-9]+: 66 0f 16 0d 78 56 34 12 movhpd 0x12345678\(%rip\),%xmm1 # 123458c2 <_start\+0x123458c2> -[ ]*[a-f0-9]+: 0f 17 0d 78 56 34 12 movhps %xmm1,0x12345678\(%rip\) # 123458c9 <_start\+0x123458c9> -[ ]*[a-f0-9]+: 0f 16 0d 78 56 34 12 movhps 0x12345678\(%rip\),%xmm1 # 123458d0 <_start\+0x123458d0> -[ ]*[a-f0-9]+: 66 0f 13 0d 78 56 34 12 movlpd %xmm1,0x12345678\(%rip\) # 123458d8 <_start\+0x123458d8> -[ ]*[a-f0-9]+: 66 0f 12 0d 78 56 34 12 movlpd 0x12345678\(%rip\),%xmm1 # 123458e0 <_start\+0x123458e0> -[ ]*[a-f0-9]+: 0f 13 0d 78 56 34 12 movlps %xmm1,0x12345678\(%rip\) # 123458e7 <_start\+0x123458e7> -[ ]*[a-f0-9]+: 0f 12 0d 78 56 34 12 movlps 0x12345678\(%rip\),%xmm1 # 123458ee <_start\+0x123458ee> -[ ]*[a-f0-9]+: 66 0f d6 0d 78 56 34 12 movq %xmm1,0x12345678\(%rip\) # 123458f6 <_start\+0x123458f6> -[ ]*[a-f0-9]+: f3 0f 7e 0d 78 56 34 12 movq 0x12345678\(%rip\),%xmm1 # 123458fe <_start\+0x123458fe> -[ ]*[a-f0-9]+: f3 0f 16 0d 78 56 34 12 movshdup 0x12345678\(%rip\),%xmm1 # 12345906 <_start\+0x12345906> -[ ]*[a-f0-9]+: f3 0f 12 0d 78 56 34 12 movsldup 0x12345678\(%rip\),%xmm1 # 1234590e <_start\+0x1234590e> -[ ]*[a-f0-9]+: f3 0f 70 0d 78 56 34 12 90 pshufhw \$0x90,0x12345678\(%rip\),%xmm1 # 12345917 <_start\+0x12345917> -[ ]*[a-f0-9]+: f2 0f 70 0d 78 56 34 12 90 pshuflw \$0x90,0x12345678\(%rip\),%xmm1 # 12345920 <_start\+0x12345920> -[ ]*[a-f0-9]+: 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%mm1 # 12345927 <_start\+0x12345927> -[ ]*[a-f0-9]+: 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%mm1 # 1234592e <_start\+0x1234592e> -[ ]*[a-f0-9]+: 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%mm1 # 12345935 <_start\+0x12345935> -[ ]*[a-f0-9]+: 66 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%xmm1 # 1234593d <_start\+0x1234593d> -[ ]*[a-f0-9]+: 66 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%xmm1 # 12345945 <_start\+0x12345945> -[ ]*[a-f0-9]+: 66 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%xmm1 # 1234594d <_start\+0x1234594d> -[ ]*[a-f0-9]+: 66 0f 6c 0d 78 56 34 12 punpcklqdq 0x12345678\(%rip\),%xmm1 # 12345955 <_start\+0x12345955> -[ ]*[a-f0-9]+: 66 0f 2e 0d 78 56 34 12 ucomisd 0x12345678\(%rip\),%xmm1 # 1234595d <_start\+0x1234595d> -[ ]*[a-f0-9]+: 0f 2e 0d 78 56 34 12 ucomiss 0x12345678\(%rip\),%xmm1 # 12345964 <_start\+0x12345964> +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%rax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%rax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f d0 0d 78 56 34 12 addsubps 0x12345678\(%rip\),%xmm1 # 12345880 <_start\+0x12345880> +[ ]*[a-f0-9]+: 66 0f 2f 0d 78 56 34 12 comisd 0x12345678\(%rip\),%xmm1 # 12345888 <_start\+0x12345888> +[ ]*[a-f0-9]+: 0f 2f 0d 78 56 34 12 comiss 0x12345678\(%rip\),%xmm1 # 1234588f <_start\+0x1234588f> +[ ]*[a-f0-9]+: f3 0f e6 0d 78 56 34 12 cvtdq2pd 0x12345678\(%rip\),%xmm1 # 12345897 <_start\+0x12345897> +[ ]*[a-f0-9]+: f2 0f e6 0d 78 56 34 12 cvtpd2dq 0x12345678\(%rip\),%xmm1 # 1234589f <_start\+0x1234589f> +[ ]*[a-f0-9]+: 0f 5a 0d 78 56 34 12 cvtps2pd 0x12345678\(%rip\),%xmm1 # 123458a6 <_start\+0x123458a6> +[ ]*[a-f0-9]+: f3 0f 5b 0d 78 56 34 12 cvttps2dq 0x12345678\(%rip\),%xmm1 # 123458ae <_start\+0x123458ae> +[ ]*[a-f0-9]+: f2 0f 7c 0d 78 56 34 12 haddps 0x12345678\(%rip\),%xmm1 # 123458b6 <_start\+0x123458b6> +[ ]*[a-f0-9]+: f3 0f 7f 0d 78 56 34 12 movdqu %xmm1,0x12345678\(%rip\) # 123458be <_start\+0x123458be> +[ ]*[a-f0-9]+: f3 0f 6f 0d 78 56 34 12 movdqu 0x12345678\(%rip\),%xmm1 # 123458c6 <_start\+0x123458c6> +[ ]*[a-f0-9]+: 66 0f 17 0d 78 56 34 12 movhpd %xmm1,0x12345678\(%rip\) # 123458ce <_start\+0x123458ce> +[ ]*[a-f0-9]+: 66 0f 16 0d 78 56 34 12 movhpd 0x12345678\(%rip\),%xmm1 # 123458d6 <_start\+0x123458d6> +[ ]*[a-f0-9]+: 0f 17 0d 78 56 34 12 movhps %xmm1,0x12345678\(%rip\) # 123458dd <_start\+0x123458dd> +[ ]*[a-f0-9]+: 0f 16 0d 78 56 34 12 movhps 0x12345678\(%rip\),%xmm1 # 123458e4 <_start\+0x123458e4> +[ ]*[a-f0-9]+: 66 0f 13 0d 78 56 34 12 movlpd %xmm1,0x12345678\(%rip\) # 123458ec <_start\+0x123458ec> +[ ]*[a-f0-9]+: 66 0f 12 0d 78 56 34 12 movlpd 0x12345678\(%rip\),%xmm1 # 123458f4 <_start\+0x123458f4> +[ ]*[a-f0-9]+: 0f 13 0d 78 56 34 12 movlps %xmm1,0x12345678\(%rip\) # 123458fb <_start\+0x123458fb> +[ ]*[a-f0-9]+: 0f 12 0d 78 56 34 12 movlps 0x12345678\(%rip\),%xmm1 # 12345902 <_start\+0x12345902> +[ ]*[a-f0-9]+: 66 0f d6 0d 78 56 34 12 movq %xmm1,0x12345678\(%rip\) # 1234590a <_start\+0x1234590a> +[ ]*[a-f0-9]+: f3 0f 7e 0d 78 56 34 12 movq 0x12345678\(%rip\),%xmm1 # 12345912 <_start\+0x12345912> +[ ]*[a-f0-9]+: f3 0f 16 0d 78 56 34 12 movshdup 0x12345678\(%rip\),%xmm1 # 1234591a <_start\+0x1234591a> +[ ]*[a-f0-9]+: f3 0f 12 0d 78 56 34 12 movsldup 0x12345678\(%rip\),%xmm1 # 12345922 <_start\+0x12345922> +[ ]*[a-f0-9]+: f3 0f 70 0d 78 56 34 12 90 pshufhw \$0x90,0x12345678\(%rip\),%xmm1 # 1234592b <_start\+0x1234592b> +[ ]*[a-f0-9]+: f2 0f 70 0d 78 56 34 12 90 pshuflw \$0x90,0x12345678\(%rip\),%xmm1 # 12345934 <_start\+0x12345934> +[ ]*[a-f0-9]+: 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%mm1 # 1234593b <_start\+0x1234593b> +[ ]*[a-f0-9]+: 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%mm1 # 12345942 <_start\+0x12345942> +[ ]*[a-f0-9]+: 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%mm1 # 12345949 <_start\+0x12345949> +[ ]*[a-f0-9]+: 66 0f 60 0d 78 56 34 12 punpcklbw 0x12345678\(%rip\),%xmm1 # 12345951 <_start\+0x12345951> +[ ]*[a-f0-9]+: 66 0f 62 0d 78 56 34 12 punpckldq 0x12345678\(%rip\),%xmm1 # 12345959 <_start\+0x12345959> +[ ]*[a-f0-9]+: 66 0f 61 0d 78 56 34 12 punpcklwd 0x12345678\(%rip\),%xmm1 # 12345961 <_start\+0x12345961> +[ ]*[a-f0-9]+: 66 0f 6c 0d 78 56 34 12 punpcklqdq 0x12345678\(%rip\),%xmm1 # 12345969 <_start\+0x12345969> +[ ]*[a-f0-9]+: 66 0f 2e 0d 78 56 34 12 ucomisd 0x12345678\(%rip\),%xmm1 # 12345971 <_start\+0x12345971> +[ ]*[a-f0-9]+: 0f 2e 0d 78 56 34 12 ucomiss 0x12345678\(%rip\),%xmm1 # 12345978 <_start\+0x12345978> [ ]*[a-f0-9]+: f2 0f c2 00 00 cmpeqsd \(%rax\),%xmm0 [ ]*[a-f0-9]+: f3 0f c2 00 00 cmpeqss \(%rax\),%xmm0 [ ]*[a-f0-9]+: 66 0f 2a 00 cvtpi2pd \(%rax\),%xmm0 @@ -181,4 +185,8 @@ Disassembly of section .text: [ ]*[a-f0-9]+: 0f 15 00 unpckhps \(%rax\),%xmm0 [ ]*[a-f0-9]+: 66 0f 14 00 unpcklpd \(%rax\),%xmm0 [ ]*[a-f0-9]+: 0f 14 00 unpcklps \(%rax\),%xmm0 +[ ]*[a-f0-9]+: f3 0f c2 f7 10 cmpss \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f3 0f c2 38 10 cmpss \$0x10,\(%rax\),%xmm7 +[ ]*[a-f0-9]+: f2 0f c2 f7 10 cmpsd \$0x10,%xmm7,%xmm6 +[ ]*[a-f0-9]+: f2 0f c2 38 10 cmpsd \$0x10,\(%rax\),%xmm7 #pass diff --git a/gas/testsuite/gas/i386/x86-64-simd.s b/gas/testsuite/gas/i386/x86-64-simd.s index 67bad4e..f14e6da 100644 --- a/gas/testsuite/gas/i386/x86-64-simd.s +++ b/gas/testsuite/gas/i386/x86-64-simd.s @@ -91,6 +91,11 @@ _start: unpcklpd (%rax),%xmm1 unpcklps (%rax),%xmm1 +cmpss $0x10,%xmm7,%xmm6 +cmpss $0x10,(%rax),%xmm7 +cmpsd $0x10,%xmm7,%xmm6 +cmpsd $0x10,(%rax),%xmm7 + .intel_syntax noprefix addsubps xmm1,XMMWORD PTR [rip+0x12345678] @@ -180,3 +185,7 @@ unpckhpd xmm0,XMMWORD PTR [rax] unpckhps xmm0,XMMWORD PTR [rax] unpcklpd xmm0,XMMWORD PTR [rax] unpcklps xmm0,XMMWORD PTR [rax] +cmpss xmm6,xmm7,0x10 +cmpss xmm7,DWORD PTR [rax],0x10 +cmpsd xmm6,xmm7,0x10 +cmpsd xmm7,QWORD PTR [rax],0x10 diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog index 9ca117e..169032c 100644 --- a/opcodes/ChangeLog +++ b/opcodes/ChangeLog @@ -1,3 +1,11 @@ +2007-10-23 H.J. Lu <hongjiu.lu@intel.com> + + * i386-dis.c (OP_SIMD_Suffix): Renamed to ... + (CMP_Fixup): This. Rewrite. + (OPSIMD): Renamed to ... + (CMP): This. Updated. + (prefix_table): Update PREFIX_0FC2 entry. + 2007-10-22 H.J. Lu <hongjiu.lu@intel.com> * i386-dis.c (prefix_table): Reordered by opcode. diff --git a/opcodes/i386-dis.c b/opcodes/i386-dis.c index e4b7285..4e52288 100644 --- a/opcodes/i386-dis.c +++ b/opcodes/i386-dis.c @@ -95,7 +95,7 @@ static void OP_Mwait (int, int); static void NOP_Fixup1 (int, int); static void NOP_Fixup2 (int, int); static void OP_3DNowSuffix (int, int); -static void OP_SIMD_Suffix (int, int); +static void CMP_Fixup (int, int); static void BadOp (void); static void REP_Fixup (int, int); static void CMPXCHG8B_Fixup (int, int); @@ -340,7 +340,7 @@ fetch_data (struct disassemble_info *info, bfd_byte *addr) #define EMCq { OP_EMC, q_mode } #define MXC { OP_MXC, 0 } #define OPSUF { OP_3DNowSuffix, 0 } -#define OPSIMD { OP_SIMD_Suffix, 0 } +#define CMP { CMP_Fixup, 0 } #define XMM0 { XMM_Fixup, 0 } /* Used handle "rep" prefix for string instructions. */ @@ -2091,10 +2091,10 @@ static const struct dis386 prefix_table[][4] = { /* PREFIX_0FC2 */ { - { "", { XM, EXx, OPSIMD } }, /* See OP_SIMD_SUFFIX. */ - { "", { XM, EXd, OPSIMD } }, - { "", { XM, EXx, OPSIMD } }, - { "", { XM, EXq, OPSIMD } }, + { "cmpps", { XM, EXx, CMP } }, + { "cmpss", { XM, EXd, CMP } }, + { "cmppd", { XM, EXx, CMP } }, + { "cmpsd", { XM, EXq, CMP } }, }, /* PREFIX_0FC7_REG_6 */ @@ -7737,42 +7737,28 @@ static const char *simd_cmp_op[] = { }; static void -OP_SIMD_Suffix (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED) +CMP_Fixup (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED) { unsigned int cmp_type; FETCH_DATA (the_info, codep + 1); - obufp = obuf + strlen (obuf); cmp_type = *codep++ & 0xff; if (cmp_type < 8) { - char suffix1 = 'p', suffix2 = 's'; - used_prefixes |= (prefixes & PREFIX_REPZ); - if (prefixes & PREFIX_REPZ) - suffix1 = 's'; - else - { - used_prefixes |= (prefixes & PREFIX_DATA); - if (prefixes & PREFIX_DATA) - suffix2 = 'd'; - else - { - used_prefixes |= (prefixes & PREFIX_REPNZ); - if (prefixes & PREFIX_REPNZ) - suffix1 = 's', suffix2 = 'd'; - } - } - sprintf (scratchbuf, "cmp%s%c%c", - simd_cmp_op[cmp_type], suffix1, suffix2); - used_prefixes |= (prefixes & PREFIX_REPZ); - oappend (scratchbuf); + char suffix [3]; + char *p = obuf + strlen (obuf) - 2; + suffix[0] = p[0]; + suffix[1] = p[1]; + suffix[2] = '\0'; + sprintf (p, "%s%s", simd_cmp_op[cmp_type], suffix); } else { - /* We have a bad extension byte. Clean up. */ - op_out[0][0] = '\0'; - op_out[1][0] = '\0'; - BadOp (); + /* We have a reserved extension byte. Output it directly. */ + scratchbuf[0] = '$'; + print_operand_value (scratchbuf + 1, 1, cmp_type); + oappend (scratchbuf + intel_syntax); + scratchbuf[0] = '\0'; } } |