summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2013-05-11 02:38:11 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2013-05-11 02:38:11 +0000
commit1b09836bc3b543a06486e8989ce081f274a380a3 (patch)
tree0d1704e2f1b5f80ecc9751af3f076add6a6d1fcc /llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
parent639890222e83c3b17c668708316fc6bcf9c413e8 (diff)
downloadbcm5719-llvm-1b09836bc3b543a06486e8989ce081f274a380a3.tar.gz
bcm5719-llvm-1b09836bc3b543a06486e8989ce081f274a380a3.zip
Change getFrameMoves to return a const reference.
To add a frame now there is a dedicated addFrameMove which also takes care of constructing the move itself. llvm-svn: 181657
Diffstat (limited to 'llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp')
-rw-r--r--llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp b/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
index 0fda4edf863..f9bc83bb20f 100644
--- a/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
+++ b/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
@@ -113,8 +113,6 @@ void HexagonFrameLowering::emitPrologue(MachineFunction &MF) const {
MO.setImm(MFI->getMaxCallFrameSize());
}
- std::vector<MachineMove> &Moves = MMI.getFrameMoves();
-
if (needsFrameMoves) {
// Advance CFA. DW_CFA_def_cfa
unsigned FPReg = QRI->getFrameRegister();
@@ -122,17 +120,17 @@ void HexagonFrameLowering::emitPrologue(MachineFunction &MF) const {
MachineLocation Dst(MachineLocation::VirtualFP);
MachineLocation Src(FPReg, -8);
- Moves.push_back(MachineMove(0, Dst, Src));
+ MMI.addFrameMove(0, Dst, Src);
// R31 = (R31 - #4)
MachineLocation LRDst(RAReg, -4);
MachineLocation LRSrc(RAReg);
- Moves.push_back(MachineMove(0, LRDst, LRSrc));
+ MMI.addFrameMove(0, LRDst, LRSrc);
// R30 = (R30 - #8)
MachineLocation SPDst(FPReg, -8);
MachineLocation SPSrc(FPReg);
- Moves.push_back(MachineMove(0, SPDst, SPSrc));
+ MMI.addFrameMove(0, SPDst, SPSrc);
}
//
OpenPOWER on IntegriCloud