[llvm] r256127 - [X86] Use range-based for loop. NFC
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Sun Dec 20 10:41:57 PST 2015
Author: ctopper
Date: Sun Dec 20 12:41:57 2015
New Revision: 256127
URL: http://llvm.org/viewvc/llvm-project?rev=256127&view=rev
Log:
[X86] Use range-based for loop. NFC
Modified:
llvm/trunk/lib/Target/X86/X86InstrInfo.cpp
Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.cpp?rev=256127&r1=256126&r2=256127&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrInfo.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86InstrInfo.cpp Sun Dec 20 12:41:57 2015
@@ -2425,9 +2425,8 @@ bool X86InstrInfo::isSafeToClobberEFLAGS
// It is safe to clobber EFLAGS at the end of a block of no successor has it
// live in.
if (Iter == E) {
- for (MachineBasicBlock::succ_iterator SI = MBB.succ_begin(),
- SE = MBB.succ_end(); SI != SE; ++SI)
- if ((*SI)->isLiveIn(X86::EFLAGS))
+ for (MachineBasicBlock *S : MBB.successors())
+ if (S->isLiveIn(X86::EFLAGS))
return false;
return true;
}
More information about the llvm-commits
mailing list