Skip to content

Commit d56c1b8

Browse files
tuStromaigcbot
authored andcommitted
Checking literal type
Literal types don't have names and attempt to read it's name causes assertion fail. Matrix types nead to have specific prefix in their name, thus literal types can't be matrix type.
1 parent 9fa222a commit d56c1b8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

IGC/Compiler/Optimizer/OpenCLPasses/JointMatrixFuncsResolutionPass/JointMatrixFuncsResolutionPass.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -754,6 +754,9 @@ static bool isMatrixType(const Type *type)
754754
if (!eltType || !eltType->isStructTy())
755755
return false;
756756

757+
if (cast<StructType>(eltType)->isLiteral())
758+
return false;
759+
757760
StringRef name = eltType->getStructName();
758761
if (name.startswith("intel.joint_matrix") || name.startswith("spirv.JointMatrixINTEL._"))
759762
return true;

0 commit comments

Comments
 (0)