Operand type A generally is converted to an immediate, except
for the LEAVE instruction.  The idea in the manual is that
d64 the operand type for the "POP EBP" part of the LEAVE, but
it does not really add much to the description in the table.
Just drop the operand so that all A-type operands are handled
as immediates.

Signed-off-by: Paolo Bonzini <[email protected]>
---
 target/i386/tcg/decode-new.h     | 1 -
 target/i386/tcg/decode-new.c.inc | 3 +--
 2 files changed, 1 insertion(+), 3 deletions(-)

diff --git a/target/i386/tcg/decode-new.h b/target/i386/tcg/decode-new.h
index f18c7afca87..5f76b0c1b7a 100644
--- a/target/i386/tcg/decode-new.h
+++ b/target/i386/tcg/decode-new.h
@@ -22,7 +22,6 @@
 typedef enum X86OpType {
     X86_TYPE_None,
 
-    X86_TYPE_A, /* Implicit */
     X86_TYPE_B, /* VEX.vvvv selects a GPR */
     X86_TYPE_C, /* REG in the modrm byte selects a control register */
     X86_TYPE_D, /* REG in the modrm byte selects a debug register */
diff --git a/target/i386/tcg/decode-new.c.inc b/target/i386/tcg/decode-new.c.inc
index fa0a5b1f4c3..3845fab5c85 100644
--- a/target/i386/tcg/decode-new.c.inc
+++ b/target/i386/tcg/decode-new.c.inc
@@ -1970,7 +1970,7 @@ static const X86OpEntry opcodes_root[256] = {
     [0xBF] = X86_OP_ENTRYwr(MOV, LoBits,v, I,v),
 
     [0xC8] = X86_OP_ENTRYrr(ENTER, I,w, I,b),
-    [0xC9] = X86_OP_ENTRY1(LEAVE, A,d64),
+    [0xC9] = X86_OP_ENTRY0(LEAVE),
     [0xCA] = X86_OP_ENTRYr(RETF,  I,w),
     [0xCB] = X86_OP_ENTRY0(RETF),
     [0xCC] = X86_OP_ENTRY0(INT3),
@@ -2548,7 +2548,6 @@ static bool decode_op(DisasContext *s, CPUX86State *env, 
X86DecodedInsn *decode,
 {
     switch (type) {
     case X86_TYPE_None:  /* Implicit or absent */
-    case X86_TYPE_A:  /* Implicit */
     case X86_TYPE_F:  /* EFLAGS/RFLAGS */
     case X86_TYPE_X:  /* string source */
     case X86_TYPE_Y:  /* string destination */
-- 
2.56.0


Reply via email to