Ignore:
Timestamp:
May 17, 2018, 3:41:00 PM (15 months ago)
Author:
nmedfort
Message:

Major refactoring of buffer types. Static buffers replace Circular and CircularCopyback?. External buffers unify Source/External?.

File:
1 edited

Legend:

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

    r5985 r6047  
    6666    const auto expandedSize = boost::lcm(boost::lcm(bufferSize, 3U), 4U);
    6767
    68     StreamSetBuffer * ByteStream = pxDriver.addBuffer<SourceBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8));
     68    StreamSetBuffer * ByteStream = pxDriver.addBuffer<ExternalBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8));
    6969    Kernel * mmapK = pxDriver.addKernelInstance<MMapSourceKernel>(iBuilder);
    7070    mmapK->setInitialArguments({fileDescriptor});
    7171    pxDriver.makeKernelCall(mmapK, {}, {ByteStream});
    7272   
    73     StreamSetBuffer * Expanded3_4Out = pxDriver.addBuffer<CircularBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8), expandedSize);
     73    StreamSetBuffer * Expanded3_4Out = pxDriver.addBuffer<StaticBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8), expandedSize);
    7474    Kernel * expandK = pxDriver.addKernelInstance<expand3_4Kernel>(iBuilder);
    7575    pxDriver.makeKernelCall(expandK, {ByteStream}, {Expanded3_4Out});
    7676   
    77     StreamSetBuffer * Radix64out = pxDriver.addBuffer<CircularBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8), bufferSize);
     77    StreamSetBuffer * Radix64out = pxDriver.addBuffer<StaticBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8), bufferSize);
    7878    Kernel * radix64K = pxDriver.addKernelInstance<radix64Kernel>(iBuilder);
    7979    pxDriver.makeKernelCall(radix64K, {Expanded3_4Out}, {Radix64out});
     
    8484        pxDriver.makeKernelCall(base64K, {Radix64out}, {Base64out});
    8585    } else {
    86         StreamSetBuffer * Base64out = pxDriver.addBuffer<CircularBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8), bufferSize);
     86        StreamSetBuffer * Base64out = pxDriver.addBuffer<StaticBuffer>(iBuilder, iBuilder->getStreamSetTy(1, 8), bufferSize);
    8787        Kernel * base64K = pxDriver.addKernelInstance<base64Kernel>(iBuilder);
    8888        pxDriver.makeKernelCall(base64K, {Radix64out}, {Base64out});       
Note: See TracChangeset for help on using the changeset viewer.