[PATCH] i386: Check invalid (%dx) usage
Jan Beulich
jbeulich@suse.com
Mon Nov 7 09:55:27 GMT 2022
On 04.11.2022 21:55, H.J. Lu via Binutils wrote:
> (%dx) isn't a valid memory address in any modes. It is used as a special
> memory operand for input/output port address in AT&T syntax and should
> only be used with input/output instructions. Update i386_att_operand to
> set i.input_output_operand to true for (%dx) and issue an error if (%dx)
> is used with non-input/output instructions.
Hmm, this shouldn't require a new flag I would hope. We did properly reject
bad uses up to 2.31 ("operand type mismatch"). Whatever was broken there
would need correcting instead, imo. A possible candidate looks to be
2fb5be8dac9d ("x86: drop {,reg16_}inoutportreg variables"), albeit perhaps
combined with later changes - in 2.33 behavior changed again.
Jan
More information about the Binutils
mailing list