Changeset 5069 for icGREP


Ignore:
Timestamp:
Jun 22, 2016, 7:18:13 AM (3 years ago)
Author:
cameron
Message:

Simplification: replace wcPipelineBuilder object by wcPipeline function.

File:
1 edited

Legend:

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

    r5065 r5069  
    138138
    139139
     140
    140141class wcPipelineBuilder {
    141142public:
     
    157158using namespace kernel;
    158159
    159 wcPipelineBuilder::wcPipelineBuilder(Module * m, IDISA::IDISA_Builder * b)
    160 : mMod(m)
    161 , iBuilder(b)
    162 , mBitBlockType(b->getBitBlockType())
    163 , mBlockSize(b->getBitBlockWidth()){
    164    
    165 }
    166 
    167 wcPipelineBuilder::~wcPipelineBuilder(){
    168 }
    169 
    170 
    171 Function * wcPipelineBuilder::ExecuteKernels(PabloFunction * function) {
     160
     161Function * wcPipeline(Module * mMod, IDISA::IDISA_Builder * iBuilder, PabloFunction * function) {
     162    Type * mBitBlockType = iBuilder->getBitBlockType();
     163    unsigned mBlockSize = iBuilder->getBitBlockWidth();
    172164    s2pKernel  s2pk(iBuilder);
    173165    s2pk.generateKernel();
     
    263255    IDISA::IDISA_Builder * idb = IDISA::GetIDISA_Builder(M);
    264256
    265     wcPipelineBuilder pipelineBuilder(M, idb);
    266257    Encoding encoding(Encoding::Type::UTF_8, 8);
    267258    pablo::PabloFunction * function = wc_gen(encoding);
    268     llvm::Function * main_IR = pipelineBuilder.ExecuteKernels(function);
     259    llvm::Function * main_IR = wcPipeline(M, idb, function);
    269260
    270261    wcEngine = JIT_to_ExecutionEngine(M);
     
    310301   
    311302}
    312 
    313303
    314304
Note: See TracChangeset for help on using the changeset viewer.