News for hackers. Stuff that matters.
Re:Llama.cpp: Full CUDA GPU Acceleration by bilekas on Tuesday June 13, 2023 @03:52AM (#36306984)
I'm no expert but if I understand correctly the CUDA cores are the main pull and the API to them.

They're supposed to be more optimized and more stable compared to AMD. That's how it was before anyway, not sure today.

Re:Llama.cpp: Full CUDA GPU Acceleration by Aardwolf on Tuesday June 13, 2023 @03:55AM (#36307003)
Isn't the main component for AI matrix multiplication? What makes it so hard to create a good alternative API for matrix multiplication?
Re:Llama.cpp: Full CUDA GPU Acceleration by marcyb5st on Tuesday June 13, 2023 @04:22AM (#36307221)
I think API for matrix multiplication is just a part of the issue. CUDA tooling has better ergonomics, it's easier to set up and treated as first class citizen in tools like Tensorflow and Pytorch.

So, while I can't talk about the hardware differences in detail, developer experience is greatly on nVidia side and now AMD has a moat to overcome to catch up.

Re:Llama.cpp: Full CUDA GPU Acceleration by bilekas on Tuesday June 13, 2023 @04:14AM (#36307162)
Well I think there are 2 types right ? Tensor cores (which afaik AMD dont have) which are better for matrix ops, and CUDO which are better for general parallel ops.

Maybe someone more clever than me can go into the specifics, I only understand the minimum of the low lvl GPU details.

Nice high lvl document

[0] https://www.acecloudhosting.com/blog/cuda-cores-vs-tensor-co...

Re:Llama.cpp: Full CUDA GPU Acceleration by dotnet00 on Tuesday June 13, 2023 @09:27AM (#36309922)
It's a lot more complicated than just writing a matrix multiplication kernel because there are all sorts of operations you need to have on top of matrix multiplication (non linearities, various ways of manipulating the data) and this sort of effort is only really worthwhile if it's well optimized.

On top of that, AMD's compute stack is fairly immature, their OpenCL support is buggy and ROCm compiles device specific code, so it has very limited hardware support and is kind of unrealistic to distribute compiled binaries for. Then, getting to the optimization aspect, NVIDIA has many tools which provide detailed information on the GPU's behavior, making it much easier to identify bottlenecks and optimize. AMD is still working on these.

Finally, NVIDIA went out of its way to support ML applications. They provide a lot of their own tooling to make using them easier. AMD seems to have struggled on the "easier" part.

Re:Llama.cpp: Full CUDA GPU Acceleration by emmender on Tuesday June 13, 2023 @10:58AM (#36311197)
there is nccl, gpudirect, nvlink and so on and so forth.. It is not just matmul on gpus.