From: Thomas Preudhomme <thomas.preudhomme@foss.arm.com>
To: Richard Earnshaw <richard.earnshaw@arm.com>,
Nick Clifton <nickc@redhat.com>, Alan Modra <amodra@gmail.com>,
"binutils@sourceware.org" <binutils@sourceware.org>
Subject: [PATCH, GAS] Enable conditional Armv8-M instructions
Date: Fri, 01 Dec 2017 14:42:00 -0000 [thread overview]
Message-ID: <0df79b37-ad12-8c76-53fd-fa2a0d30f9bf@foss.arm.com> (raw)
In-Reply-To: <f5ce1db9-6e36-84e8-66bc-1549a1a90951@foss.arm.com>
[-- Attachment #1: Type: text/plain, Size: 806 bytes --]
Hi,
Newly introduced instructions common to ARMv8-M Baseline and Mainline
are currently all marked as unconditional. However, all instructions but
sg (ie. blxns, bxns, tt, ttt, tta, ttat, vlldm and vlstm) do actually
support conditional execution. This patch fixes the definition of these
instructions accordingly.
ChangeLog entries are as follows:
*** gas/ChangeLog ***
2017-11-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
* config/tc-arm.c (insns): Make blxns, bxns, tt, ttt, tta, ttat, vlldm
and vlstm conditionally executable and reindent parameters.
* testsuite/gas/arm/archv8m-cmse-main.s: Add conditional version of
aforementionned instructions.
Testing: Testsuite run when targeting arm-none-eabi targets shows no
regressions.
Is this ok for master branch?
Best regards,
Thomas
[-- Attachment #2: enable_v8m_conditional_insns.patch --]
[-- Type: text/x-patch, Size: 1997 bytes --]
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index f224104f406724e26d3fb241f3be35e96fb8a15d..17eded3524fad042b65434c4a783de4ec69c4ade 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -21429,20 +21429,20 @@ static const struct asm_opcode insns[] =
#define ARM_VARIANT NULL
#undef THUMB_VARIANT
#define THUMB_VARIANT & arm_ext_v8m
- TUE("sg", 0, e97fe97f, 0, (), 0, noargs),
- TUE("blxns", 0, 4784, 1, (RRnpc), 0, t_blx),
- TUE("bxns", 0, 4704, 1, (RRnpc), 0, t_bx),
- TUE("tt", 0, e840f000, 2, (RRnpc, RRnpc), 0, tt),
- TUE("ttt", 0, e840f040, 2, (RRnpc, RRnpc), 0, tt),
- TUE("tta", 0, e840f080, 2, (RRnpc, RRnpc), 0, tt),
- TUE("ttat", 0, e840f0c0, 2, (RRnpc, RRnpc), 0, tt),
+ TUE("sg", 0, e97fe97f, 0, (), 0, noargs),
+ TCE("blxns", 0, 4784, 1, (RRnpc), 0, t_blx),
+ TCE("bxns", 0, 4704, 1, (RRnpc), 0, t_bx),
+ TCE("tt", 0, e840f000, 2, (RRnpc, RRnpc), 0, tt),
+ TCE("ttt", 0, e840f040, 2, (RRnpc, RRnpc), 0, tt),
+ TCE("tta", 0, e840f080, 2, (RRnpc, RRnpc), 0, tt),
+ TCE("ttat", 0, e840f0c0, 2, (RRnpc, RRnpc), 0, tt),
/* FP for ARMv8-M Mainline. Enabled for ARMv8-M Mainline because the
instructions behave as nop if no VFP is present. */
#undef THUMB_VARIANT
#define THUMB_VARIANT & arm_ext_v8m_main
- TUEc("vlldm", 0, ec300a00, 1, (RRnpc), rn),
- TUEc("vlstm", 0, ec200a00, 1, (RRnpc), rn),
+ TCE("vlldm", 0, ec300a00, 1, (RRnpc), 0, rn),
+ TCE("vlstm", 0, ec200a00, 1, (RRnpc), 0, rn),
};
#undef ARM_VARIANT
#undef THUMB_VARIANT
diff --git a/gas/testsuite/gas/arm/archv8m-cmse-main.s b/gas/testsuite/gas/arm/archv8m-cmse-main.s
index 871414fd19fe6fcd95284e2f7089275c696b716a..4f7ff5d9b1b22b35a49403f3795ce7bde0b5c023 100644
--- a/gas/testsuite/gas/arm/archv8m-cmse-main.s
+++ b/gas/testsuite/gas/arm/archv8m-cmse-main.s
@@ -2,5 +2,14 @@
.syntax unified
T:
-vlldm r1
-vlstm r2
+vlldm r1
+vlstm r2
+it ne
+blxnsne r4
+it ne
+bxnsne r4
+itttt ne
+ttane r0, r1
+ttane r8, r9
+ttatne r0, r1
+ttatne r8, r9
next prev parent reply other threads:[~2017-12-01 14:42 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-01 14:40 [PATCH, GAS] No IT usage deprecation for ARMv8-M Thomas Preudhomme
2017-12-01 14:42 ` Thomas Preudhomme [this message]
2017-12-01 14:50 ` [PATCH, GAS] Add new macro for Thumb-only opcodes Thomas Preudhomme
2017-12-18 13:37 ` Nick Clifton
2017-12-18 13:36 ` [PATCH, GAS] Enable conditional Armv8-M instructions Nick Clifton
2017-12-18 13:35 ` [PATCH, GAS] No IT usage deprecation for ARMv8-M Nick Clifton
2018-01-15 14:25 ` Thomas Preudhomme
2018-01-15 14:41 ` Thomas Preudhomme
2018-01-16 11:22 ` Nick Clifton
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0df79b37-ad12-8c76-53fd-fa2a0d30f9bf@foss.arm.com \
--to=thomas.preudhomme@foss.arm.com \
--cc=amodra@gmail.com \
--cc=binutils@sourceware.org \
--cc=nickc@redhat.com \
--cc=richard.earnshaw@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).