From 9afe6eb82f6abc63f7235771b803497ebb6455f2 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Fri, 17 Jul 2009 17:08:34 +0000 Subject: 2009-07-17 H.J. Lu * config/tc-i386.c (md_assemble): Check implicit registers only for instructions with 3 operands or less. --- gas/config/tc-i386.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'gas/config') diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c index f4660b4..0862ab0 100644 --- a/gas/config/tc-i386.c +++ b/gas/config/tc-i386.c @@ -2821,12 +2821,15 @@ md_assemble (char *line) if (i.types[0].bitfield.imm1) i.imm_operands = 0; /* kludge for shift insns. */ - for (j = 0; j < i.operands; j++) - if (i.types[j].bitfield.inoutportreg - || i.types[j].bitfield.shiftcount - || i.types[j].bitfield.acc - || i.types[j].bitfield.floatacc) - i.reg_operands--; + /* We only need to check those implicit registers for instructions + with 3 operands or less. */ + if (i.operands <= 3) + for (j = 0; j < i.operands; j++) + if (i.types[j].bitfield.inoutportreg + || i.types[j].bitfield.shiftcount + || i.types[j].bitfield.acc + || i.types[j].bitfield.floatacc) + i.reg_operands--; /* ImmExt should be processed after SSE2AVX. */ if (!i.tm.opcode_modifier.sse2avx -- cgit v1.1