|
| From: | Paolo Bonzini |
| Subject: | Re: [PATCH 03/17] target/i386: add core of new i386 decoder |
| Date: | Thu, 25 Aug 2022 08:37:41 +0200 |
| User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.12.0 |
On 8/25/22 02:12, Richard Henderson wrote:
Surely it would be just as readable as
static const X86OpEntry onebyte[256] = {
/*
* Table A-2: One-byte Opcode Map: 00H — F7H
*/
[0x00] = X86_OP_ENTRY2(ADD, E,b, G,b),
[0x01] = X86_OP_ENTRY2(ADD, E,v, G,v),
...
[0x10] = X86_OP_ENTRY2(ADC, E,b, G,b),
[0x11] = X86_OP_ENTRY2(ADC, E,v, G,v),
...
/*
* Table A-2: One-byte Opcode Map: 08H - FFH
*/
[0x08] = X86_OP_ENTRY2(OR, E,b, G,b),
[0x09] = X86_OP_ENTRY2(OR, E,v, G,v),
Oh, that's obvious in retrospect.I will probably keep bidimensional arrays for the various SSE prefixes, though.
Paolo
| [Prev in Thread] | Current Thread | [Next in Thread] |