File tree Expand file tree Collapse file tree 1 file changed +16
-2
lines changed Expand file tree Collapse file tree 1 file changed +16
-2
lines changed Original file line number Diff line number Diff line change @@ -50,16 +50,30 @@ all(A .== 2.0)
50
50
argument to the kernel. See [ dependencies] (@ref dependencies) for a full
51
51
explanation.
52
52
53
+ If you have a GPU attached to your machine, it's equally as easy to launch your
54
+ kernel on it instead. For example, launching on a CUDA GPU:
55
+
56
+ ``` julia
57
+ using CUDAKernels # Required to access CUDADevice
58
+ A = CUDA. ones (1024 , 1024 )
59
+ kernel = mul2 (CUDADevice (), 16 )
60
+ # ... the rest is the same!
61
+ ```
62
+
63
+ AMDGPU (ROCm) support is also available via the ROCKernels.jl package, although
64
+ at this time it is considered experimental. Ping ` @jpsamaroo ` in any issues
65
+ specific to the ROCKernels backend.
66
+
53
67
## Important differences to Julia
54
68
55
69
1 . Functions inside kernels are forcefully inlined, except when marked with ` @noinline ` .
56
70
2 . Floating-point multiplication, addition, subtraction are marked contractable.
57
71
58
- ## Important differences to CUDA.jl
72
+ ## Important differences to CUDA.jl/AMDGPU.jl
59
73
60
74
1 . The kernels are automatically bounds-checked against either the dynamic or statically
61
75
provided ` ndrange ` .
62
- 2 . Functions like ` Base.sin ` are mapped to ` CUDA.sin ` .
76
+ 2 . Functions like ` Base.sin ` are mapped to ` CUDA.sin ` / ` AMDGPU.sin ` .
63
77
64
78
## Important differences to GPUifyLoops.jl
65
79
You can’t perform that action at this time.
0 commit comments