Skip to content

Commit 494316b

Browse files
committed
change assert to return
1 parent 5419bc8 commit 494316b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

llvm/lib/Target/PowerPC/PPCInstrInfo.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5363,8 +5363,9 @@ void PPCInstrInfo::replaceInstrAfterElimExt32To64(const Register &Reg,
53635363
IsReplaceInstr) {
53645364

53655365
const TargetRegisterClass *RC = MRI->getRegClass(Reg);
5366-
assert(RC != &PPC::G8RCRegClass && RC != &PPC::G8RC_and_G8RC_NOX0RegClass &&
5367-
"Must be 32-bit Register!");
5366+
5367+
if (RC == &PPC::G8RCRegClass || RC == &PPC::G8RC_and_G8RC_NOX0RegClass)
5368+
return;
53685369

53695370
if (!IsReplaceInstr)
53705371
NewOpcode = PPC::get64BitInstrFromSignedExt32BitInstr(Opcode);

0 commit comments

Comments
 (0)