diff graal/GraalCompiler/src/com/sun/c1x/ir/ArithmeticOp.java @ 2538:e1ba5a93e997

Clean up on Value class and LIRGenerator/LIRItem-related things.
author Thomas Wuerthinger <thomas@wuerthinger.net>
date Wed, 27 Apr 2011 20:13:54 +0200
parents 16b9a8b5ad39
children 0f9eeb15e636
line wrap: on
line diff
--- a/graal/GraalCompiler/src/com/sun/c1x/ir/ArithmeticOp.java	Wed Apr 27 19:53:46 2011 +0200
+++ b/graal/GraalCompiler/src/com/sun/c1x/ir/ArithmeticOp.java	Wed Apr 27 20:13:54 2011 +0200
@@ -36,6 +36,7 @@
 public final class ArithmeticOp extends Op2 {
 
     private FrameState stateBefore;
+    private boolean isStrictFP;
 
     /**
      * Creates a new arithmetic operation.
@@ -48,7 +49,7 @@
      */
     public ArithmeticOp(int opcode, CiKind kind, Value x, Value y, boolean isStrictFP, FrameState stateBefore) {
         super(kind, opcode, x, y);
-        initFlag(Flag.IsStrictFP, isStrictFP);
+        this.isStrictFP = isStrictFP;
         if (stateBefore != null) {
             // state before is only used in the case of a division or remainder,
             // and isn't needed if the zero check is redundant
@@ -60,10 +61,6 @@
                 } else {
                     this.stateBefore = stateBefore;
                 }
-                if (divisor != -1) {
-                    C1XMetrics.DivideSpecialChecksRedundant++;
-                    setFlag(Flag.NoDivSpecialCase);
-                }
             } else {
                 this.stateBefore = stateBefore;
             }
@@ -80,7 +77,7 @@
      * @return {@code true} if this instruction has strict fp semantics
      */
     public boolean isStrictFP() {
-        return checkFlag(Flag.IsStrictFP);
+        return isStrictFP;
     }
 
     /**
@@ -112,10 +109,6 @@
 
     @Override
     public void print(LogStream out) {
-        out.print(x()).
-             print(' ').
-             print(Bytecodes.operator(opcode)).
-             print(' ').
-             print(y());
+        out.print(x()).print(' ').print(Bytecodes.operator(opcode)).print(' ').print(y());
     }
 }