diff src/gpu/ptx/vm/gpu_ptx.cpp @ 11821:d8659ad83fcc

PTX single-threaded array store, Warp annotation
author Morris Meyer <morris.meyer@oracle.com>
date Sat, 28 Sep 2013 21:06:12 -0400
parents bff2b88444f5
children 365d8f385fb5
line wrap: on
line diff
--- a/src/gpu/ptx/vm/gpu_ptx.cpp	Fri Sep 27 19:51:01 2013 +0200
+++ b/src/gpu/ptx/vm/gpu_ptx.cpp	Sat Sep 28 21:06:12 2013 -0400
@@ -282,7 +282,7 @@
   // Get the result. TODO: Move this code to get_return_oop()
   BasicType return_type = ptxka.get_ret_type();
   switch (return_type) {
-     case T_INT :
+     case T_INT:
        {
          int return_val;
          status = gpu::Ptx::_cuda_cu_memcpy_dtoh(&return_val, ptxka._return_value_ptr, T_INT_BYTE_SIZE);
@@ -293,7 +293,7 @@
          ret.set_jint(return_val);
        }
        break;
-     case T_LONG :
+     case T_LONG:
        {
          long return_val;
          status = gpu::Ptx::_cuda_cu_memcpy_dtoh(&return_val, ptxka._return_value_ptr, T_LONG_BYTE_SIZE);
@@ -304,10 +304,14 @@
          ret.set_jlong(return_val);
        }
        break;
+     case T_VOID:
+       break;
      default:
-       tty->print_cr("[CUDA] TODO *** Unhandled return type");
+       tty->print_cr("[CUDA] TODO *** Unhandled return type: %d", return_type);
   }
 
+  // handle post-invocation object and array arguemtn
+  ptxka.reiterate();
 
   // Free device memory allocated for result
   status = gpu::Ptx::_cuda_cu_memfree(ptxka._return_value_ptr);