source: icGREP/icgrep-devel/icgrep/kernels/symboltablepipeline.h @ 4974

Last change on this file since 4974 was 4974, checked in by nmedfort, 3 years ago

Added the kernel instance class; removed original mmap file access in favour of the boost mmap system. corrected PrintRegister? routine.

File size: 1.3 KB
Line 
1/*
2 *  Copyright (c) 2016 International Characters.
3 *  This software is licensed to the public under the Open Software License 3.0.
4 */
5
6#ifndef SYMBOLTABLEPIPELINE_H
7#define SYMBOLTABLEPIPELINE_H
8
9#include <IDISA/idisa_builder.h>
10#include "kernel.h"
11
12namespace llvm {
13    class Module;
14    class Function;
15    class Type;
16}
17
18namespace pablo { class PabloFunction; class PabloBlock; }
19
20namespace kernel {
21
22class SymbolTableBuilder {
23public:
24    SymbolTableBuilder(llvm::Module * m, IDISA::IDISA_Builder * b);
25    ~SymbolTableBuilder();
26    void createKernels();
27    llvm::Function * ExecuteKernels();
28
29protected:
30
31    pablo::PabloFunction * generateLeadingFunction(const std::vector<unsigned> & endpoints);
32    pablo::PabloFunction * generateSortingFunction(const pablo::PabloFunction * const leading, const std::vector<unsigned> & endpoints);
33
34    void generateLLVMParser();
35
36private:
37    llvm::Module *                      mMod;
38    IDISA::IDISA_Builder *              iBuilder;
39    KernelBuilder *                     mS2PKernel;
40    KernelBuilder *                     mLeadingKernel;
41    KernelBuilder *                     mSortingKernel;
42    unsigned                            mLongestLookahead;
43    llvm::Type *                        mBitBlockType;
44    int                                 mBlockSize;
45};
46
47}
48
49#endif // SYMBOLTABLEPIPELINE_H
Note: See TracBrowser for help on using the repository browser.