]> gitweb.factorcode.org Git - factor.git/commitdiff
cuda: move init-cuda from cuda.utils
authorJoe Groff <arcata@gmail.com>
Sat, 15 May 2010 22:28:02 +0000 (15:28 -0700)
committerJoe Groff <arcata@gmail.com>
Sat, 15 May 2010 22:28:02 +0000 (15:28 -0700)
extra/cuda/cuda.factor
extra/cuda/utils/utils.factor

index 93de4174e9917383056edb959990526e9c019f1c..a9b67446d8755db89fca819f49a1ba1dd75763d1 100644 (file)
@@ -10,6 +10,9 @@ sequences words cuda.libraries ;
 QUALIFIED-WITH: alien.c-types c
 IN: cuda
 
+: init-cuda ( -- )
+    0 cuInit cuda-error ; inline
+
 TUPLE: function-launcher
 dim-grid dim-block shared-size stream ;
 
index a8e6210970bbecddddbcb63eb72dfc563cce776d..87abdb550849c62c3dc74c7a19a586f8bb8c01e5 100644 (file)
@@ -17,9 +17,6 @@ ERROR: throw-cuda-error n ;
 : cuda-error ( n -- )
     dup CUDA_SUCCESS = [ drop ] [ throw-cuda-error ] if ;
 
-: init-cuda ( -- )
-    0 cuInit cuda-error ; inline
-
 : cuda-version ( -- n )
     int <c-object> [ cuDriverGetVersion cuda-error ] keep *int ;