This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [patch]: i386 gas, intel syntax and IgnoreSize modifier


On Fri, 11 Aug 2000, Alan Modra wrote:

> No.  Your patch removes suffix checking on many instructions, eg. all FP
> instructions, and will affect AT&T mode as well as Intel mode.  Please
> modify the patch to only affect Intel mode.
> 
OK, thanks. Here's a revised version. The first predicate is a
bit more verbose than it needs to be, but I find it simpler to
parse this way.


Wed Aug  9 16:28:21 EDT 2000	Diego Novillo <dnovillo@cygnus.com>

	* tc-i386.c (md_assemble): Skip suffix check if the opcode modifier
	has the IgnoreSize bit set in intel syntax mode.

Index: tc-i386.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-i386.c,v
retrieving revision 1.58
diff -d -c -p -r1.58 tc-i386.c
*** tc-i386.c	2000/08/04 18:43:45	1.58
--- tc-i386.c	2000/08/10 15:42:17
*************** md_assemble (line)
*** 1519,1524 ****
--- 1519,1526 ----
  	/* Check the suffix, except for some instructions in intel mode.  */
  	if ((t->opcode_modifier & suffix_check)
  	    && !(intel_syntax
+ 		 && (i.tm.opcode_modifier & IgnoreSize))
+ 	    && !(intel_syntax
  		 && t->base_opcode == 0xd9
  		 && (t->extension_opcode == 5	/* 0xd9,5 "fldcw"  */
  		     || t->extension_opcode == 7))) /* 0xd9,7 "f{n}stcw"  */
*************** md_assemble (line)
*** 1808,1813 ****
--- 1810,1818 ----
  		}
  #endif
  	  }
+ 	else if (intel_syntax && (i.tm.opcode_modifier & IgnoreSize))
+ 	  /* Do nothing if the instruction is going to ignore the prefix.  */
+ 	  ;
  	else
  	  abort ();
        }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]