aboutsummaryrefslogtreecommitdiff
path: root/gas/testsuite
diff options
context:
space:
mode:
authorPeter Bergner <bergner@vnet.ibm.com>2013-01-11 02:25:36 +0000
committerPeter Bergner <bergner@vnet.ibm.com>2013-01-11 02:25:36 +0000
commit5817ffd1f81cf2d2ae173071775e6e620aa41283 (patch)
treeb2c4d4547a74f4de494daeae67436a970460e3d3 /gas/testsuite
parentca9c6ee2b7740e92a1630a9c7040eaba557bcd49 (diff)
downloadgdb-5817ffd1f81cf2d2ae173071775e6e620aa41283.zip
gdb-5817ffd1f81cf2d2ae173071775e6e620aa41283.tar.gz
gdb-5817ffd1f81cf2d2ae173071775e6e620aa41283.tar.bz2
include/opcode/
* ppc.h (PPC_OPCODE_POWER8): New define. (PPC_OPCODE_HTM): Likewise. opcodes/ * ppc-dis.c (ppc_opts): Add "power8", "pwr8" and "htm" entries. * ppc-opc.c (HTM_R, HTM_SI, XRTRB_MASK, XRTRARB_MASK, XRTLRARB_MASK, XRTARARB_MASK, XRTBFRARB_MASK, XRCL, POWER8, PPCHTM): New defines. (SH6): Update. <"tabort.", "tabortdc.", "tabortdci.", "tabortwc.", "tabortwci.", "tbegin.", "tcheck", "tend.", "trechkpt.", "treclaim.", "tsr.">: Add POWER8 HTM opcodes. <"tendall.", "tresume.", "tsuspend.">: Add POWER8 HTM extended opcodes. gas/ * doc/as.texinfo (Target PowerPC): Document -mpower8 and -mhtm. * doc/c-ppc.texi (PowerPC-Opts): Likewise. * config/tc-ppc.c (md_show_usage): Likewise. (ppc_handle_align): Handle power8's group ending nop. gas/testsuite/ * gas/ppc/htm.d: New test. * gas/ppc/htm.s: Likewise. * gas/ppc/power8.d: Likewise. * gas/ppc/power8.s: Likewise. * gas/ppc/ppc.exp: Run them.
Diffstat (limited to 'gas/testsuite')
-rw-r--r--gas/testsuite/ChangeLog8
-rw-r--r--gas/testsuite/gas/ppc/htm.d26
-rw-r--r--gas/testsuite/gas/ppc/htm.s19
-rw-r--r--gas/testsuite/gas/ppc/power8.d29
-rw-r--r--gas/testsuite/gas/ppc/power8.s21
-rw-r--r--gas/testsuite/gas/ppc/ppc.exp2
6 files changed, 105 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 22e1953..4e2d198 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,11 @@
+2013-01-10 Peter Bergner <bergner@vnet.ibm.com>
+
+ * gas/ppc/htm.d: New test.
+ * gas/ppc/htm.s: Likewise.
+ * gas/ppc/power8.d: Likewise.
+ * gas/ppc/power8.s: Likewise.
+ * gas/ppc/ppc.exp: Run them.
+
2013-01-10 Will Newton <will.newton@imgtec.com>
* gas/metag/labelarithmetic.d: New file.
diff --git a/gas/testsuite/gas/ppc/htm.d b/gas/testsuite/gas/ppc/htm.d
new file mode 100644
index 0000000..5eae6af
--- /dev/null
+++ b/gas/testsuite/gas/ppc/htm.d
@@ -0,0 +1,26 @@
+#as: -mhtm
+#objdump: -dr -Mhtm
+#name: Hardware Transactional Memory (HTM) tests
+
+.*: +file format elf(32)?(64)?-powerpc.*
+
+Disassembly of section \.text:
+
+0+00 <htm>:
+ 0: (7c 05 07 1d|1d 07 05 7c) tabort\. r5
+ 4: (7c e8 86 1d|1d 86 e8 7c) tabortwc\. 7,r8,r16
+ 8: (7e 8b 56 5d|5d 56 8b 7e) tabortdc\. 20,r11,r10
+ c: (7e 2a 9e 9d|9d 9e 2a 7e) tabortwci\. 17,r10,-13
+ 10: (7f a3 de dd|dd de a3 7f) tabortdci\. 29,r3,-5
+ 14: (7c 00 05 1d|1d 05 00 7c) tbegin\.
+ 18: (7f 80 05 9c|9c 05 80 7f) tcheck cr7
+ 1c: (7c 00 05 5d|5d 05 00 7c) tend\.
+ 20: (7c 00 05 5d|5d 05 00 7c) tend\.
+ 24: (7e 00 05 5d|5d 05 00 7e) tendall\.
+ 28: (7e 00 05 5d|5d 05 00 7e) tendall\.
+ 2c: (7c 18 07 5d|5d 07 18 7c) treclaim\. r24
+ 30: (7c 00 07 dd|dd 07 00 7c) trechkpt\.
+ 34: (7c 00 05 dd|dd 05 00 7c) tsuspend\.
+ 38: (7c 00 05 dd|dd 05 00 7c) tsuspend\.
+ 3c: (7c 20 05 dd|dd 05 20 7c) tresume\.
+ 40: (7c 20 05 dd|dd 05 20 7c) tresume\.
diff --git a/gas/testsuite/gas/ppc/htm.s b/gas/testsuite/gas/ppc/htm.s
new file mode 100644
index 0000000..362689b
--- /dev/null
+++ b/gas/testsuite/gas/ppc/htm.s
@@ -0,0 +1,19 @@
+ .section ".text"
+htm:
+ tabort. 5
+ tabortwc. 7,8,16
+ tabortdc. 20,11,10
+ tabortwci. 17,10,-13
+ tabortdci. 29,3,-5
+ tbegin. 0
+ tcheck 7
+ tend. 0
+ tend.
+ tend. 1
+ tendall.
+ treclaim. 24
+ trechkpt.
+ tsr. 0
+ tsuspend.
+ tsr. 1
+ tresume.
diff --git a/gas/testsuite/gas/ppc/power8.d b/gas/testsuite/gas/ppc/power8.d
new file mode 100644
index 0000000..8645280
--- /dev/null
+++ b/gas/testsuite/gas/ppc/power8.d
@@ -0,0 +1,29 @@
+#as: -mpower8
+#objdump: -dr -Mpower8
+#name: POWER8 tests (includes Altivec, VSX and HTM)
+
+.*: +file format elf(32)?(64)?-powerpc.*
+
+Disassembly of section \.text:
+
+0+00 <power8>:
+ 0: (7c 05 07 1d|1d 07 05 7c) tabort\. r5
+ 4: (7c e8 86 1d|1d 86 e8 7c) tabortwc\. 7,r8,r16
+ 8: (7e 8b 56 5d|5d 56 8b 7e) tabortdc\. 20,r11,r10
+ c: (7e 2a 9e 9d|9d 9e 2a 7e) tabortwci\. 17,r10,-13
+ 10: (7f a3 de dd|dd de a3 7f) tabortdci\. 29,r3,-5
+ 14: (7c 00 05 1d|1d 05 00 7c) tbegin\.
+ 18: (7f 80 05 9c|9c 05 80 7f) tcheck cr7
+ 1c: (7c 00 05 5d|5d 05 00 7c) tend\.
+ 20: (7c 00 05 5d|5d 05 00 7c) tend\.
+ 24: (7e 00 05 5d|5d 05 00 7e) tendall\.
+ 28: (7e 00 05 5d|5d 05 00 7e) tendall\.
+ 2c: (7c 18 07 5d|5d 07 18 7c) treclaim\. r24
+ 30: (7c 00 07 dd|dd 07 00 7c) trechkpt\.
+ 34: (7c 00 05 dd|dd 05 00 7c) tsuspend\.
+ 38: (7c 00 05 dd|dd 05 00 7c) tsuspend\.
+ 3c: (7c 20 05 dd|dd 05 20 7c) tresume\.
+ 40: (7c 20 05 dd|dd 05 20 7c) tresume\.
+ 44: (60 42 00 00|00 00 42 60) ori r2,r2,0
+ 48: (60 00 00 00|00 00 00 60) nop
+ 4c: (60 42 00 00|00 00 42 60) ori r2,r2,0
diff --git a/gas/testsuite/gas/ppc/power8.s b/gas/testsuite/gas/ppc/power8.s
new file mode 100644
index 0000000..dd67485
--- /dev/null
+++ b/gas/testsuite/gas/ppc/power8.s
@@ -0,0 +1,21 @@
+ .section ".text"
+power8:
+ tabort. 5
+ tabortwc. 7,8,16
+ tabortdc. 20,11,10
+ tabortwci. 17,10,-13
+ tabortdci. 29,3,-5
+ tbegin.
+ tcheck 7
+ tend. 0
+ tend.
+ tend. 1
+ tendall.
+ treclaim. 24
+ trechkpt.
+ tsr. 0
+ tsuspend.
+ tsr. 1
+ tresume.
+ ori 2,2,0
+ .p2align 4,,15
diff --git a/gas/testsuite/gas/ppc/ppc.exp b/gas/testsuite/gas/ppc/ppc.exp
index dd96200..b7f56b0 100644
--- a/gas/testsuite/gas/ppc/ppc.exp
+++ b/gas/testsuite/gas/ppc/ppc.exp
@@ -83,7 +83,9 @@ if { [istarget powerpc*-*-*] } then {
run_dump_test "power4_32"
run_dump_test "power6"
run_dump_test "power7"
+ run_dump_test "power8"
run_dump_test "vsx"
+ run_dump_test "htm"
run_dump_test "titan"
}
}