Changeset 6034


Ignore:
Timestamp:
May 13, 2018, 11:42:03 AM (5 months ago)
Author:
cameron
Message:

One more getBufferedSize bug fix

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/kernels/scanmatchgen.cpp

    r6027 r6034  
    136136            // It is possible that the matchRecordEnd position is one past EOF.  Make sure not
    137137            // to access past EOF.
    138             Value * const bufLimit = b->CreateSub(b->getBufferedSize("InputStream"), ONE);
     138            Value * const bufLimit = b->CreateSub(b->CreateAdd(scanwordPos, b->getAvailableItemCount("InputStream")), ONE);
    139139            matchRecordEnd = b->CreateUMin(matchRecordEnd, bufLimit);
    140140            Function * const dispatcher = m->getFunction("accumulate_match_wrapper"); assert (dispatcher);
Note: See TracChangeset for help on using the changeset viewer.