aboutsummaryrefslogtreecommitdiff
path: root/gas/config
diff options
context:
space:
mode:
authorDaniel Gutson <dgutson@codesourcery.com>2010-02-23 18:04:14 +0000
committerDaniel Gutson <dgutson@codesourcery.com>2010-02-23 18:04:14 +0000
commit56adecf405963c4b283d0b8297236525ab5f374a (patch)
tree7331f2a1e0dd5e54a7de08d6ddf27b7d41a78164 /gas/config
parentca419a6f33e27d59324ba74c4655e551a381aad5 (diff)
downloadgdb-56adecf405963c4b283d0b8297236525ab5f374a.zip
gdb-56adecf405963c4b283d0b8297236525ab5f374a.tar.gz
gdb-56adecf405963c4b283d0b8297236525ab5f374a.tar.bz2
gas/
* config/tc-arm.c (do_rd_rm_rn): Added warning. gas/testsuite/ * gas/arm/depr-swp.d: New test case. * gas/arm/depr-swp.s: New file. * gas/arm/depr-swp.l: New file.
Diffstat (limited to 'gas/config')
-rw-r--r--gas/config/tc-arm.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index b3096c5..7ef0f44 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -6970,8 +6970,16 @@ do_rd_rm_rn (void)
unsigned Rn = inst.operands[2].reg;
/* Enforce restrictions on SWP instruction. */
if ((inst.instruction & 0x0fbfffff) == 0x01000090)
- constraint (Rn == inst.operands[0].reg || Rn == inst.operands[1].reg,
- _("Rn must not overlap other operands"));
+ {
+ constraint (Rn == inst.operands[0].reg || Rn == inst.operands[1].reg,
+ _("Rn must not overlap other operands"));
+
+ /* SWP{b} is deprecated for ARMv6* and ARMv7. */
+ if (warn_on_deprecated
+ && ARM_CPU_HAS_FEATURE (selected_cpu, arm_ext_v6))
+ as_warn (_("swp{b} use is deprecated for this architecture"));
+
+ }
inst.instruction |= inst.operands[0].reg << 12;
inst.instruction |= inst.operands[1].reg;
inst.instruction |= Rn << 16;