aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorTom Rix <tom@bumblecow.com>2015-09-28 12:09:32 +0930
committerAlan Modra <amodra@gmail.com>2015-09-28 12:09:51 +0930
commit36f7a9411dcd7dbeb3483bc83a1acbb3dd235deb (patch)
treeb3b4c20efadd3469c7c47c045a469de15616ec56 /gas
parentf1b383b81a2e837d6b06656896a4753aac449803 (diff)
downloadgdb-36f7a9411dcd7dbeb3483bc83a1acbb3dd235deb.zip
gdb-36f7a9411dcd7dbeb3483bc83a1acbb3dd235deb.tar.gz
gdb-36f7a9411dcd7dbeb3483bc83a1acbb3dd235deb.tar.bz2
Patches for illegal ppc 500 instructions
This change marks a few opcodes as invalid for ppc e500 as well as adds a test to verify the change.
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/ChangeLog6
-rw-r--r--gas/testsuite/gas/ppc/e500-ill.l8
-rw-r--r--gas/testsuite/gas/ppc/e500-ill.s11
-rw-r--r--gas/testsuite/gas/ppc/ppc.exp1
4 files changed, 26 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index f6f8b37..c770a29 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,9 @@
+2015-09-28 Tom Rix <tom@bumblecow.com>
+
+ * gas/ppc/e500-ill.s: New testcase for illegal ppc e500 ops.
+ * gas/ppc/e500-ill.l: Expected results.
+ * gas/ppc/ppc.exp: Run it.
+
2015-08-25 Jose E. Marchesi <jose.marchesi@oracle.com>
* gas/sparc/wrpr.s: Test writing to the privileged %pmcdper
diff --git a/gas/testsuite/gas/ppc/e500-ill.l b/gas/testsuite/gas/ppc/e500-ill.l
new file mode 100644
index 0000000..f62f762
--- /dev/null
+++ b/gas/testsuite/gas/ppc/e500-ill.l
@@ -0,0 +1,8 @@
+.*: Assembler messages:
+.*:5: Error: unrecognized opcode: `eciwx'
+.*:6: Error: unrecognized opcode: `ecowx'
+.*:7: Error: unrecognized opcode: `mfapidi'
+.*:8: Error: unrecognized opcode: `mfdcr'
+.*:9: Error: unrecognized opcode: `mtdcr'
+.*:10: Error: unrecognized opcode: `tlbia'
+.*:11: Error: unrecognized opcode: `tlbie'
diff --git a/gas/testsuite/gas/ppc/e500-ill.s b/gas/testsuite/gas/ppc/e500-ill.s
new file mode 100644
index 0000000..890faf6
--- /dev/null
+++ b/gas/testsuite/gas/ppc/e500-ill.s
@@ -0,0 +1,11 @@
+# Motorola PowerPC e500 illegal instructions
+ .text
+ .machine e500
+start:
+ eciwx 3,4,5
+ ecowx 3,4,5
+ mfapidi 5, 6
+ mfdcr 5, 234
+ mtdcr 432, 8
+ tlbia
+ tlbie 3
diff --git a/gas/testsuite/gas/ppc/ppc.exp b/gas/testsuite/gas/ppc/ppc.exp
index f333c52..df91f36 100644
--- a/gas/testsuite/gas/ppc/ppc.exp
+++ b/gas/testsuite/gas/ppc/ppc.exp
@@ -72,6 +72,7 @@ if { [istarget powerpc*-*-*] } then {
run_dump_test "altivec_and_spe"
run_dump_test "booke"
run_dump_test "e500"
+ run_list_test "e500-ill"
run_list_test "range" "-a32"
run_dump_test "ppc750ps"
run_dump_test "e500mc"