Ignore:
Timestamp:
Mar 22, 2018, 2:49:54 AM (13 months ago)
Author:
xwa163
Message:

Fix lz4 related GEP instructions and TODO

File:
1 edited

Legend:

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

    r5853 r5926  
    111111    for (unsigned i = 0; i < mSwizzleSetCount; i++) {
    112112        Value * pendingData = iBuilder->getScalarField("pendingSwizzleData" + std::to_string(i));
    113         Value * outputStreamPtr = iBuilder->getOutputStreamBlockPtr("outputSwizzle" + std::to_string(i), iBuilder->getInt32(0));
    114         iBuilder->CreateBlockAlignedStore(pendingData, iBuilder->CreateGEP(outputStreamPtr, outputIndex));
     113        Value * outputStreamPtr = iBuilder->getOutputStreamBlockPtr("outputSwizzle" + std::to_string(i), iBuilder->getInt32(0), outputIndex);
     114        iBuilder->CreateBlockAlignedStore(pendingData, outputStreamPtr);
    115115    }
    116116    iBuilder->setProducedItemCount("outputSwizzle0", iBuilder->CreateAdd(pendingOffset, outputProduced));
     
    185185    // There is a separate vector of pending data for each swizzle group.
    186186    std::vector<Value *> pendingData;
    187     std::vector<Value *> outputStreamPtr;
    188187
    189188    for (unsigned i = 0; i < mSwizzleSetCount; i++) {
    190189        pendingData.push_back(iBuilder->getScalarField("pendingSwizzleData" + std::to_string(i)));
    191         outputStreamPtr.push_back(iBuilder->getOutputStreamBlockPtr("outputSwizzle" + std::to_string(i), iBuilder->getInt32(0)));
    192190    }
    193191
     
    210208                pendingOffset)));
    211209            //iBuilder->CallPrintRegister("ComBineDGROUP", combinedGroup);
    212             // To avoid an unpredictable branch, always store the combined group, whether full or not.             
    213             iBuilder->CreateBlockAlignedStore(combinedGroup, iBuilder->CreateGEP(outputStreamPtr[j], outputIndex));
     210            // To avoid an unpredictable branch, always store the combined group, whether full or not.
     211            iBuilder->CreateBlockAlignedStore(combinedGroup, iBuilder->getOutputStreamBlockPtr("outputSwizzle" + std::to_string(j), outputIndex));
    214212           
    215213            // Any items in excess of the space available in the current pending group overflow for the next group.
Note: See TracChangeset for help on using the changeset viewer.