changeset 18929:8f2fb6bec986

removed GPU code
author Doug Simon <doug.simon@oracle.com>
date Fri, 23 Jan 2015 10:54:21 +0100
parents c8fc6e2d128b
children 9aa1cff041eb
files graal/com.oracle.graal.asm.hsail/src/com/oracle/graal/asm/hsail/AbstractHSAILAssembler.java graal/com.oracle.graal.asm.hsail/src/com/oracle/graal/asm/hsail/HSAILAddress.java graal/com.oracle.graal.asm.hsail/src/com/oracle/graal/asm/hsail/HSAILAssembler.java graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/AbstractPTXAssembler.java graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXAddress.java graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXAsmOptions.java graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXAssembler.java graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXMacroAssembler.java graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXStateSpace.java graal/com.oracle.graal.compiler.hsail.test.infra/src/com/oracle/graal/compiler/hsail/test/infra/ForceDeoptSubstitutions.java graal/com.oracle.graal.compiler.hsail.test.infra/src/com/oracle/graal/compiler/hsail/test/infra/GraalKernelTester.java graal/com.oracle.graal.compiler.hsail.test.infra/src/com/oracle/graal/compiler/hsail/test/infra/KernelTester.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntInstIITest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntInstIJTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntStatAIITest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntStatAIJTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjInstIITest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjInstIJTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjStatIITest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjStatIJTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicIntGetAndAddTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicIntGetAndSetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicLongGetAndAddTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicLongGetAndSetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicReferenceGetAndSetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BasicHSAILTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestFF.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestFT.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestTF.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestTT.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestFF.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestFT.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestTF.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestTT.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestFF.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestFT.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestTF.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestTT.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany16384Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany20000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany5000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany8192Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany987654HighTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany987654Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany99999Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchManyBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMost1000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMost20000StressGCTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMost20000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle16384Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle20000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle5000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle8192Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingleBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckDoubleNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckFailsInMiddleTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckFloatNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckInlineTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckLongNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckNonZeroBciInstanceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseAndCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseAndTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseOrCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseOrTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseXorCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseXorTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CallTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseAndCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseAndTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseOrCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseOrTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseXorCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseXorTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ClassCastNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ClassCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DVec3.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DoubleAbsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DoubleCeilTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DoubleFloorTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DoubleLongConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DoubleNegTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DoubleRintTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/DoubleSqrtTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewFloatStringTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewFloatTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewIntArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewIntegerTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewStoreFieldTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewStringConcatTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewStringInternTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewStringLargeRangeTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewStringTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3ArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3Base.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3LargeRangeDisp3Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3LargeRangeTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3MediumRangeTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3Partial2Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3PartialTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/EscapingNewVec3Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FcompUnorderedTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Float2DMatrixBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Float2DMatrixMultiplyRangeFinalTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Float2DMatrixMultiplyTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FloatAbsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FloatConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FloatDivPrecisionTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FloatDoubleConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FloatLongConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FloatNegTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/FloatSqrtTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/InstanceOfTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/InstanceOfTwoLevelTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntAbsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntAddIndexTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntAddTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntBitwiseAndTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntBitwiseNotTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntBitwiseOrTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntBitwiseShiftLeftTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntBitwiseShiftRightTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntBitwiseShiftRightUnsignedTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntBitwiseXorTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntByteConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntCharConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntDivTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntDoubleConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntDoubledTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntFloatConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntLongConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntLookupSwitchTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntModTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntMulTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntNegTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntShortConvertTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntSqrAddTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntSquaredGidCmpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntSquaredTernaryTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntSquaredTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntStreamNullCatchNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntStreamNullCheckNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntStreamNullCheckTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntStreamNullNonArrayParamCheckTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntStreamNullParamCheckTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntSubTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntSumArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntTableSwitchTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/IntTestBranchTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongAbsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongBitwiseAndTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongBitwiseNotTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongBitwiseOrTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongBitwiseShiftLeftTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongBitwiseShiftRightTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongBitwiseShiftRightUnsignedTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongBitwiseXorTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongModTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/LongNegTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/NestedStaticCallTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/NestedVirtualCallTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptMany20000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptMany5000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptMany99999Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptManyBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptMost20000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptMost5000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptMost99999Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptMostBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptSingle100Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjSpillDeoptSingle20000Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjectStoreNullTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ObjectStoreTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ShortBitwiseAndCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ShortBitwiseAndTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ShortBitwiseOrCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ShortBitwiseOrTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ShortBitwiseXorCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ShortBitwiseXorTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/SingleExceptionTestBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticCallTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticDoubleSpillBoundsCatchOneTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticDoubleSpillBoundsCatchTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticDoubleSpillTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticIntSpillTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticMandelBoundsCheckTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticMandelTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticMethod16InArraysTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticMethodThreeIntArrays.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticMethodTwoIntArrays.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticNBodyCallTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticNBodySpillTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StaticNBodyTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StringContainsAcceptTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StringContainsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StringEqualsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StringIndexOfTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/StringSwitchTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamClassCastNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamClassCastTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamFloatCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamIntCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamIntFloatCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamNullCheckNonZeroBciTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamNullCheckTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamNullParamCheckTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamObjCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamObjFieldTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/Vec3ObjStreamTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/VolatileIntTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ArrayFieldAccessTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ArrayListGetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ArrayListSetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ArrayListStreamTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicIntAddAndGetGidTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicIntAddAndGetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicIntDecAndGetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicIntGetAndAddTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicIntGetAndDecTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicIntGetAndIncTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicIntIncAndGetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicLongAddAndGetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicLongGetAndAddTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicLongGetAndIncTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/AtomicLongIncAndGetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/BigIntegerSquaredTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Body.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ByteArrayCopyConjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ByteArrayCopyDisjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ByteArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/CharArrayCopyConjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/CharArrayCopyDisjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/CountMatchesBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleAcosTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleAsinTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleAtan2Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleAtanTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleCbrtTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleCosTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleCoshTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleExpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleExpm1Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleFieldAccessTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleGetExponentTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleHypotTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleIeeeRemainderTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleLog10Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleLogTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleMathBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleMathLargeBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleNextAfterTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleNextUpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoublePowTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleRoundTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleScalbTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleSignumTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleSinTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleSinhTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleTanTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleTanhTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleToLongTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleTwoInputMathBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DoubleUlpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/DremTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FibRecursionTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Float2DMatrixBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Float2DMatrixMultiplyRangeFinalTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Float2DMatrixMultiplySingleOutTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Float2DMatrixMultiplyTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatAcosTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatAsinTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatAtan2Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatAtanTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatCbrtTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatCondMoveTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatCosTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatCoshTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatExpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatExpm1Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatFieldAccessTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatFieldWriteTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatGetExponentTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatIeeeRemainderTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatLog10Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatLogTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatMathBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatMathLargeBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatNextAfterTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatNextUpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatPowTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatRoundTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatScalbTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatSignumTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatSinTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatSinhTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatTanTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatTanhTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatTwoInputMathBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatUlpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ForEachToGraalTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/HashMapGetTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/InstanceNBodyTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/InstanceOfNullTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/InstanceOfTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/InstanceOopNBodyAccTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/InstanceOopNBodyTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntArrayCopyConjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntArrayCopyDisjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntCondMoveTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntFieldAccessTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntNegateInstanceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntSquaredInstanceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntSquaredStaticTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntToLongTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntegerObjectCreateTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/IntegerObjectReadTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/LongAdderTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/LongArrayCopyConjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/LongArrayCopyDisjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/LongCmpTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/LongCondMoveTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/LongNegateInstanceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/LongSquaredInstanceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Main.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/MandelInstanceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/MandelStaticTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/MathTestBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/MoreThanEightArgsOOBTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/MoreThanEightArgsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/NewStringEqualsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/NewStringLenTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/NonEscapingNewArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/NonEscapingNewObjWithArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/NonEscapingNewTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ObjArrayCopyConjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ObjArrayCopyDisjointNonExactTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ObjArrayCopyDisjointTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ObjectArrayInstanceDerivedTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ObjectArrayInstanceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ObjectStoreNullTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ObjectStoreTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/OverloadMethodTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ReduceMaxTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ReduceMinTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ReduceSumTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/ShortArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StaticFloatFieldReadTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StaticIntField2ReadTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StaticIntFieldReadTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StaticIntFieldSameClassTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StaticIntFieldWriteTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StaticNBodyTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringBuilderTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringContainsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringEqualsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringHashTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringLenTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringSubsequenceTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringSubstringTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringUtilsCountMatches2Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/StringUtilsCountMatchesTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/SynchronizedMethodTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/TooSimpleNewTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/TwoDIntArrayTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VarArgsTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Vec3ObjStreamFloatCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Vec3ObjStreamIntCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Vec3ObjStreamIntFloatCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Vec3ObjStreamObjCaptureTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Vec3ObjStreamObjFieldTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/Vec3ObjStreamTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VecmathNBodyDeoptTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VecmathNBodyTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VectorStreamTest.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VirtualCall3Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VirtualCall4Test.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VirtualCallBase.java graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/VirtualCallTest.java graal/com.oracle.graal.compiler.hsail/src/com/oracle/graal/compiler/hsail/CompileAndDispatch.java graal/com.oracle.graal.compiler.hsail/src/com/oracle/graal/compiler/hsail/HSAILLIRGenerator.java graal/com.oracle.graal.compiler.hsail/src/com/oracle/graal/compiler/hsail/HSAILNodeLIRBuilder.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/ArrayPTXTest.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/BasicPTXTest.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/ControlPTXTest.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/FloatPTXTest.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/IntegerPTXTest.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/LogicPTXTest.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/ObjectPTXTest.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/PTXMethodInvalidation1Test.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/PTXMethodInvalidation2Test.java graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/PTXTest.java graal/com.oracle.graal.compiler.ptx/src/com/oracle/graal/compiler/ptx/PTXLIRGenerator.java graal/com.oracle.graal.compiler.ptx/src/com/oracle/graal/compiler/ptx/PTXNodeLIRBuilder.java graal/com.oracle.graal.gpu/src/com/oracle/graal/gpu/ExternalCompilationResult.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/ForEachToGraal.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotAssembler.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotBackend.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotBackendFactory.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotCodeCacheProvider.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotForeignCallsProvider.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotLIRGenerationResult.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotLIRGenerator.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotLoweringProvider.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotNodeLIRBuilder.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotRegisterConfig.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotReplacementsImpl.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/HSAILHotSpotSafepointOp.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/replacements/HSAILDirectLoadAcquireNode.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/replacements/HSAILDirectStoreReleaseNode.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/replacements/HSAILHotSpotReplacementsUtil.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/replacements/HSAILNewObjectSnippets.java graal/com.oracle.graal.hotspot.hsail/src/com/oracle/graal/hotspot/hsail/replacements/HSAILWorkItemAbsIdNode.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotBackend.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotBackendFactory.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotCodeCacheProvider.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotForeignCallsProvider.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotLIRGenerator.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotLoweringProvider.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotNodeLIRBuilder.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXHotSpotRegisterConfig.java graal/com.oracle.graal.hotspot.ptx/src/com/oracle/graal/hotspot/ptx/PTXWrapperBuilder.java graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotVMConfig.java graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/bridge/CompilerToVMImpl.java graal/com.oracle.graal.hsail/src/com/oracle/graal/hsail/HSAIL.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILAddressValue.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILArithmetic.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILBitManipulationOp.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILCompare.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILControlFlow.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILFrameMap.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILLIRInstruction.java graal/com.oracle.graal.lir.hsail/src/com/oracle/graal/lir/hsail/HSAILMove.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXAddressValue.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXArithmetic.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXBitManipulationOp.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXCompare.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXControlFlow.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXFrameMap.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXLIRInstruction.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXMemOp.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXMove.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXParameterOp.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/PTXTestOp.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/ParallelOver.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/ThreadDimension.java graal/com.oracle.graal.lir.ptx/src/com/oracle/graal/lir/ptx/Warp.java graal/com.oracle.graal.ptx/src/com/oracle/graal/ptx/PTX.java graal/com.oracle.graal.replacements.hsail/src/com/oracle/graal/replacements/hsail/HSAILMathIntrinsicsNode.java graal/com.oracle.graal.replacements.hsail/src/com/oracle/graal/replacements/hsail/HSAILMathSubstitutions.java graal/com.oracle.graal.replacements.hsail/src/com/oracle/graal/replacements/hsail/JStrictMath.java hotspot/.project make/bsd/makefiles/buildtree.make make/bsd/makefiles/vm.make make/linux/makefiles/buildtree.make make/linux/makefiles/vm.make make/solaris/makefiles/buildtree.make make/solaris/makefiles/vm.make make/windows/makefiles/projectcreator.make mx/suite.py src/gpu/hsail/vm/gpu_hsail.cpp src/gpu/hsail/vm/gpu_hsail.hpp src/gpu/hsail/vm/gpu_hsail_Frame.hpp src/gpu/hsail/vm/gpu_hsail_OopMapHelper.hpp src/gpu/hsail/vm/gpu_hsail_Tlab.hpp src/gpu/hsail/vm/hsailArgumentsBase.cpp src/gpu/hsail/vm/hsailArgumentsBase.hpp src/gpu/hsail/vm/hsailJavaCallArguments.hpp src/gpu/hsail/vm/hsailKernelArguments.cpp src/gpu/hsail/vm/hsailKernelArguments.hpp src/gpu/hsail/vm/vmStructs_hsail.hpp src/gpu/ptx/vm/gpu_ptx.cpp src/gpu/ptx/vm/gpu_ptx.hpp src/os/bsd/vm/gpu_bsd.cpp src/os/linux/vm/gpu_linux.cpp src/os/windows/vm/gpu_windows.cpp src/share/vm/classfile/javaClasses.cpp src/share/vm/classfile/systemDictionary.hpp src/share/vm/classfile/vmSymbols.hpp src/share/vm/code/nmethod.hpp src/share/vm/gc_interface/collectedHeap.cpp src/share/vm/gc_interface/collectedHeap.hpp src/share/vm/graal/graalCompilerToVM.cpp src/share/vm/graal/graalEnv.cpp src/share/vm/graal/graalGlobals.hpp src/share/vm/graal/graalJavaAccess.hpp src/share/vm/memory/threadLocalAllocBuffer.cpp src/share/vm/memory/threadLocalAllocBuffer.hpp src/share/vm/runtime/compilationPolicy.cpp src/share/vm/runtime/gpu.cpp src/share/vm/runtime/gpu.hpp src/share/vm/runtime/javaCalls.cpp src/share/vm/runtime/javaCalls.hpp src/share/vm/runtime/safepoint.cpp src/share/vm/runtime/thread.cpp src/share/vm/runtime/thread.hpp src/share/vm/runtime/vmStructs.cpp
diffstat 503 files changed, 48 insertions(+), 48420 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.asm.hsail/src/com/oracle/graal/asm/hsail/AbstractHSAILAssembler.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,67 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.hsail;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.asm.*;
-
-/**
- * The platform-dependent base class for the HSAIL assembler.
- */
-public abstract class AbstractHSAILAssembler extends Assembler {
-
-    public AbstractHSAILAssembler(TargetDescription target) {
-        super(target);
-    }
-
-    @Override
-    public final void bind(Label l) {
-        super.bind(l);
-        emitString0(nameOf(l) + ":\n");
-    }
-
-    @Override
-    public void align(int modulus) {
-        // Nothing to do
-    }
-
-    @Override
-    public void jmp(Label l) {
-        emitJumpToLabelName(nameOf(l));
-    }
-
-    public void emitJumpToLabelName(String labelName) {
-        emitString("brn " + labelName + ";");
-    }
-
-    @Override
-    protected void patchJumpTarget(int branch, int jumpTarget) {
-        // Nothing to do
-    }
-
-    @Override
-    protected String createLabelName(Label l, int id) {
-        int blockId = l.getBlockId();
-        return "@L" + (blockId == -1 ? id : blockId);
-    }
-}
--- a/graal/com.oracle.graal.asm.hsail/src/com/oracle/graal/asm/hsail/HSAILAddress.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,74 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.hsail;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.api.meta.*;
-
-/**
- * Represents an address in target machine memory, specified via some combination of a base register
- * and a displacement.
- */
-public final class HSAILAddress extends AbstractAddress {
-
-    private final Register base;
-    private final long displacement;
-
-    /**
-     * Creates an {@link HSAILAddress} with given base register and no displacement.
-     * 
-     * 
-     * @param base the base register
-     */
-    public HSAILAddress(Register base) {
-        this(base, 0);
-    }
-
-    /**
-     * Creates an {@link HSAILAddress} with given base register and a displacement. This is the most
-     * general constructor.
-     * 
-     * @param base the base register
-     * @param displacement the displacement
-     */
-    public HSAILAddress(Register base, long displacement) {
-        this.base = base;
-        this.displacement = displacement;
-    }
-
-    /**
-     * @return Base register that defines the start of the address computation. If not present, is
-     *         denoted by {@link Value#ILLEGAL}.
-     */
-    public Register getBase() {
-        return base;
-    }
-
-    /**
-     * @return Optional additive displacement.
-     */
-    public long getDisplacement() {
-        return displacement;
-    }
-
-}
--- a/graal/com.oracle.graal.asm.hsail/src/com/oracle/graal/asm/hsail/HSAILAssembler.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,661 +0,0 @@
-/*
- * Copyright (c) 2009, 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.asm.hsail;
-
-import static com.oracle.graal.api.code.MemoryBarriers.*;
-import static com.oracle.graal.api.code.ValueUtil.*;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.api.meta.*;
-import com.oracle.graal.compiler.common.*;
-import com.oracle.graal.hsail.*;
-
-/**
- * This class contains routines to emit HSAIL assembly code.
- */
-public abstract class HSAILAssembler extends AbstractHSAILAssembler {
-
-    /**
-     * Stack size in bytes (used to keep track of spilling).
-     */
-    private int maxDataTypeSize;
-
-    /**
-     * Maximum stack offset used by a store operation.
-     */
-    private long maxStackOffset = 0;
-
-    public long upperBoundStackSize() {
-        return maxStackOffset + maxDataTypeSize;
-    }
-
-    public HSAILAssembler(TargetDescription target) {
-        super(target);
-    }
-
-    @Override
-    public HSAILAddress makeAddress(Register base, int displacement) {
-        return new HSAILAddress(base, displacement);
-    }
-
-    @Override
-    public HSAILAddress getPlaceholder() {
-        return null;
-    }
-
-    @Override
-    public final void ensureUniquePC() {
-        throw GraalInternalError.unimplemented();
-    }
-
-    public final void undefined(String str) {
-        emitString("undefined operation " + str);
-    }
-
-    public final void exit() {
-        emitString("ret;" + "");
-    }
-
-    /**
-     * Moves an Object into a register.
-     *
-     * Because Object references become stale after Garbage collection (GC) the technique used here
-     * is to load a JNI global reference to that Object into the register. These JNI global
-     * references get updated by the GC whenever the GC moves an Object.
-     *
-     * @param a the destination register
-     * @param src the Object Constant being moved
-     */
-    public abstract void mov(Register a, JavaConstant src);
-
-    private static String getBitTypeFromKind(Kind kind) {
-        switch (kind) {
-            case Boolean:
-            case Byte:
-            case Short:
-            case Char:
-            case Int:
-            case Float:
-                return "b32";
-            case Long:
-            case Double:
-            case Object:
-                return "b64";
-            default:
-                throw GraalInternalError.shouldNotReachHere();
-        }
-    }
-
-    public final void emitMov(Kind kind, Value dst, Value src) {
-        if (isRegister(dst) && isConstant(src) && kind.getStackKind() == Kind.Object) {
-            mov(asRegister(dst), asConstant(src));
-        } else {
-            String argtype = getBitTypeFromKind(kind);
-            emitString("mov_" + argtype + " " + mapRegOrConstToString(dst) + ", " + mapRegOrConstToString(src) + ";");
-        }
-    }
-
-    private void emitAddrOp(String instr, Value reg, HSAILAddress addr) {
-        String storeValue = mapRegOrConstToString(reg);
-        emitString(instr + " " + storeValue + ", " + mapAddress(addr) + ";");
-    }
-
-    /**
-     * Emits a memory barrier instruction.
-     *
-     * @param barriers the kind of barrier to emit
-     */
-    public final void emitMembar(int barriers) {
-        if (barriers == 0) {
-            emitString("// no barrier before volatile read");
-        } else if (barriers == JMM_POST_VOLATILE_READ) {
-            emitString("sync; // barriers=" + MemoryBarriers.barriersString(barriers));
-        } else if (barriers == JMM_PRE_VOLATILE_WRITE) {
-            emitString("sync; // barriers=" + MemoryBarriers.barriersString(barriers));
-        } else if (barriers == JMM_POST_VOLATILE_WRITE) {
-            emitString("sync; // barriers=" + MemoryBarriers.barriersString(barriers));
-        }
-    }
-
-    public final void emitLoad(Kind kind, Value dest, HSAILAddress addr) {
-        emitLoad(dest, addr, getArgTypeFromKind(kind));
-    }
-
-    public final void emitLoad(Value dest, HSAILAddress addr, String argTypeStr) {
-        emitAddrOp("ld_global_" + argTypeStr, dest, addr);
-    }
-
-    public final void emitLda(Value dest, HSAILAddress addr) {
-        emitAddrOp("lda_global_u64", dest, addr);
-    }
-
-    public final void emitLea(Value dest, HSAILAddress addr) {
-        String prefix = getArgType(dest);
-        emitString(String.format("add_%s %s, $%s, 0x%s;", prefix, HSAIL.mapRegister(dest), addr.getBase().name, Long.toHexString(addr.getDisplacement())));
-    }
-
-    public final void emitLoadKernelArg(Value dest, String kernArgName, String argTypeStr) {
-        emitString("ld_kernarg_" + argTypeStr + " " + HSAIL.mapRegister(dest) + ", [" + kernArgName + "];");
-    }
-
-    public final void emitStore(Kind kind, Value src, HSAILAddress addr) {
-        emitStore(src, addr, getArgTypeFromKind(kind));
-    }
-
-    public final void emitStore(Value dest, HSAILAddress addr, String argTypeStr) {
-        emitAddrOp("st_global_" + argTypeStr, dest, addr);
-    }
-
-    private void storeImmediateImpl(String storeType, String value, HSAILAddress addr) {
-        emitString("st_global_" + storeType + " " + value + ", " + mapAddress(addr) + ";");
-    }
-
-    public final void emitStoreImmediate(Kind kind, long src, HSAILAddress addr) {
-        assert (kind != Kind.Float && kind != Kind.Double);
-        storeImmediateImpl(getArgTypeFromKind(kind), Long.toString(src), addr);
-    }
-
-    public final void emitStoreImmediate(float src, HSAILAddress addr) {
-        storeImmediateImpl("f32", floatToString(src), addr);
-    }
-
-    public final void emitStoreImmediate(double src, HSAILAddress addr) {
-        storeImmediateImpl("f64", doubleToString(src), addr);
-    }
-
-    public final void emitSpillLoad(Kind kind, Value dest, Value src) {
-        emitString("ld_spill_" + getArgTypeFromKind(kind) + " " + HSAIL.mapRegister(dest) + ", " + mapStackSlot(src, getArgSizeFromKind(kind)) + ";");
-    }
-
-    public final void emitStore(Value src, HSAILAddress addr) {
-        emitString("st_global_" + getArgType(src) + " " + HSAIL.mapRegister(src) + ", " + mapAddress(addr) + ";");
-    }
-
-    public final void emitSpillStore(Kind kind, Value src, Value dest) {
-        int sizestored = getArgSizeFromKind(kind);
-        if (maxDataTypeSize < sizestored) {
-            maxDataTypeSize = sizestored;
-        }
-        int stackoffset = HSAIL.getStackOffset(dest);
-        if (maxStackOffset < stackoffset) {
-            maxStackOffset = stackoffset;
-        }
-        emitString("st_spill_" + getArgTypeFromKind(kind) + " " + HSAIL.mapRegister(src) + ", " + mapStackSlot(dest, getArgSizeFromKind(kind)) + ";");
-    }
-
-    public static String mapStackSlot(Value reg, int argSize) {
-        long startOffset = HSAIL.getStackOffsetStart(reg, argSize);
-        return "[%spillseg]" + "[" + startOffset + "]";
-    }
-
-    public void cbr(String target1) {
-        emitString("cbr " + "$c0" + ", " + target1 + ";");
-    }
-
-    public int getArgSize(Value src) {
-        return getArgSizeFromKind(src.getKind());
-    }
-
-    private static int getArgSizeFromKind(Kind kind) {
-        switch (kind) {
-            case Int:
-            case Float:
-                return 32;
-            case Double:
-            case Long:
-            case Object:
-                return 64;
-            default:
-                throw GraalInternalError.shouldNotReachHere();
-        }
-    }
-
-    private static String getArgType(Value src) {
-        return getArgTypeFromKind(src.getKind());
-    }
-
-    private static String getArgTypeFromKind(Kind kind) {
-        String prefix = "";
-        switch (kind) {
-            case Float:
-                prefix = "f32";
-                break;
-            case Double:
-                prefix = "f64";
-                break;
-            case Int:
-                prefix = "s32";
-                break;
-            case Long:
-                prefix = "s64";
-                break;
-            case Object:
-                prefix = "u64";
-                break;
-            case Char:
-                prefix = "u16";
-                break;
-            case Short:
-                prefix = "s16";
-                break;
-            case Byte:
-                prefix = "s8";
-                break;
-            case Boolean:
-                prefix = "u8";
-                break;
-            default:
-                throw GraalInternalError.shouldNotReachHere();
-        }
-        return prefix;
-    }
-
-    public static final String getArgTypeForceUnsigned(Value src) {
-        return getArgTypeForceUnsignedKind(src.getKind());
-    }
-
-    public static final String getArgTypeForceUnsignedKind(Kind kind) {
-        switch (kind) {
-            case Int:
-                return "u32";
-            case Long:
-            case Object:
-                return "u64";
-            default:
-                throw GraalInternalError.shouldNotReachHere();
-        }
-    }
-
-    public static final String getArgTypeBitwiseLogical(Value src) {
-        String length = getArgType(src);
-        String prefix = "_b" + (length.endsWith("64") ? "64" : "32");
-        return prefix;
-    }
-
-    /**
-     * Emits a compare instruction.
-     *
-     * @param src0 - the first source register
-     * @param src1 - the second source register
-     * @param condition - the compare condition i.e., eq, ne, lt, gt
-     * @param unordered - flag specifying if this is an unordered compare. This only applies to
-     *            float compares.
-     * @param isUnsignedCompare - flag specifying if this is a compare of unsigned values.
-     */
-    public void emitCompare(Kind compareKind, Value src0, Value src1, String condition, boolean unordered, boolean isUnsignedCompare) {
-        // Formulate the prefix of the instruction.
-        // if unordered is true, it should be ignored unless the src type is f32 or f64
-        String argType = getArgTypeFromKind(compareKind);
-        String unorderedPrefix = (argType.startsWith("f") && unordered ? "u" : "");
-        String prefix = "cmp_" + condition + unorderedPrefix + "_b1_" + (isUnsignedCompare ? getArgTypeForceUnsigned(src1) : argType);
-        // Generate a comment for debugging purposes
-        String comment = (isConstant(src1) && (src1.getKind() == Kind.Object) && (asConstant(src1).isNull()) ? " // null test " : "");
-        // Emit the instruction.
-        emitString(prefix + " $c0, " + mapRegOrConstToString(src0) + ", " + mapRegOrConstToString(src1) + ";" + comment);
-    }
-
-    public void emitConvert(Value dest, Value src, String destType, String srcType) {
-        String prefix = "cvt_";
-        if (destType.equals("f32") && srcType.equals("f64")) {
-            prefix = "cvt_near_";
-        } else if (srcType.startsWith("f") && (destType.startsWith("s") || destType.startsWith("u"))) {
-            prefix = "cvt_zeroi_sat_";
-        }
-        emitString(prefix + destType + "_" + srcType + " " + HSAIL.mapRegister(dest) + ", " + HSAIL.mapRegister(src) + ";");
-    }
-
-    public void emitConvert(Value dest, Value src, Kind destKind, Kind srcKind) {
-        String destType = getArgTypeFromKind(destKind);
-        String srcType = getArgTypeFromKind(srcKind);
-        emitConvert(dest, src, destType, srcType);
-    }
-
-    /**
-     * Emits a convert instruction that uses unsigned prefix, regardless of the type of dest and
-     * src.
-     *
-     * @param dest the destination operand
-     * @param src the source operand
-     */
-    public void emitConvertForceUnsigned(Value dest, Value src) {
-        emitString("cvt_" + getArgTypeForceUnsigned(dest) + "_" + getArgTypeForceUnsigned(src) + " " + HSAIL.mapRegister(dest) + ", " + HSAIL.mapRegister(src) + ";");
-    }
-
-    public static String mapAddress(HSAILAddress addr) {
-        if (addr.getBase().encoding() < 0) {
-            return "[0x" + Long.toHexString(addr.getDisplacement()) + "]";
-        } else {
-            return "[$d" + addr.getBase().encoding() + " + " + addr.getDisplacement() + "]";
-        }
-    }
-
-    private static String doubleToString(double dval) {
-        long lval = Double.doubleToRawLongBits(dval);
-        long lvalIgnoreSign = lval & 0x7fffffffffffffffL;
-        if (lvalIgnoreSign >= 0x7ff0000000000000L) {
-            return "0D" + String.format("%16x", lval);
-        } else {
-            return Double.toString(dval);
-        }
-    }
-
-    private static String floatToString(float fval) {
-        int ival = Float.floatToRawIntBits(fval);
-        int ivalIgnoreSign = ival & 0x7fffffff;
-        if (ivalIgnoreSign >= 0x7f800000) {
-            return "0F" + String.format("%8x", ival);
-        } else {
-            return Float.toString(fval) + "f";
-        }
-    }
-
-    private static String mapRegOrConstToString(Value src) {
-        if (!isConstant(src)) {
-            return HSAIL.mapRegister(src);
-        } else {
-            JavaConstant consrc = asConstant(src);
-            switch (src.getKind()) {
-                case Boolean:
-                case Int:
-                    return Integer.toString(consrc.asInt());
-                case Float:
-                    return floatToString(consrc.asFloat());
-                case Double:
-                    return doubleToString(consrc.asDouble());
-                case Long:
-                    return "0x" + Long.toHexString(consrc.asLong());
-                case Object:
-                    if (consrc.isNull()) {
-                        return "0";
-                    } else {
-                        throw GraalInternalError.shouldNotReachHere("unknown type: " + src);
-                    }
-                default:
-                    throw GraalInternalError.shouldNotReachHere("unknown type: " + src);
-            }
-        }
-
-    }
-
-    /**
-     * Emits an instruction.
-     *
-     * @param mnemonic the instruction mnemonic
-     * @param dest the destination operand
-     * @param sources the source operands
-     */
-    public final void emit(String mnemonic, Value dest, Value... sources) {
-        String prefix = getArgType(dest);
-        emitTextFormattedInstruction(mnemonic + "_" + prefix, dest, sources);
-    }
-
-    /**
-     * Emits an unsigned instruction.
-     *
-     * @param mnemonic the instruction mnemonic
-     * @param dest the destination argument
-     * @param sources the source arguments
-     *
-     */
-    public final void emitForceUnsigned(String mnemonic, Value dest, Value... sources) {
-        String prefix = getArgTypeForceUnsigned(dest);
-        emitTextFormattedInstruction(mnemonic + "_" + prefix, dest, sources);
-    }
-
-    public final void emitForceUnsignedKind(String mnemonic, Kind kind, Value dest, Value... sources) {
-        String prefix = getArgTypeForceUnsignedKind(kind);
-        emitTextFormattedInstruction(mnemonic + "_" + prefix, dest, sources);
-    }
-
-    /**
-     * Emits an instruction for a bitwise logical operation.
-     *
-     * @param mnemonic the instruction mnemonic
-     * @param dest the destination
-     * @param sources the source operands
-     */
-    public final void emitForceBitwise(String mnemonic, Value dest, Value... sources) {
-        String prefix = getArgTypeBitwiseLogical(dest);
-        emitTextFormattedInstruction(mnemonic + prefix, dest, sources);
-    }
-
-    /**
-     * Central helper routine that emits a text formatted HSAIL instruction via call to
-     * AbstractAssembler.emitString. All the emit routines in the assembler end up calling this one.
-     *
-     * @param instr the full instruction mnenomics including any prefixes
-     * @param dest the destination operand
-     * @param sources the source operand
-     */
-    private void emitTextFormattedInstruction(String instr, Value dest, Value... sources) {
-        /**
-         * Destination can't be a constant and no instruction has > 3 source operands.
-         */
-        assert (!isConstant(dest) && sources.length <= 3);
-        switch (sources.length) {
-            case 3:
-                // Emit an instruction with three source operands.
-                emitString(String.format("%s %s, %s, %s, %s;", instr, HSAIL.mapRegister(dest), mapRegOrConstToString(sources[0]), mapRegOrConstToString(sources[1]), mapRegOrConstToString(sources[2])));
-                break;
-            case 2:
-                // Emit an instruction with two source operands.
-                emitString(String.format("%s %s, %s, %s;", instr, HSAIL.mapRegister(dest), mapRegOrConstToString(sources[0]), mapRegOrConstToString(sources[1])));
-                break;
-            case 1:
-                // Emit an instruction with one source operand.
-                emitString(String.format("%s %s, %s;", instr, HSAIL.mapRegister(dest), mapRegOrConstToString(sources[0])));
-                break;
-            default:
-                // Emit an instruction with one source operand.
-                emitString(String.format("%s %s;", instr, HSAIL.mapRegister(dest)));
-                break;
-        }
-    }
-
-    /**
-     * Emits a conditional move instruction.
-     *
-     * @param dest the destination operand storing result of the move
-     * @param trueReg the register that should be copied to dest if the condition is true
-     * @param falseReg the register that should be copied to dest if the condition is false
-     * @param width the width of the instruction (32 or 64 bits)
-     */
-    public final void emitConditionalMove(Value dest, Value trueReg, Value falseReg, int width) {
-        assert (!isConstant(dest));
-        String instr = (width == 32 ? "cmov_b32" : "cmov_b64");
-        emitString(String.format("%s %s, %s%s, %s;", instr, HSAIL.mapRegister(dest), "$c0, ", mapRegOrConstToString(trueReg), mapRegOrConstToString(falseReg)));
-    }
-
-    /**
-     * Emits code to build a 64-bit pointer from a compressed value and the associated base and
-     * shift. The compressed value could represent either a normal oop or a klass ptr. If the
-     * compressed value is 0, the uncompressed must also be 0. We only emit this if base and shift
-     * are not both zero.
-     *
-     * @param result the register containing the compressed value on input and the uncompressed ptr
-     *            on output
-     * @param base the amount to be added to the compressed value
-     * @param shift the number of bits to shift left the compressed value
-     * @param testForNull true if the compressed value might be null
-     */
-    public void emitCompressedOopDecode(Value result, long base, int shift, boolean testForNull) {
-        assert (base != 0 || shift != 0);
-        assert (!isConstant(result));
-        if (base == 0) {
-            // we don't have to test for null if shl is the only operation
-            emitForceUnsignedKind("shl", Kind.Long, result, result, JavaConstant.forInt(shift));
-        } else if (shift == 0) {
-            // only use add if result is not starting as null (test only if testForNull is true)
-            emitWithOptionalTestForNull(testForNull, "add", result, result, JavaConstant.forLong(base));
-        } else {
-            // only use mad if result is not starting as null (test only if testForNull is true)
-            emitWithOptionalTestForNull(testForNull, "mad", result, result, JavaConstant.forInt(1 << shift), JavaConstant.forLong(base));
-        }
-    }
-
-    /**
-     * Emits code to build a compressed value from a full 64-bit pointer using the associated base
-     * and shift. The compressed value could represent either a normal oop or a klass ptr. If the
-     * ptr is 0, the compressed value must also be 0. We only emit this if base and shift are not
-     * both zero.
-     *
-     * @param result the register containing the 64-bit pointer on input and the compressed value on
-     *            output
-     * @param base the amount to be subtracted from the 64-bit pointer
-     * @param shift the number of bits to shift right the 64-bit pointer
-     * @param testForNull true if the 64-bit pointer might be null
-     */
-    public void emitCompressedOopEncode(Value result, long base, int shift, boolean testForNull) {
-        assert (base != 0 || shift != 0);
-        assert (!isConstant(result));
-        if (base != 0) {
-            // only use sub if result is not starting as null (test only if testForNull is true)
-            emitWithOptionalTestForNull(testForNull, "sub", result, result, JavaConstant.forLong(base));
-        }
-        if (shift != 0) {
-            // note that the shr can still be done even if the result is null
-            emitForceUnsignedKind("shr", Kind.Long, result, result, JavaConstant.forInt(shift));
-        }
-    }
-
-    /**
-     * Emits code for the requested mnemonic on the result and sources. In addition, if testForNull
-     * is true, surrounds the instruction with code that will guarantee that if the result starts as
-     * 0, it will remain 0.
-     *
-     * @param testForNull true if we want to add the code to check for and preserve null
-     * @param mnemonic the instruction to be applied (without size prefix)
-     * @param result the register which is both an input and the final output
-     * @param sources the sources for the mnemonic instruction
-     */
-    private void emitWithOptionalTestForNull(boolean testForNull, String mnemonic, Value result, Value... sources) {
-        if (testForNull) {
-            emitCompare(Kind.Long, result, JavaConstant.forLong(0), "eq", false, true);
-        }
-        emitForceUnsigned(mnemonic, result, sources);
-        if (testForNull) {
-            emitConditionalMove(result, JavaConstant.forLong(0), result, 64);
-        }
-    }
-
-    /**
-     * Emits an atomic_cas_global instruction.
-     *
-     * @param result result operand that gets the original contents of the memory location
-     * @param address the memory location
-     * @param cmpValue the value that will be compared against the memory location
-     * @param newValue the new value that will be written to the memory location if the cmpValue
-     *            comparison matches
-     */
-    public void emitAtomicCas(Kind accessKind, AllocatableValue result, HSAILAddress address, Value cmpValue, Value newValue) {
-        emitString(String.format("atomic_cas_global_b%d   %s, %s, %s, %s;", getArgSizeFromKind(accessKind), HSAIL.mapRegister(result), mapAddress(address), mapRegOrConstToString(cmpValue),
-                        mapRegOrConstToString(newValue)));
-    }
-
-    /**
-     * Emits an atomic_add_global instruction.
-     *
-     * @param result result operand that gets the original contents of the memory location
-     * @param address the memory location
-     * @param delta the amount to add
-     */
-    public void emitAtomicAdd(AllocatableValue result, HSAILAddress address, Value delta) {
-        // ensure result and delta agree (this should probably be at some higher level)
-        Value mydelta = delta;
-        if (!isConstant(delta) && (getArgSize(result) != getArgSize(delta))) {
-            emitConvert(result, delta, result.getKind(), delta.getKind());
-            mydelta = result;
-        }
-        String prefix = getArgTypeForceUnsigned(result);
-        emitString(String.format("atomic_add_global_%s   %s, %s, %s;", prefix, HSAIL.mapRegister(result), mapAddress(address), mapRegOrConstToString(mydelta)));
-    }
-
-    /**
-     * Emits an atomic_exch_global instruction.
-     *
-     * @param result result operand that gets the original contents of the memory location
-     * @param address the memory location
-     * @param newValue the new value to write to the memory location
-     */
-    public void emitAtomicExch(Kind accessKind, AllocatableValue result, HSAILAddress address, Value newValue) {
-        emitString(String.format("atomic_exch_global_b%d   %s, %s, %s;", getArgSizeFromKind(accessKind), HSAIL.mapRegister(result), mapAddress(address), mapRegOrConstToString(newValue)));
-    }
-
-    /**
-     * Emits a comment. Useful for debugging purposes.
-     *
-     * @param comment
-     */
-    public void emitComment(String comment) {
-        emitString(comment);
-    }
-
-    public String getDeoptInfoName() {
-        return "%_deoptInfo";
-    }
-
-    public String getDeoptLabelName() {
-        return "@L_Deopt";
-    }
-
-    public void emitWorkItemAbsId(Value dest) {
-        emitString(String.format("workitemabsid_u32 %s, 0;", HSAIL.mapRegister(dest)));
-    }
-
-    public void emitCuId(Value dest) {
-        emitString(String.format("cuid_u32 %s;", HSAIL.mapRegister(dest)));
-    }
-
-    public void emitLaneId(Value dest) {
-        emitString(String.format("laneid_u32 %s;", HSAIL.mapRegister(dest)));
-    }
-
-    public void emitWaveId(Value dest) {
-        emitString(String.format("waveid_u32 %s;", HSAIL.mapRegister(dest)));
-    }
-
-    public void emitMaxWaveId(Value dest) {
-        // emitString(String.format("maxwaveid_u32 %s;", HSAIL.mapRegister(dest)));
-        int hardCodedMaxWaveId = 36;
-        emitComment("// Hard-coded maxwaveid=" + hardCodedMaxWaveId + " until it works");
-        emitMov(Kind.Int, dest, JavaConstant.forInt(hardCodedMaxWaveId));
-    }
-
-    public void emitMultiplyByWavesize(Value dest) {
-        String regName = HSAIL.mapRegister(dest);
-        emitString(String.format("mul_u%d %s, %s, WAVESIZE;", getArgSize(dest), regName, regName));
-    }
-
-    public void emitGetWavesize(Value dest) {
-        String regName = HSAIL.mapRegister(dest);
-        emitString(String.format("mov_b%d %s, WAVESIZE;", getArgSize(dest), regName));
-    }
-
-    public void emitLoadAcquire(Value dest, HSAILAddress address) {
-        emitString(String.format("ld_global_acq_u%d %s, %s;", getArgSize(dest), HSAIL.mapRegister(dest), mapAddress(address)));
-    }
-
-    public void emitStoreRelease(Value src, HSAILAddress address) {
-        emitString(String.format("st_global_rel_u%d %s, %s;", getArgSize(src), HSAIL.mapRegister(src), mapAddress(address)));
-    }
-}
--- a/graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/AbstractPTXAssembler.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,58 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.ptx;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.asm.*;
-
-/**
- * The platform-dependent base class for the PTX assembler.
- */
-public abstract class AbstractPTXAssembler extends Assembler {
-
-    public AbstractPTXAssembler(TargetDescription target) {
-        super(target);
-    }
-
-    @Override
-    public final void bind(Label l) {
-        super.bind(l);
-        emitString0(nameOf(l) + ":\n");
-    }
-
-    @Override
-    public void align(int modulus) {
-        // Nothing to do
-    }
-
-    @Override
-    public void jmp(Label l) {
-        // Nothing to do
-    }
-
-    @Override
-    protected void patchJumpTarget(int branch, int jumpTarget) {
-        // Nothing to do. All branches already point to the right label.
-    }
-
-}
--- a/graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXAddress.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,73 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.ptx;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.api.meta.*;
-import com.oracle.graal.lir.*;
-
-/**
- * Represents an address in target machine memory, specified via some combination of a base register
- * and a displacement.
- */
-public final class PTXAddress extends AbstractAddress {
-
-    private final Variable base;
-    private final long displacement;
-
-    /**
-     * Creates an {@link PTXAddress} with given base register and no displacement.
-     * 
-     * @param base the base register
-     */
-    public PTXAddress(Variable base) {
-        this(base, 0);
-    }
-
-    /**
-     * Creates an {@link PTXAddress} with given base register and a displacement. This is the most
-     * general constructor.
-     * 
-     * @param base the base register
-     * @param displacement the displacement
-     */
-    public PTXAddress(Variable base, long displacement) {
-        this.base = base;
-        this.displacement = displacement;
-    }
-
-    /**
-     * @return Base register that defines the start of the address computation. If not present, is
-     *         denoted by {@link Value#ILLEGAL}.
-     */
-    public Variable getBase() {
-        return base;
-    }
-
-    /**
-     * @return Optional additive displacement.
-     */
-    public long getDisplacement() {
-        return displacement;
-    }
-}
--- a/graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXAsmOptions.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,27 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.ptx;
-
-public class PTXAsmOptions {
-    // Nothing for now
-}
--- a/graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXAssembler.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,712 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.ptx;
-
-import static com.oracle.graal.api.code.ValueUtil.*;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.api.meta.*;
-import com.oracle.graal.asm.*;
-import com.oracle.graal.compiler.common.*;
-import com.oracle.graal.compiler.common.calc.*;
-import com.oracle.graal.lir.*;
-
-public class PTXAssembler extends AbstractPTXAssembler {
-
-    public PTXAssembler(TargetDescription target, @SuppressWarnings("unused") RegisterConfig registerConfig) {
-        super(target);
-    }
-
-    public enum ConditionOperator {
-        // @formatter:off
-
-        // Signed integer operators
-        S_EQ("eq"),
-        S_NE("ne"),
-        S_LT("lt"),
-        S_LE("le"),
-        S_GT("gt"),
-        S_GE("ge"),
-
-        // Unsigned integer operators
-        U_EQ("eq"),
-        U_NE("ne"),
-        U_LO("lo"),
-        U_LS("ls"),
-        U_HI("hi"),
-        U_HS("hs"),
-
-        // Bit-size integer operators
-        B_EQ("eq"),
-        B_NE("ne"),
-
-        // Floating-point operators
-        F_EQ("eq"),
-        F_NE("ne"),
-        F_LT("lt"),
-        F_LE("le"),
-        F_GT("gt"),
-        F_GE("ge"),
-
-        // Floating-point operators accepting NaN
-        F_EQU("equ"),
-        F_NEU("neu"),
-        F_LTU("ltu"),
-        F_LEU("leu"),
-        F_GTU("gtu"),
-        F_GEU("geu"),
-
-        // Floating-point operators testing for NaN
-        F_NUM("num"),
-        F_NAN("nan");
-
-        // @formatter:on
-
-        private final String operator;
-
-        private ConditionOperator(String op) {
-            this.operator = op;
-        }
-
-        public String getOperator() {
-            return operator;
-        }
-    }
-
-    public static class StandardFormat {
-
-        // Type of destination value
-        protected Kind valueKind;
-        protected Variable dest;
-        protected Value source1;
-        protected Value source2;
-
-        public StandardFormat(Variable dst, Value src1, Value src2) {
-            setDestination(dst);
-            setSource1(src1);
-            setSource2(src2);
-            setKind(dst.getKind());
-        }
-
-        public void setKind(Kind k) {
-            valueKind = k;
-        }
-
-        public void setDestination(Variable var) {
-            assert var != null;
-            dest = var;
-            setKind(var.getKind());
-        }
-
-        public void setSource1(Value val) {
-            assert val != null;
-            source1 = val;
-        }
-
-        public void setSource2(Value val) {
-            assert val != null;
-            source2 = val;
-        }
-
-        public String typeForKind(Kind k) {
-            switch (k.getTypeChar()) {
-            // Boolean
-                case 'z':
-                    return "u8";
-                    // Byte
-                case 'b':
-                    return "b8";
-                    // Short
-                case 's':
-                    return "s16";
-                case 'c':
-                    return "u16";
-                case 'i':
-                    return "s32";
-                case 'f':
-                    return "f32";
-                case 'j':
-                    return "s64";
-                case 'd':
-                    return "f64";
-                case 'a':
-                    return "u64";
-                case '-':
-                    return "u32";
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-
-        public String emit() {
-            return (typeForKind(valueKind) + emitRegister(dest, true) + emitValue(source1, true) + emitValue(source2, false) + ";");
-        }
-
-        public String emitValue(Value v, boolean comma) {
-            assert v != null;
-
-            if (isConstant(v)) {
-                return (emitConstant(v, comma));
-            } else {
-                return (emitRegister((Variable) v, comma));
-            }
-        }
-
-        public String emitRegister(Variable v, boolean comma) {
-            return (" %r" + v.index + (comma ? "," : ""));
-        }
-
-        public String emitConstant(Value v, boolean comma) {
-            JavaConstant constant = (JavaConstant) v;
-            String str = null;
-
-            switch (v.getKind().getTypeChar()) {
-                case 'i':
-                    str = String.valueOf((int) constant.asLong());
-                    break;
-                case 'f':
-                    str = String.valueOf(constant.asFloat());
-                    break;
-                case 'j':
-                    str = String.valueOf(constant.asLong());
-                    break;
-                case 'd':
-                    str = String.valueOf(constant.asDouble());
-                    break;
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-            if (comma) {
-                return (str + ",");
-            } else {
-                return str;
-            }
-        }
-    }
-
-    public static class LogicInstructionFormat extends StandardFormat {
-        public LogicInstructionFormat(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        @Override
-        public String emit() {
-            String kindStr;
-            switch (valueKind.getTypeChar()) {
-                case 's':
-                    kindStr = "b16";
-                    break;
-                case 'i':
-                    kindStr = "b32";
-                    break;
-                case 'j':
-                    kindStr = "b64";
-                    break;
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-
-            return (kindStr + emitRegister(dest, true) + emitValue(source1, true) + emitValue(source2, false) + ";");
-        }
-    }
-
-    public static class SingleOperandFormat {
-
-        protected Variable dest;
-        protected Value source;
-
-        public SingleOperandFormat(Variable dst, Value src) {
-            setDestination(dst);
-            setSource(src);
-        }
-
-        public void setDestination(Variable var) {
-            dest = var;
-        }
-
-        public void setSource(Value var) {
-            source = var;
-        }
-
-        public String typeForKind(Kind k) {
-            switch (k.getTypeChar()) {
-                case 'z':
-                    return "u8";
-                case 'b':
-                    return "s8";
-                case 's':
-                    return "s16";
-                case 'c':
-                    return "u16";
-                case 'i':
-                    return "s32";
-                case 'f':
-                    return "f32";
-                case 'j':
-                    return "s64";
-                case 'd':
-                    return "f64";
-                case 'a':
-                    return "u64";
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-
-        public String emit() {
-            return (typeForKind(dest.getKind()) + " " + emitVariable(dest) + ", " + emitValue(source) + ";");
-        }
-
-        public String emitValue(Value v) {
-            assert v != null;
-
-            if (isConstant(v)) {
-                return (emitConstant(v));
-            } else {
-                return (emitVariable((Variable) v));
-            }
-        }
-
-        public String emitConstant(Value v) {
-            JavaConstant constant = (JavaConstant) v;
-
-            switch (v.getKind().getTypeChar()) {
-                case 'i':
-                    return (String.valueOf((int) constant.asLong()));
-                case 'f':
-                    return (String.valueOf(constant.asFloat()));
-                case 'j':
-                    return (String.valueOf(constant.asLong()));
-                case 'd':
-                    return (String.valueOf(constant.asDouble()));
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-
-        public String emitVariable(Variable v) {
-            String name = v.getName();
-
-            if (name == null) {
-                return (" %r" + v.index);
-            } else {
-                return name;
-            }
-        }
-    }
-
-    public static class BinarySingleOperandFormat extends SingleOperandFormat {
-
-        public BinarySingleOperandFormat(Variable dst, Value src) {
-            super(dst, src);
-        }
-
-        @Override
-        public String typeForKind(Kind k) {
-            switch (k.getTypeChar()) {
-                case 's':
-                    return "b16";
-                case 'i':
-                    return "b32";
-                case 'j':
-                    return "b64";
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-    }
-
-    public static class ConversionFormat extends SingleOperandFormat {
-
-        private final Kind dstKind;
-        private final Kind srcKind;
-
-        public ConversionFormat(Variable dst, Value src, Kind dstKind, Kind srcKind) {
-            super(dst, src);
-            this.dstKind = dstKind;
-            this.srcKind = srcKind;
-        }
-
-        @Override
-        public String emit() {
-            return (typeForKind(dstKind) + "." + typeForKind(srcKind) + " " + emitVariable(dest) + ", " + emitValue(source) + ";");
-        }
-    }
-
-    public static class LoadStoreFormat extends StandardFormat {
-
-        protected PTXStateSpace space;
-
-        public LoadStoreFormat(PTXStateSpace space, Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-            setStateSpace(space);
-        }
-
-        public void setStateSpace(PTXStateSpace ss) {
-            space = ss;
-        }
-
-        public String emitAddress(Value var, Value val) {
-            assert var instanceof Variable;
-            assert val instanceof JavaConstant;
-            JavaConstant constant = (JavaConstant) val;
-            return ("[" + ((space == PTXStateSpace.Parameter) ? emitParameter((Variable) var) : emitRegister((Variable) var, false)) + " + " + constant.toValueString() + "]");
-        }
-
-        @Override
-        public String emitRegister(Variable var, boolean comma) {
-            return ("%r" + var.index);
-        }
-
-        public String emitParameter(Variable v) {
-            return ("param" + v.index);
-        }
-
-        public String emit(boolean isLoad) {
-            if (isLoad) {
-                return (space.getStateName() + "." + typeForKind(valueKind) + " " + emitRegister(dest, false) + ", " + emitAddress(source1, source2) + ";");
-            } else {
-                return (space.getStateName() + "." + typeForKind(valueKind) + " " + emitAddress(source1, source2) + ", " + emitRegister(dest, false) + ";");
-            }
-        }
-    }
-
-    // Checkstyle: stop method name check
-    /*
-     * Emit conditional branch to target 'tgt' guarded by predicate register 'pred' whose state is
-     * tested to be 'predCheck'.
-     */
-    public final void bra(String tgt, int pred, boolean predCheck) {
-        assert pred >= 0;
-
-        if (tgt.equals("?")) {
-            Thread.dumpStack();
-        }
-        emitString("@" + (predCheck ? "%p" : "!%p") + pred + " " + "bra" + " " + tgt + ";");
-    }
-
-    public final void bra(String src) {
-        emitString("bra " + src + ";");
-    }
-
-    public final void bra_uni(String tgt) {
-        emitString("bra.uni" + " " + tgt + ";" + "");
-    }
-
-    public final void exit() {
-        emitString("exit;" + " " + "");
-    }
-
-    public static class Global {
-
-        private Kind kind;
-        private String name;
-        private LabelRef[] targets;
-
-        public Global(Value val, String name, LabelRef[] targets) {
-            this.kind = val.getKind();
-            this.name = name;
-            this.targets = targets;
-        }
-
-        private static String valueForKind(Kind k) {
-            switch (k.getTypeChar()) {
-                case 'i':
-                    return "s32";
-                case 'j':
-                    return "s64";
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-
-        private static String emitTargets(PTXAssembler asm, LabelRef[] refs) {
-            StringBuffer sb = new StringBuffer();
-
-            for (int i = 0; i < refs.length; i++) {
-                sb.append(asm.nameOf(refs[i].label()));
-                if (i < (refs.length - 1)) {
-                    sb.append(", ");
-                }
-            }
-
-            return sb.toString();
-        }
-
-        public void emit(PTXAssembler asm) {
-            asm.emitString(".global ." + valueForKind(kind) + " " + name + "[" + targets.length + "] = " + "{ " + emitTargets(asm, targets) + " };");
-        }
-    }
-
-    public final void popc_b32(Register d, Register a) {
-        emitString("popc.b32" + " " + "%r" + d.encoding() + ", %r" + a.encoding() + ";" + "");
-    }
-
-    public final void popc_b64(Register d, Register a) {
-        emitString("popc.b64" + " " + "%r" + d.encoding() + ", %r" + a.encoding() + ";" + "");
-    }
-
-    public final void ret() {
-        emitString("ret;" + " " + "");
-    }
-
-    public final void ret_uni() {
-        emitString("ret.uni;" + " " + "");
-    }
-
-    public enum BooleanOperator {
-        AND("and"),
-        OR("or"),
-        XOR("xor");
-
-        private final String output;
-
-        private BooleanOperator(String out) {
-            this.output = out;
-        }
-
-        public String getOperator() {
-            return output + ".";
-        }
-    }
-
-    public static class Setp {
-
-        private BooleanOperator booleanOperator;
-        private ConditionOperator operator;
-        private Value first, second;
-        private Kind kind;
-        private int predicate;
-
-        public Setp(Condition condition, Value first, Value second, int predicateRegisterNumber) {
-            setFirst(first);
-            setSecond(second);
-            setPredicate(predicateRegisterNumber);
-            setKind();
-            setConditionOperator(operatorForConditon(condition));
-        }
-
-        public Setp(Condition condition, BooleanOperator operator, Value first, Value second, int predicateRegisterNumber) {
-            setFirst(first);
-            setSecond(second);
-            setPredicate(predicateRegisterNumber);
-            setKind();
-            setConditionOperator(operatorForConditon(condition));
-            setBooleanOperator(operator);
-        }
-
-        public void setFirst(Value v) {
-            first = v;
-        }
-
-        public void setSecond(Value v) {
-            second = v;
-        }
-
-        public void setPredicate(int p) {
-            predicate = p;
-        }
-
-        public void setConditionOperator(ConditionOperator co) {
-            operator = co;
-        }
-
-        public void setBooleanOperator(BooleanOperator bo) {
-            booleanOperator = bo;
-        }
-
-        private ConditionOperator operatorForConditon(Condition condition) {
-            char typeChar = kind.getTypeChar();
-
-            switch (typeChar) {
-                case 'z':
-                case 'c':
-                case 'a':
-                    // unsigned
-                    switch (condition) {
-                        case EQ:
-                            return ConditionOperator.U_EQ;
-                        case NE:
-                            return ConditionOperator.U_NE;
-                        case LT:
-                            return ConditionOperator.U_LO;
-                        case LE:
-                            return ConditionOperator.U_LS;
-                        case GT:
-                            return ConditionOperator.U_HI;
-                        case GE:
-                            return ConditionOperator.U_HS;
-                        default:
-                            throw GraalInternalError.shouldNotReachHere();
-                    }
-                case 'b':
-                case 's':
-                case 'i':
-                case 'j':
-                    // signed
-                    switch (condition) {
-                        case EQ:
-                            return ConditionOperator.S_EQ;
-                        case NE:
-                            return ConditionOperator.S_NE;
-                        case LT:
-                            return ConditionOperator.S_LT;
-                        case LE:
-                            return ConditionOperator.S_LE;
-                        case GT:
-                            return ConditionOperator.S_GT;
-                        case GE:
-                        case AE:
-                            return ConditionOperator.S_GE;
-                        default:
-                            throw GraalInternalError.shouldNotReachHere();
-                    }
-                case 'f':
-                case 'd':
-                    // floating point - do these need to accept NaN??
-                    switch (condition) {
-                        case EQ:
-                            return ConditionOperator.F_EQ;
-                        case NE:
-                            return ConditionOperator.F_NE;
-                        case LT:
-                            return ConditionOperator.F_LT;
-                        case LE:
-                            return ConditionOperator.F_LE;
-                        case GT:
-                            return ConditionOperator.F_GT;
-                        case GE:
-                            return ConditionOperator.F_GE;
-                        default:
-                            throw GraalInternalError.shouldNotReachHere();
-                    }
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-
-        public void setKind() {
-            // assert isConstant(first) && isConstant(second) == false;
-
-            if (isConstant(first)) {
-                kind = second.getKind();
-            } else {
-                kind = first.getKind();
-            }
-        }
-
-        public String emitValue(Value v) {
-            assert v != null;
-
-            if (isConstant(v)) {
-                return (", " + emitConstant(v));
-            } else {
-                return (", " + emitVariable((Variable) v));
-            }
-        }
-
-        public String typeForKind(Kind k) {
-            switch (k.getTypeChar()) {
-                case 'z':
-                    return "u8";
-                case 'b':
-                    return "s8";
-                case 's':
-                    return "s16";
-                case 'c':
-                    return "u16";
-                case 'i':
-                    return "s32";
-                case 'f':
-                    return "f32";
-                case 'j':
-                    return "s64";
-                case 'd':
-                    return "f64";
-                case 'a':
-                    return "u64";
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-
-        public String emitConstant(Value v) {
-            JavaConstant constant = (JavaConstant) v;
-
-            switch (v.getKind().getTypeChar()) {
-                case 'i':
-                    return (String.valueOf((int) constant.asLong()));
-                case 'f':
-                    return (String.valueOf(constant.asFloat()));
-                case 'j':
-                    return (String.valueOf(constant.asLong()));
-                case 'd':
-                    return (String.valueOf(constant.asDouble()));
-                default:
-                    throw GraalInternalError.shouldNotReachHere();
-            }
-        }
-
-        public String emitVariable(Variable v) {
-            return ("%r" + v.index);
-        }
-
-        public void emit(PTXAssembler asm) {
-
-            if (booleanOperator != null) {
-                // Predicates need to be objects
-                asm.emitString("setp." + operator.getOperator() + "." + booleanOperator.getOperator() + typeForKind(kind) + " %p" + predicate + emitValue(first) + emitValue(second) + ", %r;");
-            } else {
-                asm.emitString("setp." + operator.getOperator() + "." + typeForKind(kind) + " %p" + predicate + emitValue(first) + emitValue(second) + ";");
-            }
-        }
-    }
-
-    @Override
-    public PTXAddress makeAddress(Register base, int displacement) {
-        throw GraalInternalError.shouldNotReachHere();
-    }
-
-    @Override
-    public PTXAddress getPlaceholder() {
-        return null;
-    }
-
-    @Override
-    public final void ensureUniquePC() {
-        throw GraalInternalError.unimplemented();
-    }
-
-    @Override
-    public void jmp(Label l) {
-        String str = nameOf(l);
-        bra(str);
-    }
-
-    /**
-     * @param r
-     */
-    public void nullCheck(Register r) {
-        // setp(....);
-    }
-}
--- a/graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXMacroAssembler.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,322 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.ptx;
-
-import sun.misc.*;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.api.meta.*;
-import com.oracle.graal.compiler.common.*;
-import com.oracle.graal.lir.*;
-
-public class PTXMacroAssembler extends PTXAssembler {
-
-    public PTXMacroAssembler(TargetDescription target, RegisterConfig registerConfig) {
-        super(target, registerConfig);
-    }
-
-    public static class LoadAddr extends LoadStoreFormat {
-
-        public LoadAddr(PTXStateSpace space, Variable dst, Variable src1, Value src2) {
-            super(space, dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler masm) {
-            String ldAddrStr = "ld." + space.getStateName();
-            if (Unsafe.ADDRESS_SIZE == 8) {
-                ldAddrStr = ldAddrStr + ".u64";
-            } else {
-                ldAddrStr = ldAddrStr + ".u32";
-            }
-            masm.emitString(ldAddrStr + " " + emitRegister(dest, false) + ", " + emitAddress(source1, source2) + ";");
-        }
-    }
-
-    public static class Ld extends LoadStoreFormat {
-
-        public Ld(PTXStateSpace space, Variable dst, Variable src1, Value src2) {
-            super(space, dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("ld." + super.emit(true));
-        }
-    }
-
-    public static class St extends LoadStoreFormat {
-
-        public St(PTXStateSpace space, Variable dst, Variable src1, Value src2) {
-            super(space, dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("st." + super.emit(false));
-        }
-    }
-
-    public static class LoadParam extends Ld {
-        // Type of the operation is dependent on src1's type.
-        public LoadParam(PTXStateSpace space, Variable dst, Variable src1, Value src2) {
-            super(space, dst, src1, src2);
-            setKind(src1.getKind());
-        }
-    }
-
-    public static class Add extends StandardFormat {
-
-        public Add(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("add." + super.emit());
-        }
-    }
-
-    public static class And extends LogicInstructionFormat {
-
-        public And(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("and." + super.emit());
-        }
-    }
-
-    public static class Div extends StandardFormat {
-
-        public Div(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("div." + super.emit());
-        }
-    }
-
-    public static class Mul extends StandardFormat {
-
-        public Mul(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("mul.lo." + super.emit());
-        }
-    }
-
-    public static class Or extends LogicInstructionFormat {
-
-        public Or(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("or." + super.emit());
-        }
-    }
-
-    public static class Rem extends StandardFormat {
-
-        public Rem(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("rem." + super.emit());
-        }
-    }
-
-    public static class Shl extends LogicInstructionFormat {
-
-        public Shl(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("shl." + super.emit());
-        }
-    }
-
-    public static class Shr extends StandardFormat {
-
-        public Shr(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("shr." + super.emit());
-        }
-    }
-
-    public static class Sub extends StandardFormat {
-
-        public Sub(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("sub." + super.emit());
-        }
-    }
-
-    public static class Ushr extends StandardFormat {
-
-        public Ushr(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-            setKind(Kind.Illegal);  // get around not having an Unsigned Kind
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("shr." + super.emit());
-        }
-    }
-
-    public static class Xor extends LogicInstructionFormat {
-
-        public Xor(Variable dst, Value src1, Value src2) {
-            super(dst, src1, src2);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("xor." + super.emit());
-        }
-    }
-
-    public static class Cvt extends ConversionFormat {
-
-        public Cvt(Variable dst, Variable src, Kind dstKind, Kind srcKind) {
-            super(dst, src, dstKind, srcKind);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            if (dest.getKind() == Kind.Float || dest.getKind() == Kind.Double) {
-                // round-to-zero - might not be right
-                asm.emitString("cvt.rz." + super.emit());
-            } else {
-                asm.emitString("cvt." + super.emit());
-            }
-        }
-    }
-
-    public static class Mov extends SingleOperandFormat {
-
-        private int predicateRegisterNumber = -1;
-
-        public Mov(Variable dst, Value src) {
-            super(dst, src);
-        }
-
-        public Mov(Variable dst, Value src, int predicate) {
-            super(dst, src);
-            this.predicateRegisterNumber = predicate;
-        }
-
-        /*
-         * public Mov(Variable dst, AbstractAddress src) { throw
-         * GraalInternalError.unimplemented("AbstractAddress Mov"); }
-         */
-
-        public void emit(PTXMacroAssembler asm) {
-            if (predicateRegisterNumber >= 0) {
-                asm.emitString("@%p" + String.valueOf(predicateRegisterNumber) + " mov." + super.emit());
-            } else {
-                asm.emitString("mov." + super.emit());
-            }
-        }
-    }
-
-    public static class Neg extends SingleOperandFormat {
-
-        public Neg(Variable dst, Variable src) {
-            super(dst, src);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("neg." + super.emit());
-        }
-    }
-
-    public static class Not extends BinarySingleOperandFormat {
-
-        public Not(Variable dst, Variable src) {
-            super(dst, src);
-        }
-
-        public void emit(PTXMacroAssembler asm) {
-            asm.emitString("not." + super.emit());
-        }
-    }
-
-    public static class Param extends SingleOperandFormat {
-        boolean isReturnParameter;
-
-        public Param(Variable d, boolean isRet) {
-            super(d, null);
-            isReturnParameter = isRet;
-        }
-
-        public String emitParameter(Variable v) {
-            return (" param" + v.index);
-        }
-
-        public void emit(PTXMacroAssembler asm, boolean isLastParam) {
-            asm.emitString(".param ." + paramForKind(dest.getKind()) + emitParameter(dest) + (isLastParam ? "" : ","));
-        }
-
-        public String paramForKind(Kind k) {
-            if (isReturnParameter) {
-                if (Unsafe.ADDRESS_SIZE == 8) {
-                    return "u64";
-                } else {
-                    return "u32";
-                }
-            } else {
-                switch (k.getTypeChar()) {
-                    case 'z':
-                    case 'f':
-                        return "s32";
-                    case 'b':
-                        return "b8";
-                    case 's':
-                        return "s16";
-                    case 'c':
-                        return "u16";
-                    case 'i':
-                        return "s32";
-                    case 'j':
-                        return "s64";
-                    case 'd':
-                        return "f64";
-                    case 'a':
-                        return "u64";
-                    default:
-                        throw GraalInternalError.shouldNotReachHere();
-                }
-            }
-        }
-
-    }
-
-}
--- a/graal/com.oracle.graal.asm.ptx/src/com/oracle/graal/asm/ptx/PTXStateSpace.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,49 +0,0 @@
-/*
- * Copyright (c) 2013, 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.asm.ptx;
-
-/**
- * Represents the various PTX state spaces.
- */
-public enum PTXStateSpace {
-
-    Parameter("param"),
-
-    Shared("shared"),
-
-    Local("local"),
-
-    Global("global"),
-
-    Const("const");
-
-    private final String stateName;
-
-    private PTXStateSpace(String name) {
-        this.stateName = name;
-    }
-
-    public String getStateName() {
-        return stateName;
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test.infra/src/com/oracle/graal/compiler/hsail/test/infra/ForceDeoptSubstitutions.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 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.compiler.hsail.test.infra;
-
-import com.oracle.graal.api.replacements.*;
-import com.oracle.graal.nodes.*;
-import com.oracle.graal.api.meta.*;
-
-@ClassSubstitution(GraalKernelTester.class)
-class ForceDeoptSubstitutions {
-
-    /**
-     * Allows us to force a non-exception throwing deopt from java code.
-     */
-    @MethodSubstitution
-    public static int forceDeopt(int x) {
-        DeoptimizeNode.deopt(DeoptimizationAction.None, DeoptimizationReason.RuntimeConstraint);
-        // will never get here but keep the compiler happy
-        return x * x;
-    }
-
-    @MethodSubstitution
-    public static double forceDeopt(double x) {
-        DeoptimizeNode.deopt(DeoptimizationAction.None, DeoptimizationReason.RuntimeConstraint);
-        // will never get here but keep the compiler happy
-        return x * x;
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test.infra/src/com/oracle/graal/compiler/hsail/test/infra/GraalKernelTester.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,226 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test.infra;
-
-/**
- * This class extends KernelTester and provides a base class
- * for which the HSAIL code comes from the Graal compiler.
- */
-import static com.oracle.graal.compiler.common.GraalOptions.*;
-import static com.oracle.graal.hotspot.HotSpotGraalRuntime.*;
-import static org.junit.Assume.*;
-
-import java.io.*;
-import java.lang.reflect.*;
-
-import org.junit.*;
-
-import com.oracle.graal.api.code.*;
-import com.oracle.graal.api.meta.*;
-import com.oracle.graal.compiler.common.*;
-import com.oracle.graal.compiler.target.*;
-import com.oracle.graal.debug.*;
-import com.oracle.graal.gpu.*;
-import com.oracle.graal.hotspot.hsail.*;
-import com.oracle.graal.hotspot.meta.*;
-import com.oracle.graal.hsail.*;
-import com.oracle.graal.options.*;
-import com.oracle.graal.options.OptionValue.OverrideScope;
-
-public abstract class GraalKernelTester extends KernelTester {
-
-    private static boolean substitutionsInstalled;
-
-    private static synchronized void installSubstitutions() {
-        if (!substitutionsInstalled) {
-            getHSAILBackend().getProviders().getReplacements().registerSubstitutions(GraalKernelTester.class, ForceDeoptSubstitutions.class);
-            substitutionsInstalled = true;
-        }
-    }
-
-    public GraalKernelTester() {
-        super(getHSAILBackend().isDeviceInitialized());
-        installSubstitutions();
-    }
-
-    protected static HSAILHotSpotBackend getHSAILBackend() {
-        Backend backend = runtime().getBackend(HSAIL.class);
-        Assume.assumeTrue("No HSAIL backend, skipping test!", backend instanceof HSAILHotSpotBackend);
-        return (HSAILHotSpotBackend) backend;
-    }
-
-    ExternalCompilationResult hsailCode;
-    private boolean showHsailSource = false;
-    private boolean saveInFile = false;
-
-    @Override
-    public String getCompiledHSAILSource(Method method) {
-        if (hsailCode == null) {
-            HSAILHotSpotBackend backend = getHSAILBackend();
-            ResolvedJavaMethod javaMethod = backend.getProviders().getMetaAccess().lookupJavaMethod(method);
-            hsailCode = backend.compileKernel(javaMethod, false);
-        }
-        String hsailSource = hsailCode.getCodeString();
-        if (showHsailSource) {
-            logger.severe(hsailSource);
-        }
-        if (saveInFile) {
-            try {
-                File fout = File.createTempFile("tmp", ".hsail");
-                logger.fine("creating " + fout.getCanonicalPath());
-                FileWriter fw = new FileWriter(fout);
-                BufferedWriter bw = new BufferedWriter(fw);
-                bw.write(hsailSource);
-                bw.close();
-            } catch (Exception e) {
-                e.printStackTrace();
-            }
-        }
-        return hsailSource;
-    }
-
-    public boolean aggressiveInliningEnabled() {
-        return (InlineEverything.getValue());
-    }
-
-    public boolean canHandleHSAILMethodCalls() {
-        // needs 2 things, backend needs to be able to generate such calls, and target needs to be
-        // able to run them
-        boolean canGenerateCalls = false;   // not implemented yet
-        boolean canExecuteCalls = runningOnSimulator();
-        return (canGenerateCalls && canExecuteCalls);
-    }
-
-    private static boolean supportsObjectAllocation() {
-        return true;
-    }
-
-    /**
-     * Determines if the runtime supports object allocation in HSAIL code.
-     */
-    public boolean canHandleObjectAllocation() {
-        return supportsObjectAllocation() && canDeoptimize();
-    }
-
-    /**
-     * Determines if the runtime supports deoptimization in HSAIL code.
-     */
-    public boolean canDeoptimize() {
-        return getHSAILBackend().getRuntime().getConfig().useHSAILDeoptimization;
-    }
-
-    /**
-     * Determines if we are running CQE tests (via a -D flag).
-     */
-    public boolean runningCQETests() {
-        return Boolean.getBoolean("com.amd.CQE");
-    }
-
-    /**
-     * Determines if the JVM supports the required typeProfileWidth.
-     */
-    public boolean typeProfileWidthAtLeast(int val) {
-        return (getHSAILBackend().getRuntime().getConfig().typeProfileWidth >= val);
-    }
-
-    /**
-     * Determines if the runtime supports {@link VirtualObject}s in {@link DebugInfo} associated
-     * with HSAIL code.
-     */
-    public boolean canHandleDeoptVirtualObjects() {
-        return true;
-    }
-
-    /**
-     * Determines if the runtime has the capabilities required by this test.
-     */
-    protected boolean supportsRequiredCapabilities() {
-        return true;
-    }
-
-    HotSpotNmethod installedCode;
-
-    @Override
-    protected void dispatchKernelOkra(int range, Object... args) {
-        HSAILHotSpotBackend backend = getHSAILBackend();
-        if (backend.isDeviceInitialized()) {
-            try {
-                if (installedCode == null) {
-                    installedCode = backend.compileAndInstallKernel(testMethod);
-                }
-                backend.executeKernel(installedCode, range, args);
-            } catch (InvalidInstalledCodeException e) {
-                Debug.log("WARNING:Invalid installed code: " + e);
-                e.printStackTrace();
-            }
-        } else {
-            super.dispatchKernelOkra(range, args);
-        }
-    }
-
-    public static OptionValue<?> getOptionFromField(Class<?> declaringClass, String fieldName) {
-        try {
-            Field f = declaringClass.getDeclaredField(fieldName);
-            f.setAccessible(true);
-            return (OptionValue<?>) f.get(null);
-        } catch (Exception e) {
-            throw new GraalInternalError(e);
-        }
-    }
-
-    private OptionValue<?> accessibleRemoveNeverExecutedCode = getOptionFromField(GraalOptions.class, "RemoveNeverExecutedCode");
-
-    // Special overrides for the testGeneratedxxx routines which set
-    // required graal options that we need to run any junit test
-
-    private OverrideScope getOverrideScope() {
-        return OptionValue.override(GraalOptions.InlineEverything, true, accessibleRemoveNeverExecutedCode, false);
-    }
-
-    @Override
-    public void testGeneratedHsail() {
-        try (OverrideScope s = getOverrideScope()) {
-            assumeTrue("Orka environment not initialized or unsupported!", supportsRequiredCapabilities() && okraEnvIsInitialized());
-            super.testGeneratedHsail();
-        }
-    }
-
-    @Override
-    public void testGeneratedHsailUsingLambdaMethod() {
-        try (OverrideScope s = getOverrideScope()) {
-            assumeTrue("Orka environment not initialized or unsupported!", supportsRequiredCapabilities() && okraEnvIsInitialized());
-            super.testGeneratedHsailUsingLambdaMethod();
-        }
-    }
-
-    // used for forcing a deoptimization
-    public static int forceDeopt(int x) {
-        return x * x;
-    }
-
-    public static double forceDeopt(double x) {
-        return x * x;
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test.infra/src/com/oracle/graal/compiler/hsail/test/infra/KernelTester.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,795 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test.infra;
-
-import static org.junit.Assert.*;
-import static org.junit.Assume.*;
-
-import java.io.*;
-import java.lang.annotation.*;
-import java.lang.reflect.*;
-import java.nio.file.*;
-import java.util.*;
-import java.util.concurrent.atomic.*;
-import java.util.logging.*;
-
-import com.amd.okra.*;
-import com.oracle.graal.test.*;
-
-/**
- * Abstract class on which the HSAIL unit tests are built. Executes a method or lambda on both the
- * Java side and the Okra side and compares the results for fields that are annotated with
- * {@link Result}.
- */
-public abstract class KernelTester extends GraalTest {
-
-    /**
-     * Denotes a field whose value is to be
-     * {@linkplain KernelTester#assertResultFieldsEqual(KernelTester) compared} as part of computing
-     * the result of a test.
-     */
-    @Retention(RetentionPolicy.RUNTIME)
-    @Target(ElementType.FIELD)
-    public @interface Result {
-    }
-
-    // Using these in case we want to compile with Java 7.
-    public interface MyIntConsumer {
-
-        void accept(int value);
-    }
-
-    public interface MyObjConsumer {
-
-        void accept(Object obj);
-    }
-
-    public enum DispatchMode {
-        SEQ,
-        JTP,
-        OKRA
-    }
-
-    public enum HsailMode {
-        COMPILED,
-        INJECT_HSAIL,
-        INJECT_OCL
-    }
-
-    public DispatchMode dispatchMode;
-    // Where the hsail comes from.
-    private HsailMode hsailMode;
-    protected Method testMethod;
-    // What type of okra dispatch to use when client calls.
-    private boolean useLambdaMethod;
-    private Class<?>[] testMethodParams = null;
-    private int id = nextId.incrementAndGet();
-    static AtomicInteger nextId = new AtomicInteger(0);
-    public static Logger logger;
-    private OkraContext okraContext;
-    private OkraKernel okraKernel;
-    private static final String propPkgName = KernelTester.class.getPackage().getName();
-    private static Level logLevel;
-    private static ConsoleHandler consoleHandler;
-    private boolean runOkraFirst = Boolean.getBoolean("kerneltester.runOkraFirst");
-
-    static {
-        logger = Logger.getLogger(propPkgName);
-        logLevel = Level.parse(System.getProperty("kerneltester.logLevel", "OFF"));
-
-        // This block configure the logger with handler and formatter.
-        consoleHandler = new ConsoleHandler();
-        logger.addHandler(consoleHandler);
-        logger.setUseParentHandlers(false);
-        SimpleFormatter formatter = new SimpleFormatter() {
-
-            @SuppressWarnings("sync-override")
-            @Override
-            public String format(LogRecord record) {
-                return (record.getMessage() + "\n");
-            }
-        };
-        consoleHandler.setFormatter(formatter);
-        setLogLevel(logLevel);
-    }
-
-    private static boolean gaveNoOkraWarning = false;
-    private boolean onSimulator;
-    private final boolean okraLibExists;
-
-    public boolean runningOnSimulator() {
-        return onSimulator;
-    }
-
-    public boolean okraEnvIsInitialized() {
-        return this.okraLibExists;
-    }
-
-    public KernelTester(boolean okraLibExists) {
-        dispatchMode = DispatchMode.SEQ;
-        hsailMode = HsailMode.COMPILED;
-        useLambdaMethod = false;
-
-        this.okraLibExists = okraLibExists || OkraUtil.okraLibExists();
-        if (!this.okraLibExists) {
-            logger.info("Okra native library cannot be found or loaded while running" + this.getClass().getSimpleName());
-            return;
-        }
-
-        // Control which okra instances can run the tests (isSimulator is static).
-        onSimulator = OkraContext.isSimulator();
-    }
-
-    public abstract void runTest();
-
-    /**
-     * Asserts that the value of all {@link Result} annotated fields in this object and
-     * {@code other} are {@linkplain #assertDeepEquals(Object, Object) equal}.
-     *
-     * @throws AssertionError if the value of a result field in this and {@code other} are not equal
-     */
-    public void assertResultFieldsEqual(KernelTester other) {
-        Class<?> clazz = this.getClass();
-        while (clazz != null && clazz != KernelTester.class) {
-            for (Field f : clazz.getDeclaredFields()) {
-                if (!Modifier.isStatic(f.getModifiers())) {
-                    Result annos = f.getAnnotation(Result.class);
-                    if (annos != null) {
-                        Object actualResult = getFieldFromObject(f, this);
-                        Object expectedResult = getFieldFromObject(f, other);
-                        assertDeepEquals(f.toString(), expectedResult, actualResult);
-                    }
-                }
-            }
-            clazz = clazz.getSuperclass();
-        }
-    }
-
-    public void setDispatchMode(DispatchMode dispatchMode) {
-        this.dispatchMode = dispatchMode;
-    }
-
-    public void setHsailMode(HsailMode hsailMode) {
-        this.hsailMode = hsailMode;
-    }
-
-    /**
-     * Return a clone of this instance unless overridden, we just call the null constructor.
-     */
-    public KernelTester newInstance() {
-        try {
-            return this.getClass().getConstructor((Class<?>[]) null).newInstance();
-        } catch (Throwable t) {
-            fail("Unexpected exception " + t);
-            return null;
-        }
-    }
-
-    public Method getMethodFromMethodName(String methName, Class<?> clazz) {
-        Class<?> clazz2 = clazz;
-        while (clazz2 != null) {
-            for (Method m : clazz2.getDeclaredMethods()) {
-                logger.fine(" in " + clazz2 + ", trying to match " + m);
-                if (m.getName().equals(methName)) {
-                    testMethodParams = m.getParameterTypes();
-                    if (logLevel.intValue() <= Level.FINE.intValue()) {
-                        logger.fine(" in " + clazz2 + ", matched " + m);
-                        logger.fine("parameter types are...");
-                        int paramNum = 0;
-                        for (Class<?> pclazz : testMethodParams) {
-                            logger.fine(paramNum++ + ") " + pclazz.toString());
-                        }
-                    }
-                    return m;
-                }
-            }
-            // Didn't find it in current clazz, try superclass.
-            clazz2 = clazz2.getSuperclass();
-        }
-        // If we got this far, no match.
-        return null;
-    }
-
-    private void setTestMethod(String methName, Class<?> inClazz) {
-        testMethod = getMethodFromMethodName(methName, inClazz);
-        if (testMethod == null) {
-            fail("cannot find method " + methName + " in class " + inClazz);
-        } else {
-            // Print info but only for first such class.
-            if (id == 1) {
-                logger.fine("testMethod to be compiled is \n   " + testMethod);
-            }
-        }
-    }
-
-    // Default is method name "run", but could be overridden.
-    private final String defaultMethodName = "run";
-
-    public String getTestMethodName() {
-        return defaultMethodName;
-    }
-
-    /**
-     * The dispatchMethodKernel dispatches a non-lambda method. All the parameters of the compiled
-     * method are supplied as parameters to this call.
-     */
-    public void dispatchMethodKernel(int range, Object... args) {
-        if (testMethod == null) {
-            setTestMethod(getTestMethodName(), this.getClass());
-        }
-        if (dispatchMode == DispatchMode.SEQ) {
-            dispatchMethodKernelSeq(range, args);
-        } else if (dispatchMode == DispatchMode.OKRA) {
-            dispatchMethodKernelOkra(range, args);
-        }
-    }
-
-    /**
-     * The "array stream" version of {@link #dispatchMethodKernel(int, Object...)}.
-     */
-    public void dispatchMethodKernel(Object[] ary, Object... args) {
-        if (testMethod == null) {
-            setTestMethod(getTestMethodName(), this.getClass());
-        }
-        if (dispatchMode == DispatchMode.SEQ) {
-            dispatchMethodKernelSeq(ary, args);
-        } else if (dispatchMode == DispatchMode.OKRA) {
-            dispatchMethodKernelOkra(ary, args);
-        }
-    }
-
-    /**
-     * This dispatchLambdaMethodKernel dispatches the lambda version of a kernel where the "kernel"
-     * is for the lambda method itself (like lambda$0).
-     */
-    public void dispatchLambdaMethodKernel(int range, MyIntConsumer consumer) {
-        if (testMethod == null) {
-            setTestMethod(findLambdaMethodName(), this.getClass());
-        }
-        if (dispatchMode == DispatchMode.SEQ) {
-            dispatchLambdaKernelSeq(range, consumer);
-        } else if (dispatchMode == DispatchMode.OKRA) {
-            dispatchLambdaMethodKernelOkra(range, consumer);
-        }
-    }
-
-    public void dispatchLambdaMethodKernel(Object[] ary, MyObjConsumer consumer) {
-        if (testMethod == null) {
-            setTestMethod(findLambdaMethodName(), this.getClass());
-        }
-        if (dispatchMode == DispatchMode.SEQ) {
-            dispatchLambdaKernelSeq(ary, consumer);
-        } else if (dispatchMode == DispatchMode.OKRA) {
-            dispatchLambdaMethodKernelOkra(ary, consumer);
-        }
-    }
-
-    /**
-     * Dispatches the lambda version of a kernel where the "kernel" is for the xxx$$Lambda.accept
-     * method in the wrapper for the lambda. Note that the useLambdaMethod boolean provides a way of
-     * actually invoking dispatchLambdaMethodKernel from this API.
-     */
-    public void dispatchLambdaKernel(int range, MyIntConsumer consumer) {
-        if (useLambdaMethod) {
-            dispatchLambdaMethodKernel(range, consumer);
-            return;
-        }
-        if (testMethod == null) {
-            setTestMethod("accept", consumer.getClass());
-        }
-        if (dispatchMode == DispatchMode.SEQ) {
-            dispatchLambdaKernelSeq(range, consumer);
-        } else if (dispatchMode == DispatchMode.OKRA) {
-            dispatchLambdaKernelOkra(range, consumer);
-        }
-    }
-
-    public void dispatchLambdaKernel(Object[] ary, MyObjConsumer consumer) {
-        if (useLambdaMethod) {
-            dispatchLambdaMethodKernel(ary, consumer);
-            return;
-        }
-        if (testMethod == null) {
-            setTestMethod("accept", consumer.getClass());
-        }
-        if (dispatchMode == DispatchMode.SEQ) {
-            dispatchLambdaKernelSeq(ary, consumer);
-        } else if (dispatchMode == DispatchMode.OKRA) {
-            dispatchLambdaKernelOkra(ary, consumer);
-        }
-    }
-
-    private ArrayList<String> getLambdaMethodNames() {
-        Class<?> clazz = this.getClass();
-        ArrayList<String> lambdaNames = new ArrayList<>();
-        while (clazz != null && (lambdaNames.size() == 0)) {
-            for (Method m : clazz.getDeclaredMethods()) {
-                logger.fine(" in " + clazz + ", trying to match " + m);
-                if (m.getName().startsWith("lambda$")) {
-                    lambdaNames.add(m.getName());
-                }
-            }
-            // Didn't find it in current clazz, try superclass.
-            clazz = clazz.getSuperclass();
-        }
-        return lambdaNames;
-    }
-
-    /**
-     * findLambdaMethodName finds a name in the class starting with lambda$. If we find more than
-     * one, throw an error, and tell user to override explicitly
-     */
-    private String findLambdaMethodName() {
-        // If user overrode getTestMethodName, use that name.
-        if (!getTestMethodName().equals(defaultMethodName)) {
-            return getTestMethodName();
-        } else {
-            ArrayList<String> lambdaNames = getLambdaMethodNames();
-            switch (lambdaNames.size()) {
-                case 1:
-                    return lambdaNames.get(0);
-                case 0:
-                    fail("No lambda method found in " + this.getClass());
-                    return null;
-                default:
-                    // More than one lambda.
-                    String msg = "Multiple lambda methods found in " + this.getClass() + "\nYou should override getTestMethodName with one of the following\n";
-                    for (String name : lambdaNames) {
-                        msg = msg + name + "\n";
-                    }
-                    fail(msg);
-                    return null;
-            }
-        }
-    }
-
-    /**
-     * The getCompiledHSAILSource returns the string of HSAIL code for the compiled method. By
-     * default, throws an error. In graal for instance, this would be overridden in
-     * GraalKernelTester.
-     */
-    public String getCompiledHSAILSource(Method testMethod1) {
-        fail("no compiler connected so unable to compile " + testMethod1 + "\nYou could try injecting HSAIL or OpenCL");
-        return null;
-    }
-
-    public String getHSAILSource(Method testMethod1) {
-        switch (hsailMode) {
-            case COMPILED:
-                return getCompiledHSAILSource(testMethod1);
-            case INJECT_HSAIL:
-                return getHsailFromClassnameHsailFile();
-            case INJECT_OCL:
-                return getHsailFromClassnameOclFile();
-            default:
-                fail("unknown hsailMode = " + hsailMode);
-                return null;
-        }
-    }
-
-    /**
-     * The getHSAILKernelName returns the name of the hsail kernel. By default we use 'run'. unless
-     * coming from opencl injection. Could be overridden by the junit test.
-     */
-    public String getHSAILKernelName() {
-        return (hsailMode != HsailMode.INJECT_OCL ? "&run" : "&__OpenCL_run_kernel");
-    }
-
-    private void createOkraKernel() {
-        // Call routines in the derived class to get the hsail code and kernel name.
-        String hsailSource = getHSAILSource(testMethod);
-        if (!okraLibExists) {
-            if (!gaveNoOkraWarning) {
-                logger.severe("No Okra library detected, skipping all KernelTester tests in " + this.getClass().getPackage().getName());
-                gaveNoOkraWarning = true;
-            }
-        }
-        // Ignore any kerneltester test if okra does not exist.
-        assumeTrue("No Okra library detected, skipping test!", okraLibExists);
-        // Control which okra instances can run the tests.
-        onSimulator = OkraContext.isSimulator();
-        okraContext = new OkraContext();
-        if (!okraContext.isValid()) {
-            fail("...unable to create context");
-        }
-        // Control verbosity in okra from our logLevel.
-        if (logLevel.intValue() <= Level.INFO.intValue()) {
-            okraContext.setVerbose(true);
-        }
-        okraKernel = new OkraKernel(okraContext, hsailSource, getHSAILKernelName());
-        if (!okraKernel.isValid()) {
-            fail("...unable to create kernel");
-        }
-    }
-
-    /**
-     * Dispatches an okra kernel over a given range using JNI. Protected so that it can be
-     * overridden in {@link GraalKernelTester} which will dispatch without JNI.
-     */
-    protected void dispatchKernelOkra(int range, Object... args) {
-        if (okraKernel == null) {
-            createOkraKernel();
-        }
-        if (logLevel.intValue() <= Level.FINE.intValue()) {
-            logger.fine("Arguments passed to okra...");
-            for (Object arg : args) {
-                logger.fine("  " + arg);
-            }
-        }
-        okraKernel.setLaunchAttributes(range);
-        okraKernel.dispatchWithArgs(args);
-    }
-
-    // int stream version
-    private void dispatchMethodKernelSeq(int range, Object... args) {
-        Object[] invokeArgs = new Object[args.length + 1];
-        // Need space on the end for the gid parameter.
-        System.arraycopy(args, 0, invokeArgs, 0, args.length);
-        int gidArgIndex = invokeArgs.length - 1;
-        if (logLevel.intValue() <= Level.FINE.intValue()) {
-            for (Object arg : args) {
-                logger.fine(arg.toString());
-            }
-        }
-        for (int rangeIndex = 0; rangeIndex < range; rangeIndex++) {
-            invokeArgs[gidArgIndex] = rangeIndex;
-            invokeMethodKernelSeq(invokeArgs, rangeIndex);
-        }
-    }
-
-    // array stream version
-    private void dispatchMethodKernelSeq(Object[] ary, Object... args) {
-        Object[] invokeArgs = new Object[args.length + 1];
-        // Need space on the end for the final obj parameter.
-        System.arraycopy(args, 0, invokeArgs, 0, args.length);
-        int objArgIndex = invokeArgs.length - 1;
-        if (logLevel.intValue() <= Level.FINE.intValue()) {
-            for (Object arg : args) {
-                logger.fine(arg.toString());
-            }
-        }
-        int range = ary.length;
-        for (int rangeIndex = 0; rangeIndex < range; rangeIndex++) {
-            invokeArgs[objArgIndex] = ary[rangeIndex];
-            invokeMethodKernelSeq(invokeArgs, rangeIndex);
-        }
-    }
-
-    private void invokeMethodKernelSeq(Object[] invokeArgs, int rangeIndex) {
-        try {
-            testMethod.invoke(this, invokeArgs);
-        } catch (IllegalAccessException e) {
-            fail("could not invoke " + testMethod + ", make sure it is public");
-        } catch (IllegalArgumentException e) {
-            fail("wrong arguments invoking " + testMethod + ", check number and type of args passed to dispatchMethodKernel");
-        } catch (InvocationTargetException e) {
-            Throwable cause = e.getCause();
-            if (cause instanceof RuntimeException) {
-                throw ((RuntimeException) cause);
-            } else {
-                String errstr = testMethod + " threw a checked exception on gid=" + rangeIndex + ", exception was " + cause;
-                fail(errstr);
-            }
-        } catch (Exception e) {
-            fail("Unknown exception " + e + " invoking " + testMethod);
-        }
-    }
-
-    // int stream version
-    private void dispatchMethodKernelOkra(int range, Object... args) {
-        Object[] fixedArgs = fixArgTypes(args);
-        if (Modifier.isStatic(testMethod.getModifiers())) {
-            dispatchKernelOkra(range, fixedArgs);
-        } else {
-            // If it is a non-static method we have to push "this" as the first argument.
-            Object[] newFixedArgs = new Object[fixedArgs.length + 1];
-            System.arraycopy(fixedArgs, 0, newFixedArgs, 1, fixedArgs.length);
-            newFixedArgs[0] = this;
-            dispatchKernelOkra(range, newFixedArgs);
-        }
-    }
-
-    // array stream version
-    private void dispatchMethodKernelOkra(Object[] ary, Object... args) {
-        // add the ary itself as the last arg in the passed parameter list
-        Object[] argsWithAry = new Object[args.length + 1];
-        System.arraycopy(args, 0, argsWithAry, 0, args.length);
-        argsWithAry[argsWithAry.length - 1] = ary;
-
-        Object[] fixedArgs = fixArgTypes(argsWithAry);
-        int range = ary.length;
-        if (Modifier.isStatic(testMethod.getModifiers())) {
-            dispatchKernelOkra(range, fixedArgs);
-        } else {
-            // If it is a non-static method we have to push "this" as the first argument.
-            Object[] newFixedArgs = new Object[fixedArgs.length + 1];
-            System.arraycopy(fixedArgs, 0, newFixedArgs, 1, fixedArgs.length);
-            newFixedArgs[0] = this;
-            dispatchKernelOkra(range, newFixedArgs);
-        }
-    }
-
-    /**
-     * For primitive arg parameters, make sure arg types are cast to whatever the testMethod
-     * signature says they should be.
-     */
-    protected Object[] fixArgTypes(Object[] args) {
-        Object[] fixedArgs = new Object[args.length];
-        for (int i = 0; i < args.length; i++) {
-            Class<?> paramClass = testMethodParams[i];
-            if (paramClass.equals(Float.class) || paramClass.equals(float.class)) {
-                fixedArgs[i] = ((Number) args[i]).floatValue();
-            } else if (paramClass.equals(Integer.class) || paramClass.equals(int.class)) {
-                fixedArgs[i] = ((Number) args[i]).intValue();
-            } else if (paramClass.equals(Long.class) || paramClass.equals(long.class)) {
-                fixedArgs[i] = ((Number) args[i]).longValue();
-            } else if (paramClass.equals(Double.class) || paramClass.equals(double.class)) {
-                fixedArgs[i] = ((Number) args[i]).doubleValue();
-            } else if (paramClass.equals(Byte.class) || paramClass.equals(byte.class)) {
-                fixedArgs[i] = ((Number) args[i]).byteValue();
-            } else if (paramClass.equals(Boolean.class) || paramClass.equals(boolean.class)) {
-                fixedArgs[i] = (boolean) args[i];
-            } else {
-                // All others just move unchanged.
-                fixedArgs[i] = args[i];
-            }
-        }
-        return fixedArgs;
-    }
-
-    /**
-     * Dispatching a lambda on the java side is simple.
-     */
-    @SuppressWarnings("static-method")
-    private void dispatchLambdaKernelSeq(int range, MyIntConsumer consumer) {
-        for (int i = 0; i < range; i++) {
-            consumer.accept(i);
-        }
-    }
-
-    @SuppressWarnings("static-method")
-    private void dispatchLambdaKernelSeq(Object[] ary, MyObjConsumer consumer) {
-        for (Object obj : ary) {
-            consumer.accept(obj);
-        }
-    }
-
-    /**
-     * The dispatchLambdaMethodKernelOkra dispatches in the case where the hsail kernel implements
-     * the lambda method itself as opposed to the wrapper that calls the lambda method. From the
-     * consumer object, we need to find the fields and pass them to the kernel.
-     */
-    protected void dispatchLambdaMethodKernelOkra(int range, MyIntConsumer consumer) {
-        logger.info("To determine parameters to pass to hsail kernel, we will examine   " + consumer.getClass());
-        Field[] fields = consumer.getClass().getDeclaredFields();
-        Object[] args = new Object[fields.length];
-        int argIndex = 0;
-        for (Field f : fields) {
-            logger.info("... " + f);
-            args[argIndex++] = getFieldFromObject(f, consumer);
-        }
-        dispatchKernelOkra(range, args);
-    }
-
-    private void dispatchLambdaMethodKernelOkra(Object[] ary, MyObjConsumer consumer) {
-        logger.info("To determine parameters to pass to hsail kernel, we will examine   " + consumer.getClass());
-        Field[] fields = consumer.getClass().getDeclaredFields();
-        Object[] args = new Object[fields.length + 1];  // + 1 because we also pass the array
-        int argIndex = 0;
-        for (Field f : fields) {
-            logger.info("... " + f);
-            args[argIndex++] = getFieldFromObject(f, consumer);
-        }
-        args[argIndex] = ary;
-        dispatchKernelOkra(ary.length, args);
-    }
-
-    /**
-     * The dispatchLambdaKernelOkra dispatches in the case where the hsail kernel where the hsail
-     * kernel implements the accept method of the wrapper that calls the lambda method as opposed to
-     * the actual lambda method itself.
-     */
-    private void dispatchLambdaKernelOkra(int range, MyIntConsumer consumer) {
-        // The "wrapper" method always has only one arg consisting of the consumer.
-        Object[] args = new Object[1];
-        args[0] = consumer;
-        dispatchKernelOkra(range, args);
-    }
-
-    private void dispatchLambdaKernelOkra(Object[] ary, MyObjConsumer consumer) {
-        // The "wrapper" method always has only one arg consisting of the consumer.
-        Object[] args = new Object[2];
-        args[0] = consumer;
-        args[1] = ary;
-        dispatchKernelOkra(ary.length, args);
-    }
-
-    private void disposeKernelOkra() {
-        if (okraContext != null) {
-            okraContext.dispose();
-        }
-    }
-
-    private void assertOkraEqualsSeq(HsailMode hsailModeToUse) {
-        assertOkraEqualsSeq(hsailModeToUse, false);
-    }
-
-    /**
-     * Runs this instance on OKRA, and as SEQ and compares the output of the two executions. the
-     * runOkraFirst flag controls which order they are done in. Note the compiler must use eager
-     * resolving if Okra is done first.
-     */
-    private void assertOkraEqualsSeq(HsailMode hsailModeToUse, boolean useLambda) {
-        KernelTester testerSeq;
-        if (runOkraFirst) {
-            runOkraInstance(hsailModeToUse, useLambda);
-            testerSeq = runSeqInstance();
-        } else {
-            testerSeq = runSeqInstance();
-            runOkraInstance(hsailModeToUse, useLambda);
-        }
-        assertResultFieldsEqual(testerSeq);
-    }
-
-    private void runOkraInstance(HsailMode hsailModeToUse, boolean useLambda) {
-        // run Okra instance in exiting KernelTester object
-        this.setHsailMode(hsailModeToUse);
-        this.setDispatchMode(DispatchMode.OKRA);
-        this.useLambdaMethod = useLambda;
-        this.runTest();
-        this.disposeKernelOkra();
-    }
-
-    private KernelTester runSeqInstance() {
-        // Create and run sequential instance.
-        KernelTester testerSeq = newInstance();
-        testerSeq.setDispatchMode(DispatchMode.SEQ);
-        testerSeq.runTest();
-        return testerSeq;
-    }
-
-    public void testGeneratedHsail() {
-        assertOkraEqualsSeq(HsailMode.COMPILED);
-    }
-
-    public void testGeneratedHsailUsingLambdaMethod() {
-        assertOkraEqualsSeq(HsailMode.COMPILED, true);
-    }
-
-    public void testInjectedHsail() {
-        newInstance().assertOkraEqualsSeq(HsailMode.INJECT_HSAIL);
-    }
-
-    public void testInjectedOpencl() {
-        newInstance().assertOkraEqualsSeq(HsailMode.INJECT_OCL);
-    }
-
-    protected static Object getFieldFromObject(Field f, Object fromObj) {
-        try {
-            f.setAccessible(true);
-            Type type = f.getType();
-            logger.info("type = " + type);
-            if (type == double.class) {
-                return f.getDouble(fromObj);
-            } else if (type == float.class) {
-                return f.getFloat(fromObj);
-            } else if (type == long.class) {
-                return f.getLong(fromObj);
-            } else if (type == int.class) {
-                return f.getInt(fromObj);
-            } else if (type == byte.class) {
-                return f.getByte(fromObj);
-            } else if (type == boolean.class) {
-                return f.getBoolean(fromObj);
-            } else {
-                return f.get(fromObj);
-            }
-        } catch (Exception e) {
-            fail("unable to get field " + f + " from " + fromObj);
-            return null;
-        }
-    }
-
-    public static void checkFileExists(String fileName) {
-        assertTrue(fileName + " does not exist", fileExists(fileName));
-    }
-
-    public static boolean fileExists(String fileName) {
-        return new File(fileName).exists();
-    }
-
-    public static String getFileAsString(String sourceFileName) {
-        String source = null;
-        try {
-            checkFileExists(sourceFileName);
-            source = new String(Files.readAllBytes(FileSystems.getDefault().getPath(sourceFileName)));
-        } catch (IOException e) {
-            fail("could not open file " + sourceFileName);
-            return null;
-        }
-        return source;
-    }
-
-    public static String getHsailFromFile(String sourceFileName) {
-        logger.severe("... getting hsail from file " + sourceFileName);
-        return getFileAsString(sourceFileName);
-    }
-
-    private static void executeCmd(String... cmd) {
-        logger.info("spawning" + Arrays.toString(cmd));
-        try {
-            ProcessBuilder pb = new ProcessBuilder(cmd);
-            Process p = pb.start();
-            if (logLevel.intValue() <= Level.INFO.intValue()) {
-                InputStream in = p.getInputStream();
-                BufferedInputStream buf = new BufferedInputStream(in);
-                InputStreamReader inread = new InputStreamReader(buf);
-                BufferedReader bufferedreader = new BufferedReader(inread);
-                String line;
-                while ((line = bufferedreader.readLine()) != null) {
-                    logger.info(line);
-                }
-            }
-            p.waitFor();
-        } catch (Exception e) {
-            fail("could not execute <" + Arrays.toString(cmd) + ">");
-        }
-    }
-
-    public static String getHsailFromOpenCLFile(String openclFileName) {
-        String openclHsailFile = "opencl_out.hsail";
-        String tmpTahitiFile = "_temp_0_Tahiti.txt";
-        checkFileExists(openclFileName);
-        logger.severe("...converting " + openclFileName + " to HSAIL...");
-        executeCmd("aoc2", "-m64", "-I./", "-march=hsail", openclFileName);
-        if (fileExists(tmpTahitiFile)) {
-            return getFileAsString(tmpTahitiFile);
-        } else {
-            executeCmd("HSAILasm", "-disassemble", "-o", openclHsailFile, openclFileName.replace(".cl", ".bin"));
-            checkFileExists(openclHsailFile);
-            return getFileAsString(openclHsailFile);
-        }
-    }
-
-    public String getHsailFromClassnameHsailFile() {
-        return (getHsailFromFile(this.getClass().getSimpleName() + ".hsail"));
-    }
-
-    public String getHsailFromClassnameOclFile() {
-        return (getHsailFromOpenCLFile(this.getClass().getSimpleName() + ".cl"));
-    }
-
-    public static void logInfo(String msg) {
-        logger.info(msg);
-    }
-
-    public static void logSevere(String msg) {
-        logger.severe(msg);
-    }
-
-    public static void setLogLevel(Level level) {
-        logLevel = level;
-        logger.setLevel(level);
-        consoleHandler.setLevel(level);
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntBase.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Tests codegen for an IJ signature {@code IntStream} instance function.
- */
-public abstract class ArgsIntBase extends GraalKernelTester {
-
-    static final int NUM = 20;
-
-    @Result public double[] outArray = new double[NUM];
-
-    void setupArrays() {
-        for (int i = 0; i < NUM; i++) {
-            outArray[i] = -i;
-        }
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntInstIITest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an II signature {@code IntStream} instance function.
- */
-public class ArgsIntInstIITest extends ArgsIntBase {
-
-    public void run(int arg1, int arg2, int gid) {
-        outArray[gid] = gid + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(NUM, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntInstIJTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an IJ signature {@code IntStream} instance function.
- */
-public class ArgsIntInstIJTest extends ArgsIntBase {
-
-    public void run(int arg1, long arg2, int gid) {
-        outArray[gid] = gid + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(NUM, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntStatAIITest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an AII signature {@code IntStream} static function.
- */
-public class ArgsIntStatAIITest extends ArgsIntBase {
-
-    public static void run(double[] out, int arg1, int arg2, int gid) {
-        out[gid] = gid + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(NUM, outArray, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsIntStatAIJTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an AIJ signature {@code IntStream} static function.
- */
-public class ArgsIntStatAIJTest extends ArgsIntBase {
-
-    public static void run(double[] out, int arg1, long arg2, int gid) {
-        out[gid] = gid + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(NUM, outArray, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjBase.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Tests codegen for an IJ signature Object stream instance function.
- */
-public abstract class ArgsObjBase extends GraalKernelTester {
-
-    static class MyObj {
-        public int id;
-        public double d;
-
-        public MyObj(int id) {
-            this.id = id;
-        }
-
-        @Override
-        public boolean equals(Object other) {
-            if (!(other instanceof MyObj)) {
-                return false;
-            }
-            MyObj oth = (MyObj) other;
-            return (oth.id == id && oth.d == d);
-        }
-
-        @Override
-        public String toString() {
-            return ("MyObj[" + id + ", " + d + "]");
-        }
-
-        @Override
-        public int hashCode() {
-            return id;
-        }
-
-    }
-
-    static final int NUM = 20;
-
-    @Result public MyObj[] outArray = new MyObj[NUM];
-
-    void setupArrays() {
-        for (int i = 0; i < NUM; i++) {
-            outArray[i] = new MyObj(i + 1);
-        }
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjInstIITest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an II signature Object stream instance function.
- */
-public class ArgsObjInstIITest extends ArgsObjBase {
-
-    public void run(int arg1, int arg2, MyObj myobj) {
-        myobj.d = myobj.id + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(outArray, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjInstIJTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an IJ signature Object stream instance function.
- */
-public class ArgsObjInstIJTest extends ArgsObjBase {
-
-    public void run(int arg1, long arg2, MyObj myobj) {
-        myobj.d = myobj.id + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(outArray, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjStatIITest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an II signature Object stream static function.
- */
-public class ArgsObjStatIITest extends ArgsObjBase {
-
-    public static void run(int arg1, int arg2, MyObj myobj) {
-        myobj.d = myobj.id + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(outArray, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ArgsObjStatIJTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * Tests codegen for an IJ signature Object stream static function.
- */
-public class ArgsObjStatIJTest extends ArgsObjBase {
-
-    public static void run(int arg1, long arg2, MyObj myobj) {
-        myobj.d = myobj.id + arg1 + arg2;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-        dispatchMethodKernel(outArray, 7, 6);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicIntGetAndAddTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) 2013, 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.compiler.hsail.test;
-
-import java.util.*;
-import java.util.concurrent.atomic.*;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Tests {@link AtomicInteger#getAndAdd(int)} which tests HSAIL atomic_add codegen.
- */
-public class AtomicIntGetAndAddTest extends GraalKernelTester {
-
-    static final int NUM = 20;
-    @Result public int[] outArray = new int[NUM];
-    AtomicInteger atomicInt = new AtomicInteger();
-
-    void setupArrays() {
-        for (int i = 0; i < NUM; i++) {
-            outArray[i] = -i;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-
-        dispatchMethodKernel(NUM);
-
-        // note: the actual order of entries in outArray is not predictable
-        // thus we sort before we compare results
-        Arrays.sort(outArray);
-    }
-
-    public void run(int gid) {
-        outArray[gid] = atomicInt.getAndAdd(0x7);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicIntGetAndSetTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 2013, 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.compiler.hsail.test;
-
-import java.util.*;
-import java.util.concurrent.atomic.*;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Tests {@link AtomicInteger#getAndSet(int)} which tests HSAIL atomic_exch codegen.
- */
-public class AtomicIntGetAndSetTest extends GraalKernelTester {
-
-    static final int NUM = 1000;
-    @Result public int[] outArray = new int[NUM];
-    AtomicInteger atomicInt = new AtomicInteger(Integer.MAX_VALUE);
-
-    void setupArrays() {
-        for (int i = 0; i < NUM; i++) {
-            outArray[i] = -i;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-
-        dispatchMethodKernel(NUM);
-        // to complete the circle, replace the initial get value with that of the last executor
-        for (int i = 0; i < NUM; i++) {
-            if (outArray[i] == Integer.MAX_VALUE) {
-                outArray[i] = atomicInt.get();
-            }
-        }
-
-        // note: the actual order of entries in outArray is not predictable
-        // thus we sort before we compare results
-        Arrays.sort(outArray);
-    }
-
-    public void run(int gid) {
-        outArray[gid] = atomicInt.getAndSet(gid);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicLongGetAndAddTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) 2013, 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.compiler.hsail.test;
-
-import java.util.*;
-import java.util.concurrent.atomic.*;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Tests {@link AtomicLong#getAndAdd(long)} which tests HSAIL atomic_add codegen.
- */
-public class AtomicLongGetAndAddTest extends GraalKernelTester {
-
-    static final int NUM = 20;
-    @Result public long[] outArray = new long[NUM];
-    AtomicLong atomicLong = new AtomicLong();
-
-    void setupArrays() {
-        for (int i = 0; i < NUM; i++) {
-            outArray[i] = -i;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-
-        dispatchMethodKernel(NUM);
-
-        // note: the actual order of entries in outArray is not predictable
-        // thus we sort before we compare results
-        Arrays.sort(outArray);
-    }
-
-    public void run(int gid) {
-        outArray[gid] = atomicLong.getAndAdd(0x7);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicLongGetAndSetTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 2013, 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.compiler.hsail.test;
-
-import java.util.*;
-import java.util.concurrent.atomic.*;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Tests {@link AtomicLong#getAndSet(long)} which tests HSAIL atomic_exch codegen.
- */
-public class AtomicLongGetAndSetTest extends GraalKernelTester {
-
-    static final int NUM = 1000;
-    @Result public long[] outArray = new long[NUM];
-    AtomicLong atomicLong = new AtomicLong(Long.MAX_VALUE);
-
-    void setupArrays() {
-        for (int i = 0; i < NUM; i++) {
-            outArray[i] = -i;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-
-        dispatchMethodKernel(NUM);
-        // to complete the circle, replace the initial get value with that of the last executor
-        for (int i = 0; i < NUM; i++) {
-            if (outArray[i] == Long.MAX_VALUE) {
-                outArray[i] = atomicLong.get();
-            }
-        }
-
-        // note: the actual order of entries in outArray is not predictable
-        // thus we sort before we compare results
-        Arrays.sort(outArray);
-    }
-
-    public void run(int gid) {
-        outArray[gid] = atomicLong.getAndSet(gid);
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/AtomicReferenceGetAndSetTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,102 +0,0 @@
-/*
- * Copyright (c) 2013, 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.compiler.hsail.test;
-
-import java.util.concurrent.atomic.*;
-
-import org.junit.*;
-
-import sun.misc.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-import com.oracle.graal.debug.*;
-
-/**
- * Tests {@link AtomicReference#getAndSet(Object)} which indirectly tests
- * {@link Unsafe#compareAndSwapObject(Object, long, Object, Object)}. The latter requires special
- * handling if compressed oops are enabled.
- */
-public class AtomicReferenceGetAndSetTest extends GraalKernelTester {
-
-    static final int NUM = 20;
-    @Result public int[] followedCount = new int[NUM];
-    public MyObj[] inArray = new MyObj[NUM];
-    AtomicReference<MyObj> atomicRef = new AtomicReference<>();
-
-    public static class MyObj {
-        public int val;
-        public boolean[] followedBy = new boolean[NUM + 1];
-
-        MyObj(int n) {
-            val = n;
-        }
-    }
-
-    void setupArrays() {
-        for (int i = 0; i < NUM; i++) {
-            inArray[i] = new MyObj(i + 1);
-        }
-        atomicRef.set(new MyObj(0)); // initial value
-    }
-
-    private static final boolean DEBUG = false;
-
-    @Override
-    public void runTest() {
-        setupArrays();
-
-        dispatchMethodKernel(NUM);
-
-        // make a fake followedBy for the final object
-        MyObj finalObj = atomicRef.get();
-        finalObj.followedBy[0] = true;
-
-        // When the kernel is done, compute the number of true bits in each followedBy array;
-        for (int i = 0; i < NUM; i++) {
-            MyObj obj = inArray[i];
-            int count = 0;
-            for (int j = 0; j < NUM + 1; j++) {
-                boolean b = obj.followedBy[j];
-                if (b) {
-                    count++;
-                    if (DEBUG) {
-                        TTY.println("obj " + obj.val + " was followed by " + j);
-                    }
-                }
-
-            }
-            followedCount[i] = count;
-        }
-    }
-
-    public void run(int gid) {
-        MyObj newObj = inArray[gid];
-        MyObj oldObj = atomicRef.getAndSet(newObj);
-        oldObj.followedBy[newObj.val] = true;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BasicHSAILTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,387 +0,0 @@
-/*
- * Copyright (c) 2011, 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.compiler.hsail.test;
-
-import static com.oracle.graal.debug.DelegatingDebugConfig.Feature.*;
-
-import org.junit.*;
-
-import com.oracle.graal.api.meta.*;
-import com.oracle.graal.compiler.target.*;
-import com.oracle.graal.compiler.test.*;
-import com.oracle.graal.debug.*;
-import com.oracle.graal.debug.Debug.Scope;
-import com.oracle.graal.gpu.*;
-import com.oracle.graal.hotspot.hsail.*;
-import com.oracle.graal.hsail.*;
-
-/**
- * Test class for small Java methods compiled to HSAIL kernels.
- */
-public class BasicHSAILTest extends GraalCompilerTest {
-
-    public BasicHSAILTest() {
-        super(HSAIL.class);
-    }
-
-    public void testAdd() {
-        test("testAddSnippet");
-    }
-
-    public static int testAddSnippet(int a) {
-        return a * a;
-    }
-
-    public void testArrayConstantIndex() {
-        test("testArrayReturnFirstElement");
-    }
-
-    public void testArrayVariableIndex() {
-        test("testArrayReturnIthElement");
-    }
-
-    public void testArrayMultiplyConstant() {
-        test("testArrayMultiplyZero");
-    }
-
-    public void testArrayMultiplyVar() {
-        test("testArrayMultiplyGid");
-    }
-
-    public void testArrayMisc() {
-        test("testArrayLocalVariable");
-    }
-
-    public void testArrayLoopVar() {
-        test("testArrayMultiplyGidLoop");
-    }
-
-    void setupPalette(int[] in) {
-        for (int i = 0; i < in.length; i++) {
-            in[i] = i;
-        }
-    }
-
-    public void testNBody() {
-        test("nBodySpill");
-    }
-
-    public void testArrayMandel() {
-        final int width = 768;
-        final int height = width;
-        int loopiterations = 1;
-        int counter = 0;
-        final int range = width * height;
-        int[] rgb = new int[range];
-        int[] palette = new int[range];
-        setupPalette(palette);
-        while (counter < loopiterations) {
-            for (int gid = 0; gid < range; gid++) {
-                testMandelSimple(rgb, palette, -1.0f, 0.0f, 3f, gid);
-            }
-            counter++;
-        }
-        test("testMandelSimple");
-    }
-
-    public void testDanglingElse() {
-        test("danglingElse");
-    }
-
-    public void testIntSquaresTernary() {
-        test("intSquaresTernary");
-    }
-
-    public void testDanglingElse2() {
-        test("danglingElse2");
-    }
-
-    public void testDanglingElse3() {
-        test("danglingElse3");
-    }
-
-    public void testSimpleIf() {
-        test("simpleIf");
-    }
-
-    public void testParams11() {
-        test("testParams1");
-    }
-
-    public void testParams21() {
-        test("testParams2");
-    }
-
-    public void testParams31() {
-        test("testParams3");
-    }
-
-    public void testAssignment1() {
-        test("testAssignment");
-    }
-
-    public void testArithmetic1() {
-        test("testArithmetic");
-    }
-
-    public void testSimpleWhile1() {
-        test("testSimpleWhile");
-    }
-
-    public void testComplexWhile1() {
-        test("testComplexWhile");
-    }
-
-    public void testSquaresThree() {
-        test("testMulThreeArrays");
-    }
-
-    @Test
-    public void testCondMoves() {
-        test("testMinI");
-        test("testMinF");
-    }
-
-    public int testMinI(int a, int b) {
-        return (a < b ? 1 : 2);
-    }
-
-    public float testMinF(int a, int b) {
-        return (a < b ? 1.0f : 2.0f);
-    }
-
-    public static void testMulThreeArrays(int[] out, int[] ina, int[] inb, int gid) {
-        out[gid] = ina[gid] * inb[gid];
-    }
-
-    public static int testArrayMultiplyZero(int[] array1, int[] array2) {
-        return array1[0] = array2[0] * array2[0];
-    }
-
-    public static int testArrayMultiplyGid(int[] array1, int[] array2, int gid) {
-        return array1[gid] = array2[gid] * array2[gid];
-    }
-
-    public static float testParams3(float c, float d, float e) {
-        return c + d + e;
-    }
-
-    public static int testAssignment() {
-        final int width = 768;
-        final int height = 768;
-        final int maxIterations = 64;
-        return width * height * maxIterations;
-    }
-
-    public static int testSimpleWhile(int i) {
-        int count = 0;
-        int j = 0;
-        final int maxIterations = 64;
-        while (count < maxIterations) {
-            j += count * i;
-            count++;
-        }
-        return j;
-    }
-
-    public static void testComplexWhile() {
-        float lx = 1;
-        float ly = 2;
-        float zx = lx;
-        float zy = ly;
-        float newzx = 0f;
-        final int maxIterations = 64;
-        int count = 0;
-        while (count < maxIterations && zx * zx + zy * zy < 8) {
-            newzx = zx * zx - zy * zy + lx;
-            zy = 2 * zx * zy + ly;
-            zx = newzx;
-            count++;
-        }
-    }
-
-    public static void testMandel(int[] rgb, int[] pallette, float xoffset, float yoffset, float scale, int gid) {
-        final int width = 768;
-        final int height = 768;
-        final int maxIterations = 64;
-        float lx = (((gid % width * scale) - ((scale / 2) * width)) / width) + xoffset;
-        float ly = (((gid / width * scale) - ((scale / 2) * height)) / height) + yoffset;
-        int count = 0;
-        float zx = lx;
-        float zy = ly;
-        float newzx = 0f;
-        /**
-         * Iterate until the algorithm converges or until maxIterations are reached.
-         */
-        while (count < maxIterations && zx * zx + zy * zy < 8) {
-            newzx = zx * zx - zy * zy + lx;
-            zy = 2 * zx * zy + ly;
-            zx = newzx;
-            count++;
-        }
-        rgb[gid] = pallette[count];
-    }
-
-    public static void testMandelSimple(int[] rgb, int[] pallette, float xoffset, float yoffset, float scale, int gid) {
-        final int width = 768;
-        final int height = width;
-        final int maxIterations = 64;
-        float lx = (((gid % width * scale) - ((scale / 2) * width)) / width) + xoffset;
-        float ly = (((gid / width * scale) - ((scale / 2) * height)) / height) + yoffset;
-        int count = 0;
-        float zx = lx;
-        float zy = ly;
-        float newzx = 0f;
-        /**
-         * Iterate until the algorithm converges or until maxIterations are reached.
-         */
-        while (count < maxIterations && zx * zx + zy * zy < 8) {
-            newzx = zx * zx - zy * zy + lx;
-            zy = 2 * zx * zy + ly;
-            zx = newzx;
-            count++;
-        }
-        rgb[gid] = pallette[count];
-    }
-
-    public static void testMandel2(int[] rgb, int[] pallette, int xoffseti, int yoffseti, int scalei, int gid) {
-        final int width = 768;
-        final int height = 768;
-        final int maxIterations = 64;
-        float xoffset = xoffseti;
-        float yoffset = yoffseti;
-        float scale = scalei;
-        float lx = (((gid % width * scale) - ((scale / 2) * width)) / width) + xoffset;
-        float ly = (((gid / width * scale) - ((scale / 2) * height)) / height) + yoffset;
-        int count = 0;
-        float zx = lx;
-        float zy = ly;
-        float newzx = 0f;
-        /**
-         * Iterate until the algorithm converges or until maxIterations are reached.
-         */
-        while (count < maxIterations && zx * zx + zy * zy < 8) {
-            newzx = zx * zx - zy * zy + lx;
-            zy = 2 * zx * zy + ly;
-            zx = newzx;
-            count++;
-        }
-        rgb[gid] = pallette[count];
-    }
-
-    public static int testArrayLocalVariable(int gid, int[] array) {
-        int foo = 198;
-        return array[gid + foo];
-    }
-
-    public static int testArrayReturnFirstElement(int[] array) {
-        return array[0];
-    }
-
-    public static int testArrayReturnIthElement(int i, int[] array) {
-        return array[i];
-    }
-
-    public static void simpleIf(int[] out, int[] in, int gid) {
-        if (gid > 9) {
-            out[gid] = in[gid] * in[gid];
-        }
-    }
-
-    public static int danglingElse(int a) {
-        return (a > 5) ? (a + 7) : (a - 3);
-    }
-
-    public static int danglingElse2(int a, int b) {
-        if (a > 5) {
-            return (a + 7 * (b - 4 + a));
-        } else {
-            return (a - 3 + b * 3 * a + 5);
-        }
-    }
-
-    public static int danglingElse3(int a, int b) {
-        int val;
-        if (a > 5) {
-            val = (a + 7 * (b - 4 + a));
-        } else {
-            val = (a - 3 + b * 3 * a + 5);
-        }
-        return val + a;
-    }
-
-    public static void intSquaresTernary(int[] out, int[] in, int gid) {
-        int val = in[gid] * in[gid];
-        val = (val % 2 == 1 ? val + 1 : val);
-        out[gid] = val;
-    }
-
-    @Override
-    protected HSAILHotSpotBackend getBackend() {
-        Backend backend = super.getBackend();
-        Assume.assumeTrue("No HSAIL backend, skipping test!", backend instanceof HSAILHotSpotBackend);
-        return (HSAILHotSpotBackend) backend;
-    }
-
-    private void test(final String snippet) {
-        try (DebugConfigScope dcs = Debug.setConfig(new DelegatingDebugConfig().disable(INTERCEPT))) {
-            try (Scope s = Debug.scope("HSAILCodeGen")) {
-                ResolvedJavaMethod method = getResolvedJavaMethod(snippet);
-                ExternalCompilationResult hsailCode = getBackend().compileKernel(method, false);
-                Debug.log("HSAIL code generated for %s:%n%s", snippet, hsailCode.getCodeString());
-            } catch (Throwable e) {
-                throw Debug.handle(e);
-            }
-        }
-    }
-
-    public static void nBodySpill(float[] inxyz, float[] outxyz, float[] invxyz, float[] outvxyz, int gid) {
-        final int bodies = 8;
-        final float delT = .005f;
-        final float espSqr = 1.0f;
-        final float mass = 5f;
-        final int count = bodies * 3;
-        final int globalId = gid * 3;
-        float accx = 0.f;
-        float accy = 0.f;
-        float accz = 0.f;
-        for (int i = 0; i < count; i += 3) {
-            final float dx = inxyz[i + 0] - inxyz[globalId + 0];
-            final float dy = inxyz[i + 1] - inxyz[globalId + 1];
-            final float dz = inxyz[i + 2] - inxyz[globalId + 2];
-            final float invDist = (float) (1.0 / (Math.sqrt((dx * dx) + (dy * dy) + (dz * dz) + espSqr)));
-            accx += mass * invDist * invDist * invDist * dx;
-            accy += mass * invDist * invDist * invDist * dy;
-            accz += mass * invDist * invDist * invDist * dz;
-        }
-        accx *= delT;
-        accy *= delT;
-        accz *= delT;
-        outxyz[globalId + 0] = inxyz[globalId + 0] + (invxyz[globalId + 0] * delT) + (accx * .5f * delT);
-        outxyz[globalId + 1] = inxyz[globalId + 1] + (invxyz[globalId + 1] * delT) + (accy * .5f * delT);
-        outxyz[globalId + 2] = inxyz[globalId + 2] + (invxyz[globalId + 2] * delT) + (accz * .5f * delT);
-        outvxyz[globalId + 0] = invxyz[globalId + 0] + accx;
-        outvxyz[globalId + 1] = invxyz[globalId + 1] + accy;
-        outvxyz[globalId + 2] = invxyz[globalId + 2] + accz;
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestFF.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two boolean values which are both false.
- */
-public class BooleanBitwiseAndTestFF extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = false;
-            in2[i] = false;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestFT.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two booleans. First input is false and second input is true.
- */
-public class BooleanBitwiseAndTestFT extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = false;
-            in2[i] = true;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestTF.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two booleans. First input is true and second is false.
- */
-public class BooleanBitwiseAndTestTF extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = true;
-            in2[i] = false;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseAndTestTT.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two booleans. Both inputs are true.
- */
-public class BooleanBitwiseAndTestTT extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = true;
-            in2[i] = true;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestFF.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two booleans. Both inputs are false.
- */
-public class BooleanBitwiseOrTestFF extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] | inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = false;
-            in2[i] = false;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestFT.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two booleans. First input is false. Second input is true.
- */
-public class BooleanBitwiseOrTestFT extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] | inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = false;
-            in2[i] = true;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestTF.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two booleans. First input is true. Second input is false.
- */
-public class BooleanBitwiseOrTestTF extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] | inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = true;
-            in2[i] = false;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseOrTestTT.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two booleans. Both inputs are true.
- */
-public class BooleanBitwiseOrTestTT extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] | inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = true;
-            in2[i] = true;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestFF.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise XOR of two booleans. Both inputs are false.
- */
-public class BooleanBitwiseXorTestFF extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] ^ inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = false;
-            in2[i] = false;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestFT.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise XOR of two booleans. First input is false. Second input is true.
- */
-public class BooleanBitwiseXorTestFT extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] ^ inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = false;
-            in2[i] = true;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestTF.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise XOR of two booelans. First input is true. Second input is false.
- */
-public class BooleanBitwiseXorTestTF extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] ^ inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = true;
-            in2[i] = false;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BooleanBitwiseXorTestTT.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise XOR of two booleans. Both inputs are true.
- */
-public class BooleanBitwiseXorTestTT extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected boolean[] outArray = new boolean[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(boolean[] out, boolean[] ina, boolean[] inb, int gid) {
-        out[gid] = (ina[gid] ^ inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(boolean[] in, boolean[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = true;
-            in2[i] = true;
-            outArray[i] = false;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        boolean[] inArray = new boolean[num];
-        boolean[] inArray2 = new boolean[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchBase.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,70 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Base Class for tests that deopt but then catch the exception in the run routine itself.
- */
-public abstract class BoundsCatchBase extends GraalKernelTester {
-
-    abstract int getGlobalSize();
-
-    final int num = getGlobalSize();
-    @Result int[] outArray = new int[num];
-
-    void setupArrays() {
-        for (int i = 0; i < num; i++) {
-            outArray[i] = -i;
-        }
-    }
-
-    // Note: could not push the whole run routine here because
-    // problems with indirect call to getDeoptGid
-    int getOutval(int gid) {
-        int adjustment = 0;
-        int tmp = gid + 10;
-        while (tmp > gid) {
-            adjustment += tmp;
-            tmp--;
-        }
-        int outval = (outArray[gid] * -1) + adjustment;
-        return outval;
-    }
-
-    @Override
-    protected boolean supportsRequiredCapabilities() {
-        return canDeoptimize();
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-
-        // we should not get an exception escaping from the kernel
-        dispatchMethodKernel(num);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany16384Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 16384, deopt on many gids but then catch the exception in the run routine itself.
- */
-public class BoundsCatchMany16384Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 16384;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany20000Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 20000, deopt on many gids but then catch the exception in the run routine itself.
- */
-public class BoundsCatchMany20000Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 20000;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany5000Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 5000, deopt on many gids but then catch the exception in the run routine itself.
- */
-public class BoundsCatchMany5000Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 5000;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany8192Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 8192, deopt on many gids but then catch the exception in the run routine itself.
- */
-public class BoundsCatchMany8192Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 8192;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany987654HighTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,61 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 987654, deopt on many gids but then catch the exception in the run routine itself
- * deopt ids are at the high end.
- */
-public class BoundsCatchMany987654HighTest extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 987654;
-    }
-
-    boolean isMyDeoptGid(int gid) {
-        return (gid > getGlobalSize() - 4096 && gid % 512 == 1);
-    }
-
-    // copied run routine here because otherwise polymorphic calls to isDeoptGid
-    @Override
-    public void run(int gid) {
-        int outval = getOutval(gid);
-        try {
-            int index = (isMyDeoptGid(gid) ? num + 1 : gid);
-            outArray[index] = outval;
-        } catch (ArrayIndexOutOfBoundsException e) {
-            // set up so we can detect if we go thru here twice
-            outArray[gid] += outval;
-            // note: cannot record the exceptiongid here for many deopts in parallel
-        }
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany987654Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 987654, deopt on many gids but then catch the exception in the run routine itself.
- */
-public class BoundsCatchMany987654Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 987654;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMany99999Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 99999, deopt on many gids but then catch the exception in the run routine itself.
- */
-public class BoundsCatchMany99999Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 99999;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchManyBase.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-/**
- * Base Class for tests that deopt on multiple gids gid but then catches the exception in the run
- * routine itself.
- */
-public abstract class BoundsCatchManyBase extends BoundsCatchBase {
-
-    boolean isDeoptGid(int gid) {
-        return (gid < 4096 && gid % 512 == 1);
-    }
-
-    public void run(int gid) {
-        int outval = getOutval(gid);
-        try {
-            int index = (isDeoptGid(gid) ? num + 1 : gid);
-            outArray[index] = outval;
-        } catch (ArrayIndexOutOfBoundsException e) {
-            // set up so we can detect if we go thru here twice
-            outArray[gid] += outval;
-            // note: cannot record the exceptiongid here for many deopts in parallel
-        }
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMost1000Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,61 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 1000, deopt on almost all gids but then catch the exception in the run routine
- * itself.
- */
-public class BoundsCatchMost1000Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 1000;
-    }
-
-    boolean isMyDeoptGid(int gid) {
-        return (gid % 100 != 1);
-    }
-
-    // copied run routine here because otherwise polymorphic calls to isDeoptGid
-    @Override
-    public void run(int gid) {
-        int outval = getOutval(gid);
-        try {
-            int index = (isMyDeoptGid(gid) ? num + 1 : gid);
-            outArray[index] = outval;
-        } catch (ArrayIndexOutOfBoundsException e) {
-            // set up so we can detect if we go thru here twice
-            outArray[gid] += outval;
-            // note: cannot record the exceptiongid here for many deopts in parallel
-        }
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMost20000StressGCTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,76 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * A version which is likely to get a GC while running the never_rans, and so is good for oops_do
- * testing.
- */
-public class BoundsCatchMost20000StressGCTest extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 20000;
-    }
-
-    boolean isMyDeoptGid(int gid) {
-        return (gid > 100 && gid % 100 != 1);
-    }
-
-    int[] dummyArray;
-
-    // copied run routine here because otherwise polymorphic calls to isDeoptGid
-    @Override
-    public void run(int gid) {
-        int outval = getOutval(gid);
-        try {
-            int index = (isMyDeoptGid(gid) ? num + 1 : gid);
-            outArray[index] = outval;
-        } catch (ArrayIndexOutOfBoundsException e) {
-            // set up so we can detect if we go thru here twice
-            outArray[gid] += outval;
-            // note: cannot record the exceptiongid here for many deopts in parallel
-
-            // allocate something so GCs happen more often
-            dummyArray = new int[1000];
-        }
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays();
-
-        for (int i = 0; i < 10; i++) {
-            // we should not get an exception escaping from the kernel
-            dispatchMethodKernel(num);
-        }
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchMost20000Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,61 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 20000, deopt on almost all gids but then catch the exception in the run routine
- * itself.
- */
-public class BoundsCatchMost20000Test extends BoundsCatchManyBase {
-
-    @Override
-    int getGlobalSize() {
-        return 20000;
-    }
-
-    boolean isMyDeoptGid(int gid) {
-        return (gid % 100 != 1);
-    }
-
-    // copied run routine here because otherwise polymorphic calls to isDeoptGid
-    @Override
-    public void run(int gid) {
-        int outval = getOutval(gid);
-        try {
-            int index = (isMyDeoptGid(gid) ? num + 1 : gid);
-            outArray[index] = outval;
-        } catch (ArrayIndexOutOfBoundsException e) {
-            // set up so we can detect if we go thru here twice
-            outArray[gid] += outval;
-            // note: cannot record the exceptiongid here for many deopts in parallel
-        }
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle16384Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 16384, deopt on a single gid but then catch the exception in the run routine
- * itself.
- */
-public class BoundsCatchSingle16384Test extends BoundsCatchSingleBase {
-
-    @Override
-    int getGlobalSize() {
-        return 16384;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle20000Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 20000, deopt on a single gid but then catch the exception in the run routine
- * itself.
- */
-public class BoundsCatchSingle20000Test extends BoundsCatchSingleBase {
-
-    @Override
-    int getGlobalSize() {
-        return 20000;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle5000Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 5000, deopt on a single gid but then catch the exception in the run routine
- * itself.
- */
-public class BoundsCatchSingle5000Test extends BoundsCatchSingleBase {
-
-    @Override
-    int getGlobalSize() {
-        return 5000;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingle8192Test.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * For globalsize 8192, deopt on a single gid but then catch the exception in the run routine
- * itself.
- */
-public class BoundsCatchSingle8192Test extends BoundsCatchSingleBase {
-
-    @Override
-    int getGlobalSize() {
-        return 8192;
-    }
-
-    @Test
-    public void test() {
-        testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCatchSingleBase.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,54 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-/**
- * Base Class for tests that deopt on a single gid but then catch the exception in the run routine
- * itself.
- */
-public abstract class BoundsCatchSingleBase extends BoundsCatchBase {
-
-    int getDeoptGid() {
-        return 512;
-    }
-
-    boolean isDeoptGid(int gid) {
-        return (gid == getDeoptGid());
-    }
-
-    @Result public int exceptionGid;
-
-    public void run(int gid) {
-        int outval = getOutval(gid);
-        try {
-            int index = (isDeoptGid(gid) ? num + 1 : gid);
-            outArray[index] = outval;
-        } catch (ArrayIndexOutOfBoundsException e) {
-            // set up so we can detect if we go thru here twice
-            outArray[gid] -= outval;
-            exceptionGid = gid;
-        }
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckDoubleNonZeroBciTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,76 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * This test deliberately causes an ArrayIndexOutOfBoundsException to test throwing the exception
- * back to the java code.
- */
-public class BoundsCheckDoubleNonZeroBciTest extends SingleExceptionTestBase {
-
-    static final int num = 20;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    double[] outArray = new double[num];
-
-    void setupArrays(double[] in1, double[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -i;
-        }
-    }
-
-    static double dummyDouble = 10;
-
-    public static void run(double[] out, double[] ina, double[] inb, int gid) {
-        // This will fail when gid+1==num
-        double adjustment = 0;
-        double tmp = dummyDouble;
-        while (tmp-- >= 0) {
-            adjustment += tmp;
-        }
-        out[gid + 1] = ina[gid] + inb[gid] + adjustment;
-    }
-
-    @Override
-    public void runTest() {
-        double[] inArray1 = new double[num];
-        double[] inArray2 = new double[num];
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num, outArray, inArray1, inArray2);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckFailsInMiddleTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,70 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * This test deliberately causes an ArrayIndexOutOfBoundsException to test throwing the exception
- * back to the java code, in the middle of the array.
- */
-public class BoundsCheckFailsInMiddleTest extends SingleExceptionTestBase {
-    static final int num = 128; // * 256;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    int[] outArray = new int[num];
-    static final int abortingGid = (new java.util.Random()).nextInt(num / 4);
-
-    void setupArrays(int[] in1, int[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -99;
-        }
-    }
-
-    public static void run(int[] out, int[] ina, int[] inb, int gid) {
-        // Throw in the middle of doing the work
-        out[gid == abortingGid ? (gid + num) : gid] = ina[gid] + inb[gid];
-    }
-
-    @Override
-    public void runTest() {
-        int[] inArray1 = new int[num];
-        int[] inArray2 = new int[num];
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num, outArray, inArray1, inArray2);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckFloatNonZeroBciTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,76 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * This test deliberately causes an ArrayIndexOutOfBoundsException to test throwing the exception
- * back to the java code.
- */
-public class BoundsCheckFloatNonZeroBciTest extends SingleExceptionTestBase {
-
-    static final int num = 20;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    float[] outArray = new float[num];
-
-    void setupArrays(float[] in1, float[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -i;
-        }
-    }
-
-    static float dummyFloat = 10;
-
-    public static void run(float[] out, float[] ina, float[] inb, int gid) {
-        // This will fail when gid+1==num
-        float adjustment = 0;
-        float tmp = dummyFloat;
-        while (tmp-- >= 0) {
-            adjustment += tmp;
-        }
-        out[gid + 1] = ina[gid] + inb[gid] + adjustment;
-    }
-
-    @Override
-    public void runTest() {
-        float[] inArray1 = new float[num];
-        float[] inArray2 = new float[num];
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num, outArray, inArray1, inArray2);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckInlineTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,75 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * 
- * @author ecaspole
- */
-public class BoundsCheckInlineTest extends SingleExceptionTestBase {
-
-    static final int num = 20;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    int[] outArray = new int[num];
-
-    void setupArrays(int[] in1, int[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -i;
-        }
-    }
-
-    static volatile int dummy;
-
-    static void writesum(int[] out, int gid, int val) {
-        out[gid + 1] = val;
-    }
-
-    public static void run(int[] out, int[] ina, int[] inb, int gid) {
-        // This will fail when gid+1==num
-        writesum(out, gid, ina[gid] + inb[gid]);
-    }
-
-    @Override
-    public void runTest() {
-        int[] inArray1 = new int[num];
-        int[] inArray2 = new int[num];
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num, outArray, inArray1, inArray2);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckLongNonZeroBciTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,76 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * This test deliberately causes an ArrayIndexOutOfBoundsException to test throwing the exception
- * back to the java code.
- */
-public class BoundsCheckLongNonZeroBciTest extends SingleExceptionTestBase {
-
-    static final int num = 20;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    long[] outArray = new long[num];
-
-    void setupArrays(long[] in1, long[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -i;
-        }
-    }
-
-    static long dummyLong = 10;
-
-    public static void run(long[] out, long[] ina, long[] inb, int gid) {
-        // This will fail when gid+1==num
-        long adjustment = 0x1234567890abcdefL;
-        long tmp = dummyLong;
-        while (tmp-- >= 0) {
-            adjustment += tmp;
-        }
-        out[gid + 1] = ina[gid] + inb[gid] + adjustment;
-    }
-
-    @Override
-    public void runTest() {
-        long[] inArray1 = new long[num];
-        long[] inArray2 = new long[num];
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num, outArray, inArray1, inArray2);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckNonZeroBciInstanceTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,76 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * This test deliberately causes an ArrayIndexOutOfBoundsException to test throwing the exception
- * back to the java code.
- */
-public class BoundsCheckNonZeroBciInstanceTest extends SingleExceptionTestBase {
-
-    static final int num = 20;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    int[] outArray = new int[num];
-    int[] inArray1 = new int[num];
-    int[] inArray2 = new int[num];
-
-    void setupArrays(int[] in1, int[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -i;
-        }
-    }
-
-    int dummyInt = 10;
-
-    public void run(int gid) {
-        // This will fail when gid+1==num
-        int adjustment = 0;
-        int tmp = dummyInt;
-        while (tmp-- >= 0) {
-            adjustment += tmp;
-        }
-        outArray[gid + 1] = inArray1[gid] + inArray2[gid] + adjustment;
-    }
-
-    @Override
-    public void runTest() {
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckNonZeroBciTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,76 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * This test deliberately causes an ArrayIndexOutOfBoundsException to test throwing the exception
- * back to the java code.
- */
-public class BoundsCheckNonZeroBciTest extends SingleExceptionTestBase {
-
-    static final int num = 20;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    int[] outArray = new int[num];
-
-    void setupArrays(int[] in1, int[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -i;
-        }
-    }
-
-    static int dummyInt = 10;
-
-    public static void run(int[] out, int[] ina, int[] inb, int gid) {
-        // This will fail when gid+1==num
-        int adjustment = 0;
-        int tmp = dummyInt;
-        while (tmp-- >= 0) {
-            adjustment += tmp;
-        }
-        out[gid + 1] = ina[gid] + inb[gid] + adjustment;
-    }
-
-    @Override
-    public void runTest() {
-        int[] inArray1 = new int[num];
-        int[] inArray2 = new int[num];
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num, outArray, inArray1, inArray2);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/BoundsCheckTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-/**
- * This test deliberately causes an ArrayIndexOutOfBoundsException to test throwing the exception
- * back to the java code.
- */
-public class BoundsCheckTest extends SingleExceptionTestBase {
-
-    static final int num = 20;
-    // note: outArray not marked as @Result because we can't predict
-    // which workitems will get done in parallel execution
-    int[] outArray = new int[num];
-
-    void setupArrays(int[] in1, int[] in2) {
-        for (int i = 0; i < num; i++) {
-            in1[i] = i;
-            in2[i] = i + 1;
-            outArray[i] = -i;
-        }
-    }
-
-    public static void run(int[] out, int[] ina, int[] inb, int gid) {
-        // This will fail when gid+1==num
-        out[gid + 1] = ina[gid] + inb[gid];
-    }
-
-    @Override
-    public void runTest() {
-        int[] inArray1 = new int[num];
-        int[] inArray2 = new int[num];
-        setupArrays(inArray1, inArray2);
-
-        try {
-            dispatchMethodKernel(num, outArray, inArray1, inArray2);
-        } catch (Exception e) {
-            recordException(e);
-        }
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseAndCastTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two bytes and casts the result to a byte.
- */
-public class ByteBitwiseAndCastTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected byte[] outArray1 = new byte[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(byte[] out1, byte[] ina, byte[] inb, int gid) {
-        out1[gid] = (byte) (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(byte[] in, byte[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (byte) (i + i);
-            in2[i] = (byte) (i * i);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        byte[] inArray = new byte[num];
-        byte[] inArray2 = new byte[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseAndTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two bytes.
- */
-public class ByteBitwiseAndTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected int[] outArray1 = new int[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(int[] out1, byte[] ina, byte[] inb, int gid) {
-        out1[gid] = (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(byte[] in, byte[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (byte) (i + i);
-            in2[i] = (byte) (i * i);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        byte[] inArray = new byte[num];
-        byte[] inArray2 = new byte[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseOrCastTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two bytes and casts the result to a byte.
- */
-public class ByteBitwiseOrCastTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected byte[] outArray1 = new byte[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(byte[] out1, byte[] ina, byte[] inb, int gid) {
-        out1[gid] = (byte) (ina[gid] | inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(byte[] in, byte[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (byte) (i * 2);
-            in2[i] = (byte) (i);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        byte[] inArray = new byte[num];
-        byte[] inArray2 = new byte[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseOrTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two bytes.
- */
-public class ByteBitwiseOrTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected int[] outArray1 = new int[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(int[] out1, byte[] ina, byte[] inb, int gid) {
-        out1[gid] = (ina[gid] | inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(byte[] in, byte[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (byte) (i * 2);
-            in2[i] = (byte) (i);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        byte[] inArray = new byte[num];
-        byte[] inArray2 = new byte[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseXorCastTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise XOR of two bytes and casts the result to a byte.
- */
-public class ByteBitwiseXorCastTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected byte[] outArray1 = new byte[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(byte[] out1, byte[] ina, byte[] inb, int gid) {
-        out1[gid] = (byte) (ina[gid] ^ inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(byte[] in, byte[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (byte) (i);
-            in2[i] = (byte) (i * i);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        byte[] inArray = new byte[num];
-        byte[] inArray2 = new byte[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/ByteBitwiseXorTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise XOR of two bytes.
- */
-public class ByteBitwiseXorTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected int[] outArray1 = new int[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(int[] out1, byte[] ina, byte[] inb, int gid) {
-        out1[gid] = (ina[gid] ^ inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(byte[] in, byte[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (byte) (i);
-            in2[i] = (byte) (i * i);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        byte[] inArray = new byte[num];
-        byte[] inArray2 = new byte[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CallTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,63 +0,0 @@
-/*
- * Copyright (c) 2009, 2012, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * Tests direct method calls.
- */
-public class CallTest extends GraalKernelTester {
-
-    static final int width = 768;
-    static final int height = width;
-    private int iterations = 100;
-    static final int range = width * height;
-    @Result public float[] inArray = new float[range];
-
-    public static int foo(int gid, int i) {
-        if (gid < 25) {
-            return gid * i;
-        } else {
-            return gid - i;
-        }
-    }
-
-    public void run(float[] inArray1, int gid) {
-        for (int i = 0; i < iterations; i++) {
-            inArray1[gid] = foo(gid, i);
-        }
-    }
-
-    @Override
-    public void runTest() {
-        dispatchMethodKernel(range, inArray);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseAndCastTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two chars and casts result to a char.
- */
-public class CharBitwiseAndCastTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected char[] outArray1 = new char[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(char[] out1, char[] ina, char[] inb, int gid) {
-        out1[gid] = (char) (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(char[] in, char[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (char) (i + 65);
-            in2[i] = (char) (i + 97);
-            outArray1[i] = (char) 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        char[] inArray = new char[num];
-        char[] inArray2 = new char[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseAndTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise AND of two chars.
- */
-public class CharBitwiseAndTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected int[] outArray1 = new int[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(int[] out1, char[] ina, char[] inb, int gid) {
-        out1[gid] = (ina[gid] & inb[gid]);
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(char[] in, char[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (char) (i + 65);
-            in2[i] = (char) (i + 97);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        char[] inArray = new char[num];
-        char[] inArray2 = new char[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseOrCastTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two chars and casts the result to a char.
- */
-public class CharBitwiseOrCastTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected char[] outArray1 = new char[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(char[] out1, char[] ina, char[] inb, int gid) {
-        out1[gid] = (char) (ina[gid] | inb[gid]);
-
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(char[] in, char[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (char) (i + 65);
-            in2[i] = (char) (i + 97);
-            outArray1[i] = (char) 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        char[] inArray = new char[num];
-        char[] inArray2 = new char[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseOrTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise OR of two chars.
- */
-public class CharBitwiseOrTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected int[] outArray1 = new int[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     * 
-     */
-    public static void run(int[] out1, char[] ina, char[] inb, int gid) {
-        out1[gid] = (ina[gid] | inb[gid]);
-
-    }
-
-    @Test
-    public void test() {
-        super.testGeneratedHsail();
-    }
-
-    void setupArrays(char[] in, char[] in2) {
-        for (int i = 0; i < num; i++) {
-            in[i] = (char) (i + 65);
-            in2[i] = (char) (i + 97);
-            outArray1[i] = 0;
-        }
-    }
-
-    @Override
-    public void runTest() {
-        char[] inArray = new char[num];
-        char[] inArray2 = new char[num];
-        setupArrays(inArray, inArray2);
-
-        dispatchMethodKernel(num, outArray1, inArray, inArray2);
-    }
-
-}
--- a/graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/CharBitwiseXorCastTest.java	Thu Jan 22 23:16:17 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2009, 2013, 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.compiler.hsail.test;
-
-import org.junit.*;
-
-import com.oracle.graal.compiler.hsail.test.infra.*;
-
-/**
- * 
- * Tests bitwise XOR of two chars and casts the result to a char.
- */
-public class CharBitwiseXorCastTest extends GraalKernelTester {
-
-    static final int num = 20;
-    @Result protected char[] outArray1 = new char[num];
-
-    /**
-     * The static "kernel" method we will be testing. By convention the gid is the last parameter.
-     *