Ignore:
Timestamp:
May 30, 2018, 12:41:51 AM (15 months ago)
Author:
xwa163
Message:
  1. Enable swizzled match copy in multiplexing lz4_grep for some special case
  2. Implement some lz4 AIO (all-in-one) pipeline and related kernel
Location:
icGREP/icgrep-devel/icgrep/kernels
Files:
6 added
2 edited

Legend:

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

    r6047 r6059  
    566566        BasicBlock* entryBlock = b->GetInsertBlock();
    567567        Value* SIZE_1 = b->getSize(1);
    568         Value* SIZE_256 = b->getSize(fw);
    569         Value* INT256_0 = b->getIntN(fw, 0);
    570         Value* INT256_1 = b->getIntN(fw, 1);
    571 
    572         Value* endBlockIndex = b->CreateUDiv(position, SIZE_256);
    573         Value* endOffset = b->CreateZExt(b->CreateURem(position, SIZE_256), b->getIntNTy(fw));
     568        Value* SIZE_FW = b->getSize(fw);
     569        Value* INT_FW_0 = b->getIntN(fw, 0);
     570        Value* INT_FW_1 = b->getIntN(fw, 1);
     571
     572        Value* endBlockIndex = b->CreateUDiv(position, SIZE_FW);
     573        Value* endOffset = b->CreateZExt(b->CreateURem(position, SIZE_FW), b->getIntNTy(fw));
    574574
    575575        BasicBlock* appendMatchOffsetMarkerCon = b->CreateBasicBlock("appendMatchOffsetMarkerCon");
     
    594594        this->storeMatchOffsetMarker(b, phiCurrentIndex, phiEndBits);
    595595        phiCurrentIndex->addIncoming(b->CreateAdd(phiCurrentIndex, SIZE_1), b->GetInsertBlock());
    596         phiEndBits->addIncoming(INT256_0, b->GetInsertBlock());
     596        phiEndBits->addIncoming(INT_FW_0, b->GetInsertBlock());
    597597
    598598        b->CreateBr(appendMatchOffsetMarkerCon);
     
    600600        // ---- AppendM0Exit
    601601        b->SetInsertPoint(appendMatchOffsetMarkerExit);
    602         Value* finalEndBits = b->CreateOr(phiEndBits, b->CreateShl(INT256_1, endOffset));
     602        Value* finalEndBits = b->CreateOr(phiEndBits, b->CreateShl(INT_FW_1, endOffset));
    603603        b->setScalarField("pendingMarchOffsetMarkerIndex", phiCurrentIndex);
    604604        b->setScalarField("pendingMatchOffsetMarkerBits", finalEndBits);
  • icGREP/icgrep-devel/icgrep/kernels/multiblock_kernel.cpp

    r6047 r6059  
    127127    }
    128128    mIsFinal = b->CreateICmpEQ(mNumOfStrides, b->getSize(0));
     129        mIsFinal = b->CreateAnd(mIsFinal, mInitiallyFinal);
    129130    mNumOfStrides = b->CreateSelect(mIsFinal, mNumOfStridesInFinalSegment, mNumOfStrides);
    130131    for (unsigned i = 0; i < mStreamSetOutputs.size(); i++) {
Note: See TracChangeset for help on using the changeset viewer.