Skip to content

Commit

Permalink
[SPIR-V] Fix warning -Wsometimes-uninitialized (#83901)
Browse files Browse the repository at this point in the history
  • Loading branch information
michalpaszkowski committed Mar 4, 2024
1 parent 3b5965e commit 72cf95d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion llvm/lib/Target/SPIRV/SPIRVEmitIntrinsics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,7 @@ void SPIRVEmitIntrinsics::insertAssignPtrTypeIntrs(Instruction *I) {
EltTyConst = UndefValue::get(AI->getAllocatedType());
else if (auto *GEP = dyn_cast<GetElementPtrInst>(I))
EltTyConst = UndefValue::get(GEP->getResultElementType());
else if (I->getType()->isPointerTy())
else
EltTyConst = UndefValue::get(IntegerType::getInt8Ty(I->getContext()));

buildIntrWithMD(Intrinsic::spv_assign_ptr_type, {I->getType()}, EltTyConst, I,
Expand Down

0 comments on commit 72cf95d

Please sign in to comment.