Skip to content

Commit dce5006

Browse files
authored
Update README.md
1 parent 2b184f8 commit dce5006

File tree

1 file changed

+12
-24
lines changed

1 file changed

+12
-24
lines changed

README.md

Lines changed: 12 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -58,34 +58,25 @@ There is also [ReverseDiffSource](https://github.com/JuliaDiff/ReverseDiffSource
5858

5959
Current backends: OpenCL, CUDA, Julia Threaded
6060

61-
Planned backends: OpenGL, Vulkan
62-
6361
Implemented for all backends:
6462

6563
```Julia
6664
map(f, ::GPUArray...)
6765
map!(f, dest::GPUArray, ::GPUArray...)
6866

69-
# maps
70-
mapidx(f, A::GPUArray, args...) do idx, a, args...
71-
# e.g
72-
if idx < length(A)
73-
a[idx+1] = a[idx]
74-
end
75-
end
76-
77-
7867
broadcast(f, ::GPUArray...)
7968
broadcast!(f, dest::GPUArray, ::GPUArray...)
8069

81-
# calls `f` on args, with queues and context taken from `array`
82-
# f can be a julia function or a tuple (String, Symbol),
83-
# being a C kernel source string + the name of the kernel function.
84-
# first argument needs to be an untyped arg for global state. This can be mostly ignored, but needs to be passed to
85-
# e.g. `linear_index(array::GPUArray, state)`, which gives you a linear, per thread index into `array` on all backends.
86-
gpu_call(array::GPUArray, f, args::Tuple)
70+
mapreduce(f, op, ::GPUArray...) # so support for sum/mean/minimum etc comes for free
71+
72+
getindex, setindex!, push!, append!, splice!, append!, copy!, reinterpret, convert
73+
74+
From (CL/CU)FFT
75+
fft!/fft/ifft/ifft! and the matching plan_fft functions.
76+
From (CL/CU)BLAS
77+
gemm!, scal!, gemv! and the high level functions that are implemented with these, like A * B, A_mul_B!, etc.
8778
```
88-
Example for [gpu_call](https://github.com/JuliaGPU/GPUArrays.jl/blob/master/examples/custom_kernels.jl)
79+
8980

9081
# Usage
9182

@@ -122,29 +113,26 @@ function kernel(state, arg1, arg2, arg3) # args get splatted into the kernel cal
122113
return #kernel must return void
123114
end
124115
```
116+
Example for [gpu_call](https://github.com/JuliaGPU/GPUArrays.jl/blob/master/examples/custom_kernels.jl)
125117

126118
# Currently supported subset of Julia Code
127119

128120
working with immutable isbits (not containing pointers) type should be completely supported
129121
non allocating code (so no constructs like `x = [1, 2, 3]`). Note that tuples are isbits, so this works x = (1, 2, 3).
130122
Transpiler/OpenCL has problems with putting GPU arrays on the gpu into a struct - so no views and actually no multidimensional indexing. For that `size` is needed which would need to be part of the array struct. A fix for that is in sight, though.
131123

132-
| CLContext: FirePro w9100 | 0.0013 s| 7831 | 789.8|
133-
134124
# TODO / up for grabs
135125

136-
* stencil operations
126+
* stencil operations, convolutions
137127
* more tests and benchmarks
138128
* tests, that only switch the backend but use the same code
139129
* performance improvements!!
140-
* implement push!, append!, resize!, getindex, setindex!
141130
* interop between OpenCL, CUDA and OpenGL is there as a protype, but needs proper hooking up via `Base.copy!` / `convert`
142-
* share implementation of broadcast etc between backends. Currently they don't, since there are still subtle differences which should be eliminated over time!
143131

144132

145133
# Installation
146134

147-
I recently added a lot of features and bug fixes to the master branch.
135+
I recently added a lot of features and bug fixes to the master branch, so you might want to check that out (`Pkg.checkout("GPUArrays")`).
148136

149137
For the cudanative backend, you need to install [CUDAnative.jl manually](https://github.com/JuliaGPU/CUDAnative.jl/#installation) and it works only on osx + linux with a julia source build.
150138
Make sure to have either CUDA and/or OpenCL drivers installed correctly.

0 commit comments

Comments
 (0)