================
@@ -141,6 +141,22 @@ class MatrixBuilder {
return B.CreateCall(TheFn->getFunctionType(), TheFn, Ops, Name);
}
+ /// Create a column-major matrix from a row-major matrix with the given
+ /// logical dimensions by transposing it.
+ CallInst *CreateRowMajorToColumnMajorTransform(Value *Matrix, unsigned Rows,
+ unsigned Columns,
+ const Twine &Name = "") {
+ return CreateMatrixTranspose(Matrix, Columns, Rows, Name);
+ }
+
+ /// Create a row-major matrix from a column-major matrix with the given
+ /// logical dimensions by transposing it.
+ CallInst *CreateColumnMajorToRowMajorTransform(Value *Matrix, unsigned Rows,
+ unsigned Columns,
+ const Twine &Name = "") {
+ return CreateMatrixTranspose(Matrix, Rows, Columns, Name);
----------------
bob80905 wrote:
I suspect this is a no-op, and Columns and Rows should be swapped as above.
That, or this function should be called with swapped row/col parameters, but it
is not.
https://github.com/llvm/llvm-project/pull/186898
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits