Ignore:
Timestamp:
Dec 31, 2018, 5:25:19 PM (5 months ago)
Author:
nmedfort
Message:

Work on OptimizationBranch?; revisited pipeline termination

File:
1 edited

Legend:

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

    r6186 r6261  
    7474}
    7575
    76 SwizzleGenerator::SwizzleGenerator(const std::unique_ptr<kernel::KernelBuilder> &,
     76SwizzleGenerator::SwizzleGenerator(const std::unique_ptr<kernel::KernelBuilder> & b,
    7777                                   const std::vector<StreamSet *> & inputs,
    7878                                   const std::vector<StreamSet *> & outputs,
    7979                                   const unsigned fieldWidth)
    80 : BlockOrientedKernel(makeSwizzleName(inputs, outputs, fieldWidth),
     80: BlockOrientedKernel(b, makeSwizzleName(inputs, outputs, fieldWidth),
    8181makeSwizzledInputs(inputs),
    8282makeSwizzledOutputs(outputs, fieldWidth),
     
    8888
    8989void SwizzleGenerator::generateDoBlockMethod(const std::unique_ptr<kernel::KernelBuilder> & b) {
    90        
     90
    9191    // We may need a few passes depending on the swizzle factor
    9292
     
    107107    Value * targetBlocks[swizzleFactor];
    108108    for (unsigned grp = 0; grp < swizzleGroups; grp++) {
    109         // First load all the data.       
     109        // First load all the data.
    110110        for (unsigned i = 0; i < swizzleFactor; i++) {
    111111            const auto streamNo = grp * swizzleFactor + i;
     
    139139
    140140
    141 SwizzleByGather::SwizzleByGather(const std::unique_ptr<KernelBuilder> &iBuilder)
    142 : BlockOrientedKernel("swizzleByGather", {}, {}, {}, {}, {}){
     141SwizzleByGather::SwizzleByGather(const std::unique_ptr<KernelBuilder> & b)
     142: BlockOrientedKernel(b, "swizzleByGather", {}, {}, {}, {}, {}){
    143143    for (unsigned i = 0; i < 2; i++) {
    144         mInputStreamSets.push_back(Binding{iBuilder->getStreamSetTy(4, 1), "inputGroup" + std::to_string(i)});
     144        mInputStreamSets.push_back(Binding{b->getStreamSetTy(4, 1), "inputGroup" + std::to_string(i)});
    145145    }
    146146    for (unsigned i = 0; i < 1; i++) {
    147         mOutputStreamSets.push_back(Binding{iBuilder->getStreamSetTy(8, 1), "outputGroup" + std::to_string(i), FixedRate(1)});
     147        mOutputStreamSets.push_back(Binding{b->getStreamSetTy(8, 1), "outputGroup" + std::to_string(i), FixedRate(1)});
    148148    }
    149149}
Note: See TracChangeset for help on using the changeset viewer.