Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Previously we relied on the structure type (which represented matrix type) mangling to obtain its layout. Now, when DPCPP mangling scheme is aligned with C++, thus the structure lost their usual mangling. Yet we want to preserve the desired information within the matrix type, coming from DPCPP headers. To achive this the 'Matrix structure' was changed form: template <typename T, int R, int C, int L, int S> struct __spirv_JointMatrixINTEL; to template <typename T, int R, int C, int L, int S> struct __spirv_JointMatrixINTEL { T (*Value)[R][C][L + 1][S + 1]; }; so it's no longer an opaque structure and now it look like this in LLVM IR: %struct.__spirv_JointMatrixINTEL = type { [42 x [6 x [2 x [1 x i32]]]]* } Here we encode the number of Rows, Cols, Layout and Scope as sizes of an array (which element type is the same as the base matrix's type), which is a bit odd, but it's probably the best way we can preserve the information now without having the matrix type itself in LLVM. Signed-off-by: Dmitry Sidorov <[email protected]>
- Loading branch information