This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


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

Patch against i386.c committed


I've committed the following patch, and a matching testcase
(gcc.dg/991230-1.c).  Both were approved by Richard Henderson.
This showed up as a miscompilation of Quake.

Bernd

Index: ChangeLog
===================================================================
RCS file: /cvs/gcc/egcs/gcc/ChangeLog,v
retrieving revision 1.5312
diff -c -p -r1.5312 ChangeLog
*** ChangeLog	1999/12/30 05:58:56	1.5312
--- ChangeLog	1999/12/30 12:42:13
***************
*** 1,3 ****
--- 1,9 ----
+ 1999-12-30  Bernd Schmidt  <bernds@cygnus.co.uk>
+ 
+ 	* i386.c (ix86_expand_fp_compare): In non-sahf non-TARGET_IEEE
+ 	case, expand GT comparisons correctly.  Fix a comment before this
+ 	part of the code.
+ 
  1999-12-30  Gabriel Dos Reis  <dosreis@cmla.ens-cachan.fr>
  
  	* dwarfout.c: Include "frame.h"	
Index: config/i386/i386.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/config/i386/i386.c,v
retrieving revision 1.113
diff -c -p -r1.113 i386.c
*** i386.c	1999/12/20 13:18:16	1.113
--- i386.c	1999/12/30 12:42:19
*************** ix86_expand_fp_compare (code, op0, op1, 
*** 4077,4083 ****
  	    {
  	      /*
  	       * The numbers below correspond to the bits of the FPSW in AH.
! 	       * C3, C2, and C0 are in bits 0x40, 0x40, and 0x01 respectively.
  	       *
  	       *    cmp    C3 C2 C0
  	       *    >      0  0  0
--- 4077,4083 ----
  	    {
  	      /*
  	       * The numbers below correspond to the bits of the FPSW in AH.
! 	       * C3, C2, and C0 are in bits 0x40, 0x4, and 0x01 respectively.
  	       *
  	       *    cmp    C3 C2 C0
  	       *    >      0  0  0
*************** ix86_expand_fp_compare (code, op0, op1, 
*** 4091,4097 ****
  	      switch (code)
  		{
  		case GT:
! 		  mask = 0x01;
  		  code = EQ;
  		  break;
  		case LT:
--- 4091,4097 ----
  	      switch (code)
  		{
  		case GT:
! 		  mask = 0x41;
  		  code = EQ;
  		  break;
  		case LT:


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