Skip to content

Commit 61b96b3

Browse files
esukhovigcbot
authored andcommitted
Bugfix inside IGCVectorizer.cpp
Assertion with unnecessary llvm::cast fixed, more general type is used instead.
1 parent 7e2552b commit 61b96b3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

IGC/Compiler/CISACodeGen/IGCVectorizer.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -337,15 +337,15 @@ bool IGCVectorizer::handleBinaryInstruction(VecArr &Slice) {
337337
return true;
338338
}
339339
}
340-
VecArr Operands;
340+
VecVal Operands;
341341
for (unsigned int OperNum = 0; OperNum < First->getNumOperands(); ++OperNum) {
342342
Value* Vectorized = checkOperandsToBeVectorized(First, OperNum, Slice);
343343
if (Vectorized)
344-
Operands.push_back(llvm::cast<Instruction>(Vectorized));
344+
Operands.push_back(Vectorized);
345345
else {
346346
Value* VectorizedOperand = vectorizeSlice(Slice, OperNum);
347347
if (!VectorizedOperand) { PRINT_LOG_NL("Couldn't vectorize Slice"); return false; }
348-
Operands.push_back(llvm::cast<Instruction>(VectorizedOperand));
348+
Operands.push_back(VectorizedOperand);
349349
}
350350
}
351351

0 commit comments

Comments
 (0)