[PATCH] MIPS/opcodes: Fix floor/round exclusions for R5900
Maciej W. Rozycki
macro@orcam.me.uk
Sat Jan 17 16:16:46 GMT 2026
On Sat, 17 Jan 2026, David Guillen Fandos wrote:
> Signed-off-by: David Guillen Fandos <david@davidgf.net>
This is missing a change description giving justification for the patch.
E.g. if the instructions are unimplemented, but were mistakenly included
with R5900 support, then please state so. Also is there any backing
documentation available?
> diff --git a/opcodes/mips-opc.c b/opcodes/mips-opc.c
> index 234e8bb3409..4a1e842b09c 100644
> --- a/opcodes/mips-opc.c
> +++ b/opcodes/mips-opc.c
> @@ -1206,7 +1206,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
> {"floor.l.d", "D,S", 0x4620000b, 0xffff003f, WR_1|RD_2|FP_D, 0, I3_33, 0, 0 },
> {"floor.l.s", "D,S", 0x4600000b, 0xffff003f, WR_1|RD_2|FP_S|FP_D, 0, I3_33, 0, 0 },
> {"floor.w.d", "D,S", 0x4620000f, 0xffff003f, WR_1|RD_2|FP_S|FP_D, 0, I2, 0, SF },
> -{"floor.w.s", "D,S", 0x4600000f, 0xffff003f, WR_1|RD_2|FP_S, 0, I2, 0, 0 },
> +{"floor.w.s", "D,S", 0x4600000f, 0xffff003f, WR_1|RD_2|FP_S, 0, I2, 0, EE },
^
While changing this line please correct `pinfo' flags to be preceded by a
tab rather than space, just as intended with this array and still with the
majority of elements.
> @@ -1823,7 +1823,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
> {"round.l.d", "D,S", 0x46200008, 0xffff003f, WR_1|RD_2|FP_D, 0, I3_33, 0, 0 },
> {"round.l.s", "D,S", 0x46000008, 0xffff003f, WR_1|RD_2|FP_S|FP_D, 0, I3_33, 0, 0 },
> {"round.w.d", "D,S", 0x4620000c, 0xffff003f, WR_1|RD_2|FP_S|FP_D, 0, I2, 0, SF },
> -{"round.w.s", "D,S", 0x4600000c, 0xffff003f, WR_1|RD_2|FP_S, 0, I2, 0, 0 },
> +{"round.w.s", "D,S", 0x4600000c, 0xffff003f, WR_1|RD_2|FP_S, 0, I2, 0, EE },
^
Likewise here.
There've been no regressions in my testing with this change in place so
it's otherwise OK.
Maciej
More information about the Binutils
mailing list