new account here :) im an inference engineer and researcher and will be posting about high performance inference systems. if that interests you, do consider a follow :)
posting about underappreciated / unconvential techniques with CUDA.
one genuinely underappreciated technique is branchless top-k sorting using PTX predicate registers to avoid loops and branches
Suppose you have sorted values in registers, a conventional CUDA implementation inserts the new value into the sorted array by comparing individual elements. with setp.gtu.f32 you can create a predicate based on a comparison and select between two values based on that predicate using selp.f32
We formalized PTX in Lean so that we can formally prove GPU kernels correct.
This way, we can be confident that the kernels our agents wrote are correct, without ever needing to read them. 🧵
deep learning inference in libraries like tensort is so unoptimized that it virtually guarantees that if you want to host any model outside of an LLM you would have to so some sorts of kernel engineering to get to real production standards