Ignore:
Timestamp:
Nov 2, 2018, 7:18:31 PM (9 months ago)
Author:
nmedfort
Message:

Initial version of PipelineKernel? + revised StreamSet? model.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/character_deletion.cpp

    r6090 r6184  
    3737
    3838using namespace llvm;
    39 using namespace parabix;
    4039using namespace kernel;
    4140
     
    5453 * */
    5554
    56 StreamSetBuffer * loadBasisBits(ParabixDriver & pxDriver, Value* inputStream, Value* fileSize, int inputBufferBlocks) {
     55StreamSetBuffer * loadBasisBits(CPUDriver & pxDriver, Value* inputStream, Value* fileSize, int inputBufferBlocks) {
    5756    auto & iBuilder = pxDriver.getBuilder();
    5857
     
    7069}
    7170
    72 StreamSetBuffer * generateSwizzledDeletion(ParabixDriver & pxDriver, StreamSetBuffer * BasisBits, int inputBufferBlocks) {
     71StreamSetBuffer * generateSwizzledDeletion(CPUDriver & pxDriver, StreamSetBuffer * BasisBits, int inputBufferBlocks) {
    7372    auto & iBuilder = pxDriver.getBuilder();
    7473
     
    9291
    9392// TODO: It seems that there are still some bugs in DeleteByPEXTkernel
    94 StreamSetBuffer * generateDeletion(ParabixDriver & pxDriver, StreamSetBuffer * BasisBits, int inputBufferBlocks) {
     93StreamSetBuffer * generateDeletion(CPUDriver & pxDriver, StreamSetBuffer * BasisBits, int inputBufferBlocks) {
    9594    auto & iBuilder = pxDriver.getBuilder();
    9695
     
    112111}
    113112
    114 StreamSetBuffer * generateDeletionByCompression(ParabixDriver & pxDriver, StreamSetBuffer * BasisBits, int inputBufferBlocks) {
     113StreamSetBuffer * generateDeletionByCompression(CPUDriver & pxDriver, StreamSetBuffer * BasisBits, int inputBufferBlocks) {
    115114    auto & iBuilder = pxDriver.getBuilder();
    116115
     
    118117    Kernel * ccK = pxDriver.addKernelInstance<ParabixCharacterClassKernelBuilder>(iBuilder, "deletionMarker", std::vector<re::CC *>{re::subtractCC(re::makeByte(0, 255), re::makeCC(characterToBeDeleted))}, 8);
    119118    pxDriver.makeKernelCall(ccK, {BasisBits}, {CharacterMarkerBuffer});
     119
     120    #warning TODO: replace StreamFilterCompiler with the deposit method
    120121
    121122    StreamSetBuffer * compressedBits = pxDriver.addBuffer<StaticBuffer>(iBuilder, iBuilder->getStreamSetTy(8), inputBufferBlocks);
     
    151152    const int inputBufferBlocks = codegen::BufferSegments * codegen::ThreadNum * 16;
    152153
    153     ParabixDriver pxDriver("character_deletion");
     154    CPUDriver pxDriver("character_deletion");
    154155    auto & iBuilder = pxDriver.getBuilder();
    155156    Module * M = iBuilder->getModule();
     
    189190    Kernel * outK = pxDriver.addKernelInstance<StdOutKernel>(iBuilder, 8);
    190191    pxDriver.makeKernelCall(outK, {deletedByteStream}, {});
    191 
    192192    pxDriver.generatePipelineIR();
    193 
    194     pxDriver.deallocateBuffers();
    195 
    196193    iBuilder->CreateRetVoid();
    197194
Note: See TracChangeset for help on using the changeset viewer.