[PATCH 1/2] x86: infer operand count of templates

H.J. Lu hjl.tools@gmail.com
Tue Mar 2 16:35:25 GMT 2021


On Tue, Mar 02, 2021 at 05:09:31PM +0100, Jan Beulich wrote:
> Having this count explicitly in the table is redundant and (even if just
> slightly) disturbs clarity. Infer the count from the number of operands
> actually found.
> 
> Also convert the "no operands" indicator from "{ 0 }" to just "{}", as
> that (now) ends up being easier to parse.
> 
> opcodes/
> 2021-03-XX  Jan Beulich  <jbeulich@suse.com>
> 
> 	* i386-gen.c (output_i386_opcode): Don't get operand count. Look
> 	for {} instead of {0}. Don't look for '0'.
> 	* i386-opc.tbl: Drop operand count field. Drop redundant operand
> 	size specifiers.

OK.

> ---
> TBD: Do we want to do the same for the opcode length field, which can
>      also be inferred?
> 

Yes.

Thanks.

H.J.


More information about the Binutils mailing list