[ARM, gas] Don't warn on REG_SP when used in CRC32 instructions
Jiong Wang
jiong.wang@foss.arm.com
Wed Aug 9 15:01:00 GMT 2017
Hi,
According to ARMv8-A architecture manual, REG_SP is allowed in CRC32 instructions
in Thumb mode. It is REG_PC that will cause unpredictable behaviours on both ARM
and Thumb.
This patch removes the incorrect warning on Thumb mode.
Meanwhile the disassembler is updated to use format "<bitfield>R" instead of
"<bitfield>S". "<bitfield>S" is not used elsewhere. so I have deleted related
code from the disassembler.
cross and native gas check OK.
OK for master and backport to 2.28 and 2.29?
Thanks.
2017-08-09 Jiong Wang <jiong.wang@arm.com>
opcodes/
* arm-dis.c (thumb32_opcodes): Use format 'R' instead of 'S' for
register operands in CRC instructions.
(print_insn_thumb32): Remove "<bitfield>S" support. Updated the
comments.
gas/
* config/tc-arm.c (do_crc32_1): Remove warning on REG_SP for thumb_mode.
* testsuite/gas/arm/crc32-armv8-a-bad.d: Update exepcted result.
* testsuite/gas/arm/crc32-armv8-r-bad.d: Likewise
* testsuite/gas/arm/crc32-armv8-a.d: Likewise
* testsuite/gas/arm/crc32-armv8-r.d: Likewise
* testsuite/gas/arm/crc32-armv8-ar-bad.s: Update test case.
* testsuite/gas/arm/crc32-armv8-ar.s: Likewise
* testsuite/gas/arm/crc32-bad.l: Update expected error message.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix.patch
Type: text/x-patch
Size: 8987 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20170809/a9832955/attachment.bin>
More information about the Binutils
mailing list