Changeset 5272


Ignore:
Timestamp:
Jan 22, 2017, 9:00:06 PM (10 months ago)
Author:
cameron
Message:

Fix for loop bound in dumpTrace

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/IR_Gen/tracegen.h

    r5269 r5272  
    2020   
    2121    unsigned declareTraceVar(std::string traceVarName);
    22    
    2322    unsigned newTraceVar(std::string traceName);
    2423    void addTraceEntry(unsigned traceVar, llvm::Value * traceVal);
     
    9190    Value * nextIndex = iBuilder->CreateAnd(iBuilder->CreateAdd(loopIndex, iBuilder->getInt32(1)), mTraceIndexMask);
    9291    loopIndex->addIncoming(nextIndex, DumpTraceLoop);
    93     Value * atLastTraceIndex = iBuilder->CreateICmpEQ(loopIndex, lastTraceIndex);
     92    Value * atLastTraceIndex = iBuilder->CreateICmpEQ(nextIndex, lastTraceIndex);
    9493    iBuilder->CreateCondBr(atLastTraceIndex, DumpTraceExit, DumpTraceLoop);
    9594    iBuilder->SetInsertPoint(DumpTraceExit);
Note: See TracChangeset for help on using the changeset viewer.