source: icGREP/icgrep-devel/icgrep/kernels/charclasses.h @ 5769

Last change on this file since 5769 was 5748, checked in by nmedfort, 18 months ago

Bug fix for segment pipeline parallel mode + memory management improvements.

File size: 1.0 KB
Line 
1/*
2 *  Copyright (c) 2017 International Characters.
3 *  This software is licensed to the public under the Open Software License 3.0.
4 */
5#ifndef CHARCLASSES_H
6#define CHARCLASSES_H
7
8#include <pablo/pablo_kernel.h>  // for PabloKernel
9
10namespace kernel { class KernelBuilder; }
11namespace IDISA { class IDISA_Builder; }
12namespace re { class RE; class CC; }
13namespace kernel {
14
15struct CharClassesSignature {
16    CharClassesSignature(const std::vector<re::CC *> & ccs);
17protected:
18    const std::string mSignature;
19};
20
21class CharClassesKernel : public CharClassesSignature, public pablo::PabloKernel {
22public:
23    CharClassesKernel(const std::unique_ptr<kernel::KernelBuilder> & iBuilder, std::vector<re::CC *> && ccs);
24    bool hasSignature() const override { return true; }
25    std::string makeSignature(const std::unique_ptr<kernel::KernelBuilder> & iBuilder) override;
26    bool isCachable() const override { return true; }
27protected:
28    void generatePabloMethod() override;
29protected:
30    std::vector<re::CC *> mCCs;
31};
32
33}
34#endif
Note: See TracBrowser for help on using the repository browser.