Typo! How did we commute nodes before?!

llvm-svn: 28229
This commit is contained in:
Evan Cheng 2006-05-12 01:46:26 +00:00
parent 22acb80971
commit c30a5558f2
1 changed files with 1 additions and 1 deletions

View File

@ -45,7 +45,7 @@ MachineInstr *TargetInstrInfo::commuteInstruction(MachineInstr *MI) const {
assert(MI->getOperand(1).isRegister() && MI->getOperand(2).isRegister() &&
"This only knows how to commute register operands so far");
unsigned Reg1 = MI->getOperand(1).getReg();
unsigned Reg2 = MI->getOperand(1).getReg();
unsigned Reg2 = MI->getOperand(2).getReg();
MI->getOperand(2).setReg(Reg1);
MI->getOperand(1).setReg(Reg2);
return MI;