Ignore:
Timestamp:
Jul 30, 2018, 1:36:48 AM (6 months ago)
Author:
xwa163
Message:
  1. Implement twist_kernel and untwist_kernel by PEXT and PDEP
  2. Use twist form for multiplexing lz4 grep
File:
1 edited

Legend:

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

    r6133 r6135  
    2222#include <kernels/lz4/lz4_bitstream_match_copy_kernel.h>
    2323#include <kernels/lz4/lz4_bitstream_not_kernel.h>
    24 #include <kernels/lz4/aio/lz4_i4_bytestream_aio.h>
    2524#include <kernels/fake_stream_generating_kernel.h>
    2625#include <kernels/bitstream_pdep_kernel.h>
     
    401400
    402401    StreamSetBuffer * fakeMatchCopiedBits = mPxDriver.addBuffer<StaticBuffer>(idb, idb->getStreamSetTy(8), this->getInputBufferBlocks(idb));
    403     Kernel* fakeStreamGeneratorK = mPxDriver.addKernelInstance<FakeStreamGeneratingKernel>(idb, numOfCharacterClasses, 8);
    404     mPxDriver.makeKernelCall(fakeStreamGeneratorK, {decompressedCharClasses}, {fakeMatchCopiedBits});
     402    StreamSetBuffer * u8NoFinalStream = mPxDriver.addBuffer<StaticBuffer>(idb, idb->getStreamSetTy(1), this->getInputBufferBlocks(idb), 1);
     403
     404    Kernel* fakeStreamGeneratorK = mPxDriver.addKernelInstance<FakeStreamGeneratingKernel>(idb, numOfCharacterClasses, std::vector<unsigned>({8, 1}));
     405    mPxDriver.makeKernelCall(fakeStreamGeneratorK, {decompressedCharClasses}, {fakeMatchCopiedBits, u8NoFinalStream});
    405406
    406407    StreamSetBuffer * LineBreakStream = mPxDriver.addBuffer<StaticBuffer>(idb, idb->getStreamSetTy(1, 1), this->getInputBufferBlocks(idb));
     
    409410
    410411
     412    externalStreamNames.push_back("UTF8_nonfinal");
     413
    411414    kernel::Kernel * icgrepK = mGrepDriver->addKernelInstance<kernel::ICGrepKernel>(idb, mREs[0], externalStreamNames, std::vector<cc::Alphabet *>{mpx.get()}, cc::BitNumbering::BigEndian);
    412     mGrepDriver->makeKernelCall(icgrepK, {fakeMatchCopiedBits, decompressedCharClasses}, {MatchResults});
     415    mGrepDriver->makeKernelCall(icgrepK, {fakeMatchCopiedBits, u8NoFinalStream, decompressedCharClasses}, {MatchResults});
    413416    MatchResultsBufs[0] = MatchResults;
    414417
     
    774777
    775778    // GeneratePipeline
    776     this->generateLoadByteStream(iBuilder);
    777 //    this->generateLoadByteStreamAndBitStream(iBuilder);
     779//    this->generateLoadByteStream(iBuilder);
     780    this->generateLoadByteStreamAndBitStream(iBuilder);
    778781
    779782    parabix::StreamSetBuffer * decompressedByteStream = this->generateAIODecompression(iBuilder);
Note: See TracChangeset for help on using the changeset viewer.