This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[binutils][2.25][objdump][ARM][PATCH 2/2] Backport Tests for 26-bit versions of teq, tst, cmn, cmp
- From: Andre Vieira <Andre dot SimoesDiasVieira at arm dot com>
- To: "binutils at sourceware dot org" <binutils at sourceware dot org>
- Date: Fri, 13 Nov 2015 09:33:45 +0000
- Subject: [binutils][2.25][objdump][ARM][PATCH 2/2] Backport Tests for 26-bit versions of teq, tst, cmn, cmp
- Authentication-results: sourceware.org; auth=none
In the previous series patch the testsuite is updated to test the
teq,tst,cmn and cmp instructions for later versions of the architecture.
However, the 'legacy' 26-bit versions of teq, test, cmn and cmp can
still be disassembled for armv5 and older. These tests were added to
make sure we keep testing this functionality and don't loose it without
going unnoticed.
This patch backports the fix from trunk to the binutils 2.25 branch.
The original patch is at:
https://sourceware.org/ml/binutils/2015-10/msg00166.html
gas/testsuite/ChangeLog:
2015-11-12 Andre Vieira <andre.simoesdiasvieira@arm.com>
Backport from mainline
2015-09-16 Andre Vieira <andre.simoesdiasvieira@arm.com>
* gas/arm/pinsn.s: New.
* gas/arm/pinsn.d: Likewise.
From 421e468713088de0205ee15025b04e416336a6fd Mon Sep 17 00:00:00 2001
From: Andre Simoes Dias Vieira <andsim01@arm.com>
Date: Thu, 12 Nov 2015 10:38:08 +0000
Subject: [PATCH] Backport Tests for 26-bit versions of teq,tst,cmn,cmp
---
gas/testsuite/gas/arm/pinsn.d | 24 ++++++++++++++++++++++++
gas/testsuite/gas/arm/pinsn.s | 16 ++++++++++++++++
2 files changed, 40 insertions(+)
create mode 100644 gas/testsuite/gas/arm/pinsn.d
create mode 100644 gas/testsuite/gas/arm/pinsn.s
diff --git a/gas/testsuite/gas/arm/pinsn.d b/gas/testsuite/gas/arm/pinsn.d
new file mode 100644
index 0000000000000000000000000000000000000000..b36cc566c551862f128412a5a47a7a1857095c15
--- /dev/null
+++ b/gas/testsuite/gas/arm/pinsn.d
@@ -0,0 +1,24 @@
+# name: 26-bit teq/cmn/tst/cmp instructions
+# objdump: -dr --prefix-addresses --show-raw-insn -marmv4
+# skip: *-*-*coff *-*-pe *-*-wince *-*-*aout* *-*-netbsd
+
+.*: +file format .*arm.*
+
+
+Disassembly of section .text:
+0+000 <[^>]*> e330f00a ? teqp r0, #10
+0+004 <[^>]*> e132f004 ? teqp r2, r4
+0+008 <[^>]*> e135f287 ? teqp r5, r7, lsl #5
+0+00c <[^>]*> e131f113 ? teqp r1, r3, lsl r1
+0+010 <[^>]*> e370f00a ? cmnp r0, #10
+0+014 <[^>]*> e172f004 ? cmnp r2, r4
+0+018 <[^>]*> e175f287 ? cmnp r5, r7, lsl #5
+0+01c <[^>]*> e171f113 ? cmnp r1, r3, lsl r1
+0+020 <[^>]*> e350f00a ? cmpp r0, #10
+0+024 <[^>]*> e152f004 ? cmpp r2, r4
+0+028 <[^>]*> e155f287 ? cmpp r5, r7, lsl #5
+0+02c <[^>]*> e151f113 ? cmpp r1, r3, lsl r1
+0+030 <[^>]*> e310f00a ? tstp r0, #10
+0+034 <[^>]*> e112f004 ? tstp r2, r4
+0+038 <[^>]*> e115f287 ? tstp r5, r7, lsl #5
+0+03c <[^>]*> e111f113 ? tstp r1, r3, lsl r1
diff --git a/gas/testsuite/gas/arm/pinsn.s b/gas/testsuite/gas/arm/pinsn.s
new file mode 100644
index 0000000000000000000000000000000000000000..d0afc4655acbd1cf2f29837785082d7c69088be1
--- /dev/null
+++ b/gas/testsuite/gas/arm/pinsn.s
@@ -0,0 +1,16 @@
+teqp r0, #10
+teqp r2, r4
+teqp r5, r7, lsl #5
+teqp r1, r3, lsl r1
+cmnp r0, #10
+cmnp r2, r4
+cmnp r5, r7, lsl #5
+cmnp r1, r3, lsl r1
+cmpp r0, #10
+cmpp r2, r4
+cmpp r5, r7, lsl #5
+cmpp r1, r3, lsl r1
+tstp r0, #10
+tstp r2, r4
+tstp r5, r7, lsl #5
+tstp r1, r3, lsl r1
--
1.9.1