Ignore:
Timestamp:
Oct 6, 2016, 9:21:59 AM (3 years ago)
Author:
cameron
Message:

Streamset refactoring

File:
1 edited

Legend:

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

    r5109 r5184  
    7474    Value * counts = partial_sum_popcount(iBuilder, mDeletionFieldWidth, iBuilder->simd_not(del_mask));
    7575    iBuilder->CreateBlockAlignedStore(iBuilder->bitCast(counts), delCountBlock, {iBuilder->getInt32(0), iBuilder->getInt32(0)});
    76    
     76    /* Stream deletion has only been applied within fields; the actual number of data items
     77     * has not yet changed.   */
     78    Value * produced = getProducedItemCount(self);
     79    produced = iBuilder->CreateAdd(produced, ConstantInt::get(iBuilder->getSizeTy(), iBuilder->getStride()));
     80    setProducedItemCount(self, produced);   
    7781    iBuilder->CreateRetVoid();
    7882    iBuilder->restoreIP(savePoint);
     
    98102    iBuilder->CreateBlockAlignedStore(iBuilder->CreateOr(EOF_del, delmaskVal), delmaskPtr);
    99103    iBuilder->CreateCall(doBlockFunction, {self});
     104    /* Adjust the produced item count */
     105    Value * produced = getProducedItemCount(self);
     106    produced = iBuilder->CreateSub(produced, ConstantInt::get(iBuilder->getSizeTy(), iBuilder->getStride()));
     107    setProducedItemCount(self, iBuilder->CreateAdd(produced, remainingBytes));
     108
    100109    iBuilder->CreateRetVoid();
    101110    iBuilder->restoreIP(savePoint);
Note: See TracChangeset for help on using the changeset viewer.