Ignore:
Timestamp:
Oct 17, 2017, 8:59:21 AM (2 years ago)
Author:
cameron
Message:

Unified FDsource kernel; filename - now interpreted as stdin

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/kernels/source_kernel.h

    r5464 r5693  
    1616    bool isCachable() const override { return true; }
    1717    bool hasSignature() const override { return false; }
    18 protected:
    1918    void linkExternalMethods(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
    2019    void generateInitializeMethod(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
     
    3231    bool isCachable() const override { return true; }
    3332    bool hasSignature() const override { return false; }
    34 protected:
    3533    void generateInitializeMethod(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
    3634    void generateDoSegmentMethod(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
     
    4139};
    4240
     41class FDSourceKernel final : public SegmentOrientedKernel {
     42public:
     43    FDSourceKernel(const std::unique_ptr<kernel::KernelBuilder> & iBuilder, unsigned blocksPerSegment = 1, unsigned codeUnitWidth = 8);
     44    bool isCachable() const override { return true; }
     45    bool hasSignature() const override { return false; }
     46    void linkExternalMethods(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
     47    void generateInitializeMethod(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
     48    void generateDoSegmentMethod(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
     49    void generateFinalizeMethod(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
     50protected:
     51    const unsigned          mSegmentBlocks;
     52    const unsigned          mCodeUnitWidth;
     53    llvm::Function *        mFileSizeFunction;
     54};
     55   
    4356class MemorySourceKernel final : public SegmentOrientedKernel {
    4457public:
Note: See TracChangeset for help on using the changeset viewer.