Fix FP GT comparisons on i386 with -ffast-math
authorBernd Schmidt <bernds@cygnus.co.uk>
Thu, 30 Dec 1999 12:43:51 +0000 (12:43 +0000)
committerBernd Schmidt <crux@gcc.gnu.org>
Thu, 30 Dec 1999 12:43:51 +0000 (12:43 +0000)
From-SVN: r31138

gcc/ChangeLog
gcc/config/i386/i386.c

index a26dfd269f093dc89e136f06eaa24e4d67842586..1282eb0ff582c2a8645704a76fd525e20c1da899 100644 (file)
@@ -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 18124b4f12dc7ff7f0d94ed38e2f5785b4491385..7952118175085d74119598d427c6161d31547901 100644 (file)
@@ -4077,7 +4077,7 @@ ix86_expand_fp_compare (code, op0, op1, unordered)
            {
              /*
               * The numbers below correspond to the bits of the FPSW in AH.
-              * C3, C2, and C0 are in bits 0x40, 0x40, and 0x01 respectively.
+              * C3, C2, and C0 are in bits 0x40, 0x4, and 0x01 respectively.
               *
               *    cmp    C3 C2 C0
               *    >      0  0  0
@@ -4091,7 +4091,7 @@ ix86_expand_fp_compare (code, op0, op1, unordered)
              switch (code)
                {
                case GT:
-                 mask = 0x01;
+                 mask = 0x41;
                  code = EQ;
                  break;
                case LT: