4 ms·
> Because cuda matrix multiplication is so optimized that no one with a bit of sense would roll out his own Really? What if you have, for example, special matr
by jakub_h 11y ago
> Because cuda matrix multiplication is so optimized that no one with a bit of sense would roll out his own
Really? What if you have, for example, special matrices, not general ones? What's going to be faster, generating a matrix and then running the fastest general matrix multiplication code money can buy on it, or, even a somewhat slower code, but one that can instead use some extra invariants?
> Addidionally, the main issue in gpu kernels is not the ugliness of c itself, but the need to optimize algorithms to the hardware of the gpu, thus making the code much more verbose and ugly than the naive c code.
But that sounds like a compiler issue to be solved. And then you don't have to do it by hand, you let the machine find it out. (And I can't help but think that C is terrible for array based programming anyway. Granted, pure Lua might not be great either for the same reasons.)
- dragandj 11y agoWhile these things are desirable, please point to: 1. a solution such as you describe that might be used today 2. how would a typical user of lua (a GPU non-expert) program those special matrices 3. even if he/she can code the algorithm, how can it be done from lua instead of C