changeset 11291:4a6b03a16808

Fix PTX test to prevent crash; trivial code cleanup
author bharadwaj
date Mon, 12 Aug 2013 13:12:14 -0400
parents 686d6d99352c
children 5040ec3ff3aa
files graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/IntegerPTXTest.java src/gpu/ptx/vm/gpu_ptx.hpp src/share/vm/graal/graalCompilerToGPU.cpp
diffstat 3 files changed, 4 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/IntegerPTXTest.java	Mon Aug 12 15:59:58 2013 +0200
+++ b/graal/com.oracle.graal.compiler.ptx.test/src/com/oracle/graal/compiler/ptx/test/IntegerPTXTest.java	Mon Aug 12 13:12:14 2013 -0400
@@ -147,7 +147,7 @@
     @Test
     public void testIntConversion() {
         invoke(compile("testI2L"), 8);
-        invoke(compile("testL2I"), 12);
+        invoke(compile("testL2I"), 12L);
         invoke(compile("testI2C"), 65);
         invoke(compile("testI2B"), 9);
         invoke(compile("testI2F"), 17);
--- a/src/gpu/ptx/vm/gpu_ptx.hpp	Mon Aug 12 15:59:58 2013 +0200
+++ b/src/gpu/ptx/vm/gpu_ptx.hpp	Mon Aug 12 13:12:14 2013 -0400
@@ -44,7 +44,7 @@
  * End of array terminator for the extra parameter to
  * ::cuLaunchKernel
  */
-#define GRAAL_CU_LAUNCH_PARAM_END            ((void*)0x00)
+#define GRAAL_CU_LAUNCH_PARAM_END            ((void *) 0x00)
 
 /**
  * Indicator that the next value in the  extra parameter to
@@ -55,7 +55,7 @@
  *  extra array, then ::GRAAL_CU_LAUNCH_PARAM_BUFFER_POINTER will have no
  * effect.
  */
-#define GRAAL_CU_LAUNCH_PARAM_BUFFER_POINTER ((void*)0x01)
+#define GRAAL_CU_LAUNCH_PARAM_BUFFER_POINTER ((void *) 0x01)
 
 /**
  * Indicator that the next value in the  extra parameter to
@@ -65,7 +65,7 @@
  * in the extra array if the value associated with
  * ::GRAAL_CU_LAUNCH_PARAM_BUFFER_SIZE is not zero.
  */
-#define GRAAL_CU_LAUNCH_PARAM_BUFFER_SIZE    ((void*)0x02)
+#define GRAAL_CU_LAUNCH_PARAM_BUFFER_SIZE    ((void *) 0x02)
 
 class Ptx {
   friend class gpu;
--- a/src/share/vm/graal/graalCompilerToGPU.cpp	Mon Aug 12 15:59:58 2013 +0200
+++ b/src/share/vm/graal/graalCompilerToGPU.cpp	Mon Aug 12 13:12:14 2013 -0400
@@ -90,9 +90,6 @@
   // start value is the kernel
   jlong startValue = HotSpotInstalledCode::start(hotspotInstalledCode);
 
-  // JavaCalls::call(&result, mh, &jca, CHECK_NULL);
-  // tty->print_cr("executeExternalMethodVarargs: start: %x", (address)startValue);
-
   if (!gpu::execute_kernel((address)startValue, &jca)) {
     return NULL;
   }