|
|
|
|
|
by tsegratis
69 days ago
|
|
yes. do you have a more useful meaning for tensors? MLIR distinguishes arrays and tensors by allowing array mutation, but not for tensors; which allows a large class of optimizations though the internal representation is one and the same i understand it is the same for SIMD aswell (modulo alignment etc) |
|
But it looks like [MLIR and all other implementations of] SIMD only accept vectors; so there can't be Zero-Copy there because the tensor must (?) be copied to a vector to pass to a SIMD e.g. matmul routine, and then the resultant vector must be copied back into a tensor only if there are subsequent references to the complete tensor instead of just a slice?
FWIU, AFAICS, GPUs are designed for 3x3 tensors (and affine transformation to 2D) but for greater degrees like for 4x4 tensors (e.g. for SQG) you must implement shaders?