diff options
| author | Krzysztof Parzyszek <kparzysz@codeaurora.org> | 2017-10-16 19:08:41 +0000 |
|---|---|---|
| committer | Krzysztof Parzyszek <kparzysz@codeaurora.org> | 2017-10-16 19:08:41 +0000 |
| commit | 72518eaa6f5c85a1d633b91a1f0e30b2a84ca275 (patch) | |
| tree | e772060b1faf751234d2a8dae7627038808f9169 /llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | |
| parent | 3f9b4b7c91f9bd4364aa115c9294951b05754933 (diff) | |
Add iterator range MachineRegisterInfo::liveins(), adopt users, NFC
llvm-svn: 315927
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCFrameLowering.cpp')
| -rw-r--r-- | llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp b/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp index 756e35a6e6c6..0a01fdf9e676 100644 --- a/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp +++ b/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp @@ -312,11 +312,9 @@ static void HandleVRSaveUpdate(MachineInstr &MI, const TargetInstrInfo &TII) { // Live in and live out values already must be in the mask, so don't bother // marking them. - for (MachineRegisterInfo::livein_iterator - I = MF->getRegInfo().livein_begin(), - E = MF->getRegInfo().livein_end(); I != E; ++I) { - unsigned RegNo = TRI->getEncodingValue(I->first); - if (VRRegNo[RegNo] == I->first) // If this really is a vector reg. + for (std::pair<unsigned, unsigned> LI : MF->getRegInfo().liveins()) { + unsigned RegNo = TRI->getEncodingValue(LI.first); + if (VRRegNo[RegNo] == LI.first) // If this really is a vector reg. UsedRegMask &= ~(1 << (31-RegNo)); // Doesn't need to be marked. } |
