changeset 14854:64e6a5484cac

Fix style issues.
author Josef Eisl <josef.eisl@jku.at>
date Thu, 27 Mar 2014 16:21:14 +0100
parents 6bde7deb5be1
children 3a855006bf28
files graal/com.oracle.graal.api.meta/src/com/oracle/graal/api/meta/KindInterface.java graal/com.oracle.graal.baseline/src/com/oracle/graal/baseline/LIRControlFlowGraph.java graal/com.oracle.graal.baseline/src/com/oracle/graal/baseline/LIRFrameStateBuilder.java graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/LIRGenerator.java graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/NodeLIRGenerator.java graal/com.oracle.graal.hotspot.amd64/src/com/oracle/graal/hotspot/amd64/AMD64HotSpotNodeLIRGenerator.java graal/com.oracle.graal.java/src/com/oracle/graal/java/AbstractFrameStateBuilder.java graal/com.oracle.graal.java/src/com/oracle/graal/java/BytecodeParseHelper.java graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/cfg/BlocksToDoubles.java graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/spi/ArithmeticLIRGenerator.java graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/spi/NodeMappableLIRGenerator.java
diffstat 11 files changed, 150 insertions(+), 53 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.api.meta/src/com/oracle/graal/api/meta/KindInterface.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.api.meta/src/com/oracle/graal/api/meta/KindInterface.java	Thu Mar 27 16:21:14 2014 +0100
@@ -1,7 +1,30 @@
+/*
+ * Copyright (c) 2014, 2014, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
 package com.oracle.graal.api.meta;
 
 public interface KindInterface {
 
-    public Kind getKind();
+    Kind getKind();
 
 }
--- a/graal/com.oracle.graal.baseline/src/com/oracle/graal/baseline/LIRControlFlowGraph.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.baseline/src/com/oracle/graal/baseline/LIRControlFlowGraph.java	Thu Mar 27 16:21:14 2014 +0100
@@ -44,8 +44,9 @@
     }
 
     public BciBlock getStartBlock() {
-        if (blocks.length > 0)
+        if (blocks.length > 0) {
             return blocks[0];
+        }
         return null;
     }
 
--- a/graal/com.oracle.graal.baseline/src/com/oracle/graal/baseline/LIRFrameStateBuilder.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.baseline/src/com/oracle/graal/baseline/LIRFrameStateBuilder.java	Thu Mar 27 16:21:14 2014 +0100
@@ -1,3 +1,26 @@
+/*
+ * Copyright (c) 2014, 2014, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
 package com.oracle.graal.baseline;
 
 import com.oracle.graal.api.meta.*;
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/LIRGenerator.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/LIRGenerator.java	Thu Mar 27 16:21:14 2014 +0100
@@ -144,7 +144,7 @@
     protected LIRGenerationResult res;
 
     /**
-     * set this before using the LIRGenerator
+     * Set this before using the LIRGenerator.
      *
      * TODO this should be removed
      */
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/NodeLIRGenerator.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/gen/NodeLIRGenerator.java	Thu Mar 27 16:21:14 2014 +0100
@@ -234,24 +234,6 @@
         }
     }
 
-    /**
-     * For Baseline compilation
-     */
-
-    public <T extends AbstractBlock<T>> void doBlock(T block, ResolvedJavaMethod method, BytecodeParser<T> parser) {
-        doBlockStart(block);
-
-        if (block == res.getLIR().getControlFlowGraph().getStartBlock()) {
-            assert block.getPredecessorCount() == 0;
-            emitPrologue(method, parser);
-        } else {
-            assert block.getPredecessorCount() > 0;
-        }
-        parser.processBlock(block);
-
-        doBlockEnd(block);
-    }
-
     public void doBlock(Block block, StructuredGraph graph, BlockMap<List<ScheduledNode>> blockMap) {
         doBlockStart(block);
 
--- a/graal/com.oracle.graal.hotspot.amd64/src/com/oracle/graal/hotspot/amd64/AMD64HotSpotNodeLIRGenerator.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.hotspot.amd64/src/com/oracle/graal/hotspot/amd64/AMD64HotSpotNodeLIRGenerator.java	Thu Mar 27 16:21:14 2014 +0100
@@ -196,12 +196,12 @@
             address = new AMD64AddressValue(kind, gen.load(operand(x.object())), gen.load(index), Scale.Times1, disp);
         }
 
