From: Phil Blundell Date: Mon, 12 Feb 2001 21:16:23 +0000 (+0000) Subject: merge patch from HEAD to warn about bad ldrt/strt X-Git-Tag: binutils-2_11~62 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7c91cfeea811fa17e33741f079473695a8870827;p=thirdparty%2Fbinutils-gdb.git merge patch from HEAD to warn about bad ldrt/strt --- diff --git a/gas/ChangeLog b/gas/ChangeLog index c397b5fcdc9..d276be336e1 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,8 @@ +2001-02-12 Philip Blundell + + * config/tc-arm.c (do_ldst): Improve warnings for unpredictable + ldrt/strt instructions. + Mon Feb 12 17:44:08 CET 2001 Jan Hubicka * tc-i386.c (i386_displacement): Fix handling of diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c index e2e452efa66..514dba7598c 100644 --- a/gas/config/tc-arm.c +++ b/gas/config/tc-arm.c @@ -4323,9 +4323,16 @@ do_ldst (str, flags) if (ldst_extend (&str, halfword) == FAIL) return; if (conflict_reg) - as_warn (_("%s register same as write-back base"), - ((inst.instruction & LOAD_BIT) - ? _("destination") : _("source"))); + { + if (flags & TRANS_BIT) + as_warn (_("Rn and Rd must be different in %s"), + ((inst.instruction & LOAD_BIT) + ? "LDRT" : "STRT")); + else + as_warn (_("%s register same as write-back base"), + ((inst.instruction & LOAD_BIT) + ? _("destination") : _("source"))); + } } else { @@ -4346,8 +4353,15 @@ do_ldst (str, flags) } flags |= INDEX_UP; - if (! (flags & TRANS_BIT)) - pre_inc = 1; + if (flags & TRANS_BIT) + { + if (conflict_reg) + as_warn (_("Rn and Rd must be different in %s"), + ((inst.instruction & LOAD_BIT) + ? "LDRT" : "STRT")); + } + else + pre_inc = 1; } } else