Documentation ¶
Overview ¶
package cudago implements translation between CUDA C library and Go.
Index ¶
Constants ¶
View Source
const ( RetCUDAErrt = CUDARetType(0) // return type: cudaError_t RetString = CUDARetType(1) // return type: char */const char * )
View Source
const ( CUDAMemcpyHostToHost = CUDAMemcpyKind(0) /**< Host -> Host */ CUDAMemcpyHostToDevice = CUDAMemcpyKind(1) /**< Host -> Device */ CUDAMemcpyDeviceToHost = CUDAMemcpyKind(2) /**< Device -> Host */ CUDAMemcpyDeviceToDevice = CUDAMemcpyKind(3) /**< Device -> Device */ CUDAMemcpyDefault = CUDAMemcpyKind(4) /**< Direction of the traμsfer is inferred from the pointer values. Requires unified virtual addressing */ )
View Source
const ( CudaLimitStackSize = CudaLimit(0x00) /**< GPU thread stack size */ CudaLimitPrintfFifoSize = CudaLimit(0x01) /**< GPU printf FIFO size */ CudaLimitMallocHeapSize = CudaLimit(0x02) /**< GPU malloc heap size */ CudaLimitDevRuntimeSyncDepth = CudaLimit(0x03) /**< GPU device runtime synchronize depth */ CudaLimitDevRuntimePendingLaunchCount = CudaLimit(0x04) /**< GPU device runtime pending launch count */ CudaLimitMaxL2FetchGranularity = CudaLimit(0x05) /**< A value between 0 and 128 that indicates the maximum fetch granularity of L2 (in Bytes). This is a hint */ )
View Source
const ( CudaFuncCachePreferNone = CudaFuncCache(0) /**< Default function cache configuration, no preference */ CudaFuncCachePreferL1 = CudaFuncCache(2) /**< Prefer larger L1 cache and smaller shared memory */ CudaFuncCachePreferEqual = CudaFuncCache(3) /**< Prefer equal size L1 cache and shared memory */ )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CUDAMemcpyKind ¶
type CUDAMemcpyKind int
CUDAMemcpyKind - CUDA library enum type cudaMemcpyKind
type CUDARetType ¶
type CUDARetType int
CUDARetType for CUDA function return value type
Now support cudaError_t, char * and const char *
type CudaCall ¶
type CudaCall interface { // CallCUDAFuncRetInt Call CUDA library function with return type cudaError_t CallCUDAFuncRetInt(funcName string, p ...interface{}) (r int, err error) // CallCUDAFuncRetString Call CUDA library function with return type char */const char * CallCUDAFuncRetString(funcName string, p ...interface{}) (r string, err error) }
CudaCall interface for call CUDA library function
Click to show internal directories.
Click to hide internal directories.