-        RegisterValue rax_local = AMD64.rax.asValue(kind);
-        gen.emitMove(rax_local, expected);
-        append(new CompareAndSwapOp(rax_local, address, rax_local, newVal));
+        RegisterValue raxLocal = AMD64.rax.asValue(kind);
+        gen.emitMove(raxLocal, expected);
+        append(new CompareAndSwapOp(raxLocal, address, raxLocal, newVal));
 
         Variable result = newVariable(x.getKind());
-        gen.emitMove(result, rax_local);
+        gen.emitMove(result, raxLocal);
         setResult(x, result);
     }
 
--- a/graal/com.oracle.graal.java/src/com/oracle/graal/java/AbstractFrameStateBuilder.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.java/src/com/oracle/graal/java/AbstractFrameStateBuilder.java	Thu Mar 27 16:21:14 2014 +0100
@@ -1,3 +1,26 @@
+/*
+ * Copyright (c) 2014, 2014, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
 package com.oracle.graal.java;
 
 import com.oracle.graal.api.meta.*;
@@ -17,7 +40,7 @@
 
     /**
      * Returns the size of the local variables.
-     * 
+     *
      * @return the size of the local variables
      */
     public abstract int localsSize();
@@ -31,7 +54,7 @@
 
     /**
      * Gets the value in the local variables at the specified index, without any sanity checking.
-     * 
+     *
      * @param i the index into the locals
      * @return the instruction that produced the value for the specified local
      */
@@ -39,7 +62,7 @@
 
     /**
      * Get the value on the stack at the specified stack index.
-     * 
+     *
      * @param i the index into the stack, with {@code 0} being the bottom of the stack
      * @return the instruction at the specified position in the stack
      */
@@ -48,7 +71,7 @@
     /**
      * Loads the local variable at the specified index, checking that the returned value is non-null
      * and that two-stack values are properly handled.
-     * 
+     *
      * @param i the index of the local variable to load
      * @return the instruction that produced the specified local
      */
@@ -57,7 +80,7 @@
     /**
      * Stores a given local variable at the specified index. If the value occupies two slots, then
      * the next local variable index is also overwritten.
-     * 
+     *
      * @param i the index at which to store
      * @param x the instruction which produces the value for the local
      */
@@ -67,7 +90,7 @@
 
     /**
      * Pushes an instruction onto the stack with the expected type.
-     * 
+     *
      * @param kind the type expected for this instruction
      * @param x the instruction to push onto the stack
      */
@@ -75,42 +98,42 @@
 
     /**
      * Pushes a value onto the stack without checking the type.
-     * 
+     *
      * @param x the instruction to push onto the stack
      */
     public abstract void xpush(T x);
 
     /**
      * Pushes a value onto the stack and checks that it is an int.
-     * 
+     *
      * @param x the instruction to push onto the stack
      */
     public abstract void ipush(T x);
 
     /**
      * Pushes a value onto the stack and checks that it is a float.
-     * 
+     *
      * @param x the instruction to push onto the stack
      */
     public abstract void fpush(T x);
 
     /**
      * Pushes a value onto the stack and checks that it is an object.
-     * 
+     *
      * @param x the instruction to push onto the stack
      */
     public abstract void apush(T x);
 
     /**
      * Pushes a value onto the stack and checks that it is a long.
-     * 
+     *
      * @param x the instruction to push onto the stack
      */
     public abstract void lpush(T x);
 
     /**
      * Pushes a value onto the stack and checks that it is a double.
-     * 
+     *
      * @param x the instruction to push onto the stack
      */
     public abstract void dpush(T x);
@@ -119,7 +142,7 @@
 
     /**
      * Pops an instruction off the stack with the expected type.
-     * 
+     *
      * @param kind the expected type
      * @return the instruction on the top of the stack
      */
