Skip to content

Commit 7682d93

Browse files
amielczaigcbot
authored andcommitted
Remove null dereference
Remove null return value dereference
1 parent 8b32f60 commit 7682d93

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

IGC/VectorCompiler/lib/GenXOpts/CMAnalysis/ConstantFoldingGenX.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ static Constant *constantFoldRdRegion(Type *RetTy,
7171
return UndefValue::get(RetTy);
7272
// Parse the region parameters.
7373
unsigned WholeNumElements =
74-
dyn_cast<IGCLLVM::FixedVectorType>(Input->getType())->getNumElements();
74+
cast<IGCLLVM::FixedVectorType>(Input->getType())->getNumElements();
7575
auto OffsetC = dyn_cast<Constant>(
7676
Operands[GenXIntrinsic::GenXRegion::RdIndexOperandNum]);
7777
if (!OffsetC)

0 commit comments

Comments
 (0)