Skip to content

Commit 054646f

Browse files
committed
[X86] commuteInstructionImpl - assert that only MOVSDrr is being commuted to SHUFPDrri
Noticed while preparing for #142972
1 parent 6887016 commit 054646f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

llvm/lib/Target/X86/X86InstrInfo.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2487,6 +2487,7 @@ MachineInstr *X86InstrInfo::commuteInstructionImpl(MachineInstr &MI, bool NewMI,
24872487
break;
24882488
}
24892489

2490+
assert(Opc == X86::MOVSDrr && "Only MOVSD can commute to SHUFPD");
24902491
WorkingMI = CloneIfNew(MI);
24912492
WorkingMI->setDesc(get(X86::SHUFPDrri));
24922493
WorkingMI->addOperand(MachineOperand::CreateImm(0x02));

0 commit comments

Comments
 (0)