[Hexagon] Remove incorrect offset scaling

llvm-svn: 272399
This commit is contained in:
Krzysztof Parzyszek 2016-06-10 15:43:18 +00:00
parent 27f06ae7a5
commit 96cfc381e2
1 changed files with 2 additions and 4 deletions

View File

@ -1015,10 +1015,9 @@ bool HexagonInstrInfo::expandPostRAPseudo(MachineBasicBlock::iterator MI)
unsigned NewOpc = Is128B ? Hexagon::V6_vL32b_ai_128B
: Hexagon::V6_vL32b_ai;
int32_t Off = MI->getOperand(2).getImm();
int32_t Idx = Off;
BuildMI(MBB, MI, DL, get(NewOpc), DstReg)
.addOperand(MI->getOperand(1))
.addImm(Idx)
.addImm(Off)
.setMemRefs(MI->memoperands_begin(), MI->memoperands_end());
MBB.erase(MI);
return true;
@ -1029,10 +1028,9 @@ bool HexagonInstrInfo::expandPostRAPseudo(MachineBasicBlock::iterator MI)
unsigned NewOpc = Is128B ? Hexagon::V6_vS32b_ai_128B
: Hexagon::V6_vS32b_ai;
int32_t Off = MI->getOperand(1).getImm();
int32_t Idx = Is128B ? (Off >> 7) : (Off >> 6);
BuildMI(MBB, MI, DL, get(NewOpc))
.addOperand(MI->getOperand(0))
.addImm(Idx)
.addImm(Off)
.addOperand(MI->getOperand(2))
.setMemRefs(MI->memoperands_begin(), MI->memoperands_end());
MBB.erase(MI);