Ignore:
Timestamp:
Feb 10, 2017, 1:48:34 PM (3 years ago)
Author:
nmedfort
Message:

Adjusted pablo compiler to use getInputStream and getOutputStream when accessing packed stream fields.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/array-test.cpp

    r5267 r5310  
    4141static cl::list<std::string> inputFiles(cl::Positional, cl::desc("<input file ...>"), cl::OneOrMore);
    4242
    43 void generate(PabloKernel * kernel, const unsigned size) {
     43void generate(PabloKernel * kernel) {
    4444
    4545    PabloBuilder pb(kernel->getEntryBlock());
    4646
    47     Var * input = kernel->addInput("input", kernel->getStreamSetTy(8));
    48     Var * matches = kernel->addOutput("matches", kernel->getStreamSetTy(size));
     47    Var * input = kernel->getInputStreamVar("input");
     48    Var * matches = kernel->getOutputStreamVar("matches");
    4949
    5050    PabloAST * basis[8];
     
    125125    s2pk.generateKernel({&ByteStream}, {&BasisBits});
    126126
    127     PabloKernel bm(iBuilder, "MatchParens");
    128     generate(&bm, count);
     127    PabloKernel bm(iBuilder, "MatchParens",
     128        {Binding{iBuilder->getStreamSetTy(8), "input"}},
     129        {Binding{iBuilder->getStreamSetTy(count), "matches"}});
     130
     131    generate(&bm);
    129132
    130133    bm.generateKernel({&BasisBits}, {&matches});
Note: See TracChangeset for help on using the changeset viewer.