[llvm] r225468 - CodeGen: Use handy new-fangled post-increment, NFC

Duncan P. N. Exon Smith dexonsmith at apple.com
Thu Jan 8 13:07:56 PST 2015


Author: dexonsmith
Date: Thu Jan  8 15:07:55 2015
New Revision: 225468

URL: http://llvm.org/viewvc/llvm-project?rev=225468&view=rev
Log:
CodeGen: Use handy new-fangled post-increment, NFC

Drive-by cleanup; I noticed this when reviewing the patch that became
r225466.

Modified:
    llvm/trunk/lib/CodeGen/CodeGenPrepare.cpp

Modified: llvm/trunk/lib/CodeGen/CodeGenPrepare.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/CodeGenPrepare.cpp?rev=225468&r1=225467&r2=225468&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/CodeGenPrepare.cpp (original)
+++ llvm/trunk/lib/CodeGen/CodeGenPrepare.cpp Thu Jan  8 15:07:55 2015
@@ -4330,7 +4330,7 @@ bool CodeGenPrepare::PlaceDbgValues(Func
   for (BasicBlock &BB : F) {
     Instruction *PrevNonDbgInst = nullptr;
     for (BasicBlock::iterator BI = BB.begin(), BE = BB.end(); BI != BE;) {
-      Instruction *Insn = BI; ++BI;
+      Instruction *Insn = BI++;
       DbgValueInst *DVI = dyn_cast<DbgValueInst>(Insn);
       // Leave dbg.values that refer to an alloca alone. These
       // instrinsics describe the address of a variable (= the alloca)





More information about the llvm-commits mailing list