Ignore:
Timestamp:
Jan 9, 2018, 2:52:07 PM (16 months ago)
Author:
cameron
Message:

Test case for compileCCfromCodeUnitStream using DirectLineFeedBuilder?

File:
1 edited

Legend:

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

    r5797 r5824  
    2121using namespace re;
    2222using namespace llvm;
     23
     24
     25DirectLineFeedBuilder::DirectLineFeedBuilder(const std::unique_ptr<kernel::KernelBuilder> & b)
     26: PabloKernel(b, "lf_byte",
     27// input
     28{Binding{b->getStreamSetTy(1, 8), "codeUnitStream", FixedRate(), Principal()}},
     29// output
     30{Binding{b->getStreamSetTy(1), "lf"}}) {
     31
     32}
     33
     34void DirectLineFeedBuilder::generatePabloMethod() {
     35    PabloBuilder pb(getEntryBlock());
     36    PabloAST * LF = compileCCfromCodeUnitStream(makeByte(0x0A), getInput(0), pb);
     37    pb.createAssign(pb.createExtract(getOutput(0), pb.getInteger(0)), LF);
     38}
    2339
    2440
Note: See TracChangeset for help on using the changeset viewer.