Skip to content
Prev 14402 / 15075 Next

Can R on a Mac use the GPU

H Bill, 

I am not aware of any packages that do this for you directly. While it is certainly possible to write a Metal shader that will get the job done, it will likely take a substantial amount of non-trivial effort. To further complicate the issue Apple GPUs do not support double-precision computation (used by R). 

Maybe it would be possible for you to accelerate computation used Apple-provided routines from the Acceleration framework (e.g. BLAS and LAPACK)? Many of those routines have access to the hardware matrix accelerators present on Apple hardware and can result in major performance improvements. 

Best, 

Taras