[committed] arm: remove incorrect handling of FP bignums in move_or_literal_pool
Richard Earnshaw
rearnsha@arm.com
Thu May 16 10:14:59 GMT 2024
This hunk of code in move_or_literal_pool just looks wrong, but I
can't find a testcase that will tickle it to prove it. It looks a bit
like it was intended to catch cases where a bignum contained a
floating-point value, but there were a number of problems with it.
- It tested X_add_number == -1, but an FP bignum is indicated by any
value <= 0.
- It converted the floating-point value to extended precision, but
that's not used on Arm beyond the legacy FPA code. No attempt was
made to match the FP value to the intended memory/mov operation.
Since I can't construct a viable testcase, I've just removed the
existing code and made the function error out in this case: this seems
more sensible than generating wrong code or trying to write something
more complex that can't be tested anyway.
---
gas/config/tc-arm.c | 30 ++++++++++++++++++++++++------
1 file changed, 24 insertions(+), 6 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-arm-remove-incorrect-handling-of-FP-bignums-in-move_.patch
Type: text/x-patch
Size: 1459 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20240516/6c7dddd0/attachment.bin>
More information about the Binutils
mailing list