Skip to content

Commit e6b0d10

Browse files
aparshin-inteligcbot
authored andcommitted
[Autobackout][FuncReg]Revert of change: 4ab63c2
fixup erroneous assertion in epilogue generation ---------------------------
1 parent 513899d commit e6b0d10

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

IGC/VectorCompiler/lib/GenXCodeGen/GenXPrologEpilogInsertion.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -400,9 +400,7 @@ void GenXPrologEpilogInsertion::generateFunctionEpilog(Function &F,
400400
}
401401
RetSize = DL->getTypeSizeInBits(RetVal->getType()) / genx::ByteBits;
402402
std::vector<Value *> Worklist;
403-
bool UndefReturn = false;
404403
if (isa<StructType>(RetVal->getType())) {
405-
UndefReturn = isa<UndefValue>(RetVal);
406404
while (auto *InsValue = dyn_cast<InsertValueInst>(RetVal)) {
407405
RetVal = InsValue->getOperand(0);
408406
if (InsValue->getOperand(1)->getType()->getScalarType()->isIntegerTy(1))
@@ -411,7 +409,7 @@ void GenXPrologEpilogInsertion::generateFunctionEpilog(Function &F,
411409
}
412410
} else
413411
Worklist.push_back(RetVal);
414-
IGC_ASSERT(UndefReturn || !Worklist.empty());
412+
IGC_ASSERT(!Worklist.empty());
415413
for (auto *Ins : Worklist) {
416414
Instruction *InstToReplaceIn = &I;
417415
unsigned Offset = 0;

0 commit comments

Comments
 (0)