aboutsummaryrefslogtreecommitdiff
path: root/gas/testsuite
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@suse.com>2019-11-07 09:29:14 +0100
committerJan Beulich <jbeulich@suse.com>2019-11-07 09:29:14 +0100
commit142861dfd5b55fe4440c35351a068dcde4ad8ce9 (patch)
tree82f0a734706af0d57cd3e46d045d92e0bda78680 /gas/testsuite
parent081e283fafb415b4e37f2ac1d5f945ad0b61e282 (diff)
downloadgdb-142861dfd5b55fe4440c35351a068dcde4ad8ce9.zip
gdb-142861dfd5b55fe4440c35351a068dcde4ad8ce9.tar.gz
gdb-142861dfd5b55fe4440c35351a068dcde4ad8ce9.tar.bz2
x86: support further AMD Zen2 instructions
Both RDPRU and MCOMMIT have been publicly documented meanwhile: https://www.amd.com/system/files/TechDocs/24594.pdf.
Diffstat (limited to 'gas/testsuite')
-rw-r--r--gas/testsuite/gas/i386/arch-13-znver1.d28
-rw-r--r--gas/testsuite/gas/i386/arch-13-znver2.d26
-rw-r--r--gas/testsuite/gas/i386/arch-13.d4
-rw-r--r--gas/testsuite/gas/i386/arch-13.s6
-rw-r--r--gas/testsuite/gas/i386/x86-64-arch-3-znver1.d2
-rw-r--r--gas/testsuite/gas/i386/x86-64-arch-3.d4
-rw-r--r--gas/testsuite/gas/i386/x86-64-arch-3.s6
7 files changed, 22 insertions, 54 deletions
diff --git a/gas/testsuite/gas/i386/arch-13-znver1.d b/gas/testsuite/gas/i386/arch-13-znver1.d
index 8e84b5e..df7ebf5 100644
--- a/gas/testsuite/gas/i386/arch-13-znver1.d
+++ b/gas/testsuite/gas/i386/arch-13-znver1.d
@@ -1,29 +1,5 @@
#source: arch-13.s
-#as: -march=znver1+rdpid+clwb+wbnoinvd
+#as: -march=znver1+rdpid+clwb+wbnoinvd+rdpru+mcommit
#objdump: -dw
#name: i386 arch 13 (znver1)
-
-.*: file format .*
-
-Disassembly of section .text:
-
-0+ <.text>:
-[ ]*[a-f0-9]+: 0f 01 ca clac
-[ ]*[a-f0-9]+: 0f 01 cb stac
-[ ]*[a-f0-9]+: 66 0f 38 f6 ca adcx %edx,%ecx
-[ ]*[a-f0-9]+: f3 0f 38 f6 ca adox %edx,%ecx
-[ ]*[a-f0-9]+: 0f c7 f8 rdseed %eax
-[ ]*[a-f0-9]+: 0f 01 fc clzero
-[ ]*[a-f0-9]+: 0f c7 21 xsavec \(%ecx\)
-[ ]*[a-f0-9]+: 0f c7 29 xsaves \(%ecx\)
-[ ]*[a-f0-9]+: 66 0f ae 39 clflushopt \(%ecx\)
-[ ]*[a-f0-9]+: 0f 01 fa monitorx %eax,%ecx,%edx
-[ ]*[a-f0-9]+: 67 0f 01 fa monitorx %ax,%ecx,%edx
-[ ]*[a-f0-9]+: 0f 01 fa monitorx %eax,%ecx,%edx
-[ ]*[a-f0-9]+: 0f 01 fb mwaitx %eax,%ecx,%ebx
-[ ]*[a-f0-9]+: 0f 01 fb mwaitx %eax,%ecx,%ebx
-[ ]*[a-f0-9]+:[ ]*66 0f ae 31[ ]*clwb \(%ecx\)
-[ ]*[a-f0-9]+:[ ]*66 0f ae b4 f4 c0 1d fe ff[ ]*clwb -0x1e240\(%esp,%esi,8\)
-[ ]*[a-f0-9]+:[ ]*f3 0f c7 f8[ ]*rdpid %eax
-[ ]*[a-f0-9]+:[ ]*f3 0f 09[ ]*wbnoinvd[ ]*
-#pass
+#dump: arch-13.d
diff --git a/gas/testsuite/gas/i386/arch-13-znver2.d b/gas/testsuite/gas/i386/arch-13-znver2.d
index e780bf9..c410305 100644
--- a/gas/testsuite/gas/i386/arch-13-znver2.d
+++ b/gas/testsuite/gas/i386/arch-13-znver2.d
@@ -2,28 +2,4 @@
#as: -march=znver2
#objdump: -dw
#name: i386 arch 13 (znver2)
-
-.*: file format .*
-
-Disassembly of section .text:
-
-0+ <.text>:
-[ ]*[a-f0-9]+: 0f 01 ca clac[ ]*
-[ ]*[a-f0-9]+: 0f 01 cb stac[ ]*
-[ ]*[a-f0-9]+: 66 0f 38 f6 ca adcx %edx,%ecx
-[ ]*[a-f0-9]+: f3 0f 38 f6 ca adox %edx,%ecx
-[ ]*[a-f0-9]+: 0f c7 f8 rdseed %eax
-[ ]*[a-f0-9]+: 0f 01 fc clzero[ ]*
-[ ]*[a-f0-9]+: 0f c7 21 xsavec \(%ecx\)
-[ ]*[a-f0-9]+: 0f c7 29 xsaves \(%ecx\)
-[ ]*[a-f0-9]+: 66 0f ae 39 clflushopt \(%ecx\)
-[ ]*[a-f0-9]+: 0f 01 fa monitorx %eax,%ecx,%edx
-[ ]*[a-f0-9]+: 67 0f 01 fa monitorx %ax,%ecx,%edx
-[ ]*[a-f0-9]+: 0f 01 fa monitorx %eax,%ecx,%edx
-[ ]*[a-f0-9]+: 0f 01 fb mwaitx %eax,%ecx,%ebx
-[ ]*[a-f0-9]+: 0f 01 fb mwaitx %eax,%ecx,%ebx
-[ ]*[a-f0-9]+:[ ]*66 0f ae 31[ ]*clwb \(%ecx\)
-[ ]*[a-f0-9]+:[ ]*66 0f ae b4 f4 c0 1d fe ff[ ]*clwb -0x1e240\(%esp,%esi,8\)
-[ ]*[a-f0-9]+:[ ]*f3 0f c7 f8[ ]*rdpid %eax
-[ ]*[a-f0-9]+:[ ]*f3 0f 09[ ]*wbnoinvd[ ]*
-#pass
+#dump: arch-13.d
diff --git a/gas/testsuite/gas/i386/arch-13.d b/gas/testsuite/gas/i386/arch-13.d
index ad18c31..b9d79b4 100644
--- a/gas/testsuite/gas/i386/arch-13.d
+++ b/gas/testsuite/gas/i386/arch-13.d
@@ -1,4 +1,4 @@
-#as: -march=i686+smap+adx+rdseed+clzero+xsavec+xsaves+clflushopt+mwaitx+rdpid+clwb+wbnoinvd
+#as: -march=i686+smap+adx+rdseed+clzero+xsavec+xsaves+clflushopt+mwaitx+rdpid+clwb+wbnoinvd+rdpru+mcommit
#objdump: -dw
#name: i386 arch 13
@@ -23,6 +23,8 @@ Disassembly of section .text:
[ ]*[a-f0-9]+: 0f 01 fb mwaitx %eax,%ecx,%ebx
[ ]*[a-f0-9]+:[ ]*66 0f ae 31[ ]*clwb \(%ecx\)
[ ]*[a-f0-9]+:[ ]*66 0f ae b4 f4 c0 1d fe ff[ ]*clwb -0x1e240\(%esp,%esi,8\)
+[ ]*[a-f0-9]+:[ ]*f3 0f 01 fa[ ]*mcommit[ ]*
[ ]*[a-f0-9]+:[ ]*f3 0f c7 f8[ ]*rdpid %eax
+[ ]*[a-f0-9]+:[ ]*0f 01 fd[ ]*rdpru[ ]*
[ ]*[a-f0-9]+:[ ]*f3 0f 09[ ]*wbnoinvd[ ]*
#pass
diff --git a/gas/testsuite/gas/i386/arch-13.s b/gas/testsuite/gas/i386/arch-13.s
index 1766cc2..56d421b 100644
--- a/gas/testsuite/gas/i386/arch-13.s
+++ b/gas/testsuite/gas/i386/arch-13.s
@@ -27,8 +27,14 @@
clwb (%ecx) # CLWB
clwb -123456(%esp,%esi,8) # CLWB
+# mcommit instruction
+ mcommit
+
# rdpid instruction
rdpid %eax
+# rdpru instruction
+ rdpru
+
# wbnoinvd instruction
wbnoinvd
diff --git a/gas/testsuite/gas/i386/x86-64-arch-3-znver1.d b/gas/testsuite/gas/i386/x86-64-arch-3-znver1.d
index e5a6228..e7e62d9 100644
--- a/gas/testsuite/gas/i386/x86-64-arch-3-znver1.d
+++ b/gas/testsuite/gas/i386/x86-64-arch-3-znver1.d
@@ -1,5 +1,5 @@
#source: x86-64-arch-3.s
-#as: -march=znver1+rdpid+clwb+wbnoinvd
+#as: -march=znver1+rdpid+clwb+wbnoinvd+rdpru+mcommit
#objdump: -dw
#name: x86-64 arch 3 (znver1)
#dump: x86-64-arch-3.d
diff --git a/gas/testsuite/gas/i386/x86-64-arch-3.d b/gas/testsuite/gas/i386/x86-64-arch-3.d
index 9f5bd61..19d34fc 100644
--- a/gas/testsuite/gas/i386/x86-64-arch-3.d
+++ b/gas/testsuite/gas/i386/x86-64-arch-3.d
@@ -1,4 +1,4 @@
-#as: -march=generic64+smap+adx+rdseed+clzero+sha+xsavec+xsaves+clflushopt+mwaitx+rdpid+clwb+wbnoinvd
+#as: -march=generic64+smap+adx+rdseed+clzero+sha+xsavec+xsaves+clflushopt+mwaitx+rdpid+clwb+wbnoinvd+rdpru+mcommit
#objdump: -dw
#name: x86-64 arch 3
@@ -27,7 +27,9 @@ Disassembly of section .text:
[ ]*[a-f0-9]+: 0f 01 fb mwaitx %eax,%ecx,%ebx
[ ]*[a-f0-9]+:[ ]*66 0f ae 31[ ]*clwb \(%rcx\)
[ ]*[a-f0-9]+:[ ]*66 42 0f ae b4 f0 23 01 00 00[ ]*clwb 0x123\(%rax,%r14,8\)
+[ ]*[a-f0-9]+:[ ]*f3 0f 01 fa[ ]*mcommit[ ]*
[ ]*[a-f0-9]+:[ ]*f3 0f c7 f8[ ]*rdpid %rax
[ ]*[a-f0-9]+:[ ]*f3 41 0f c7 fa[ ]*rdpid %r10
+[ ]*[a-f0-9]+:[ ]*0f 01 fd[ ]*rdpru[ ]*
[ ]*[a-f0-9]+:[ ]*f3 0f 09[ ]*wbnoinvd[ ]*
#pass
diff --git a/gas/testsuite/gas/i386/x86-64-arch-3.s b/gas/testsuite/gas/i386/x86-64-arch-3.s
index 1f5a0e6..e002af4 100644
--- a/gas/testsuite/gas/i386/x86-64-arch-3.s
+++ b/gas/testsuite/gas/i386/x86-64-arch-3.s
@@ -30,9 +30,15 @@
clwb (%rcx) # CLWB
clwb 0x123(%rax,%r14,8) # CLWB
+# mcommit instruction
+ mcommit
+
# rdpid instruction
rdpid %rax
rdpid %r10
+# rdpru instruction
+ rdpru
+
# wbnoinvd instruction
wbnoinvd