graal/com.oracle.graal.compiler.hsail.test/src/com/oracle/graal/compiler/hsail/test/lambda/FloatNextUpTest.java

Print this page




  21  * questions.
  22  */
  23 
  24 package com.oracle.graal.compiler.hsail.test.lambda;
  25 
  26 import org.junit.*;
  27 
  28 /**
  29  * Tests call to {@link Math#nextUp(float)} with float arg.
  30  */
  31 public class FloatNextUpTest extends FloatMathLargeBase {
  32 
  33     @Override
  34     public void runTest() {
  35         setupArrays();
  36         dispatchLambdaKernel(size, (gid) -> {
  37             outArray[gid] = Math.nextUp(inArray[gid]);
  38         });
  39     }
  40 





  41     @Test
  42     public void testUsingLambdaMethod() {
  43         testGeneratedHsailUsingLambdaMethod();
  44     }
  45 }


  21  * questions.
  22  */
  23 
  24 package com.oracle.graal.compiler.hsail.test.lambda;
  25 
  26 import org.junit.*;
  27 
  28 /**
  29  * Tests call to {@link Math#nextUp(float)} with float arg.
  30  */
  31 public class FloatNextUpTest extends FloatMathLargeBase {
  32 
  33     @Override
  34     public void runTest() {
  35         setupArrays();
  36         dispatchLambdaKernel(size, (gid) -> {
  37             outArray[gid] = Math.nextUp(inArray[gid]);
  38         });
  39     }
  40 
  41     @Override
  42     protected boolean supportsRequiredCapabilities() {
  43         return (runningOnSimulator() || runningCQETests());
  44     }
  45 
  46     @Test
  47     public void testUsingLambdaMethod() {
  48         testGeneratedHsailUsingLambdaMethod();
  49     }
  50 }