3 ms·
Vulcan is a driver-level API. It competes with DirectX and OpenGL. CUDA is a language you write kernels. It competes with OpenAI's Triton language. Here's wha
by nl 3y ago
Vulcan is a driver-level API. It competes with DirectX and OpenGL.
CUDA is a language you write kernels. It competes with OpenAI's Triton language.
Here's what CUDA looks like: https://github.com/tspeterkim/flash-attention-minimal/blob/main/flash.cu https://github.com/tspeterkim/flash-attention-minimal/blob/m...
This is what Triton looks like: https://triton-lang.org/main/getting-started/tutorials/06-fused-attention.html#sphx-glr-download-getting-started-tutorials-06-fused-attention-py https://triton-lang.org/main/getting-started/tutorials/06-fu...
By contrast Vulcan looks like this: https://github.com/KhronosGroup/Vulkan-Samples/blob/main/samples/api/hello_triangle/hello_triangle.cpp https://github.com/KhronosGroup/Vulkan-Samples/blob/main/sam...
(It's true to some extent that maybe you could use Vulcan shaders to write deep learning kernels, maybe? I'm not aware of anyone doing it though)