@@ -127,42 +150,42 @@
 
     /**
      * Pops a value off of the stack without checking the type.
-     * 
+     *
      * @return x the instruction popped off the stack
      */
     public abstract T xpop();
 
     /**
      * Pops a value off of the stack and checks that it is an int.
-     * 
+     *
      * @return x the instruction popped off the stack
      */
     public abstract T ipop();
 
     /**
      * Pops a value off of the stack and checks that it is a float.
-     * 
+     *
      * @return x the instruction popped off the stack
      */
     public abstract T fpop();
 
     /**
      * Pops a value off of the stack and checks that it is an object.
-     * 
+     *
      * @return x the instruction popped off the stack
      */
     public abstract T apop();
 
     /**
      * Pops a value off of the stack and checks that it is a long.
-     * 
+     *
      * @return x the instruction popped off the stack
      */
     public abstract T lpop();
 
     /**
      * Pops a value off of the stack and checks that it is a double.
-     * 
+     *
      * @return x the instruction popped off the stack
      */
     public abstract T dpop();
@@ -170,14 +193,14 @@
     /**
      * Pop the specified number of slots off of this stack and return them as an array of
      * instructions.
-     * 
+     *
      * @return an array containing the arguments off of the stack
      */
     public abstract T[] popArguments(int slotSize, int argSize);
 
     /**
      * Peeks an element from the operand stack.
-     * 
+     *
      * @param argumentNumber The number of the argument, relative from the top of the stack (0 =
      *            top). Long and double arguments only count as one argument, i.e., null-slots are
      *            ignored.
--- a/graal/com.oracle.graal.java/src/com/oracle/graal/java/BytecodeParseHelper.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.java/src/com/oracle/graal/java/BytecodeParseHelper.java	Thu Mar 27 16:21:14 2014 +0100
@@ -1,3 +1,26 @@
+/*
+ * Copyright (c) 2014, 2014, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
 package com.oracle.graal.java;
 
 import static com.oracle.graal.bytecode.Bytecodes.*;
--- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/cfg/BlocksToDoubles.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/cfg/BlocksToDoubles.java	Thu Mar 27 16:21:14 2014 +0100
@@ -59,7 +59,7 @@
         return blockProbabilities;
     }
 
-    static private boolean verify(NodesToDoubles nodeProbabilities, ControlFlowGraph cfg, BlocksToDoubles blockProbabilities) {
+    private static boolean verify(NodesToDoubles nodeProbabilities, ControlFlowGraph cfg, BlocksToDoubles blockProbabilities) {
         for (Block b : cfg.getBlocks()) {
             double p = blockProbabilities.get(b);
             for (FixedNode n : b.getNodes()) {
--- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/spi/ArithmeticLIRGenerator.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/spi/ArithmeticLIRGenerator.java	Thu Mar 27 16:21:14 2014 +0100
@@ -45,22 +45,22 @@
     Value emitMul(Value a, Value b);
 
     /**
-     * TODO remove {@link DeoptimizeNode}
+     * TODO remove {@link DeoptimizeNode}.
      */
     Value emitDiv(Value a, Value b, DeoptimizingNode deopting);
 
     /**
-     * TODO remove {@link DeoptimizeNode}
+     * TODO remove {@link DeoptimizeNode}.
      */
     Value emitRem(Value a, Value b, DeoptimizingNode deopting);
 
     /**
-     * TODO remove {@link DeoptimizeNode}
+     * TODO remove {@link DeoptimizeNode}.
      */
     Value emitUDiv(Value a, Value b, DeoptimizingNode deopting);
 
     /**
-     * TODO remove {@link DeoptimizeNode}
+     * TODO remove {@link DeoptimizeNode}.
      */
     Value emitURem(Value a, Value b, DeoptimizingNode deopting);
 
--- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/spi/NodeMappableLIRGenerator.java	Thu Mar 27 15:55:08 2014 +0100
+++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/spi/NodeMappableLIRGenerator.java	Thu Mar 27 16:21:14 2014 +0100
@@ -1,3 +1,26 @@
+/*
+ * Copyright (c) 2014, 2014, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
 package com.oracle.graal.nodes.spi;
 
 import com.oracle.graal.api.meta.*;
@@ -10,5 +33,4 @@
     boolean hasOperand(ValueNode object);
 
     Value setResult(ValueNode x, Value operand);
-
-}
\ No newline at end of file
+}