VapourSynth-llvmexpr
Loading...
Searching...
No Matches
Compiler.hpp
Go to the documentation of this file.
1
19
20#ifndef LLVMEXPR_RUNTIME_LLVM_COMPILER_HPP
21#define LLVMEXPR_RUNTIME_LLVM_COMPILER_HPP
22
23#include <map>
24#include <string>
25#include <vector>
26
27#include "VapourSynth4.h"
28
31#include "Jit.hpp"
32
33class Compiler {
34 public:
35 Compiler(std::vector<Token> tokens_in, const VSVideoInfo* out_vi,
36 const std::vector<const VSVideoInfo*>& in_vi, int width_in,
37 int height_in, bool mirror, std::string dump_path,
38 const std::map<std::pair<int, std::string>, int>& p_map,
39 std::string function_name, int opt_level_in, int approx_math_in,
40 const analysis::ExpressionAnalysisResults& analysis_results_in,
41 int tile_x_in = 0, int tile_y_in = 0,
43 const std::vector<std::string>& output_props = {});
44
46
47 private:
48 std::vector<Token> tokens;
49 const VSVideoInfo* vo;
50 const std::vector<const VSVideoInfo*>& vi;
51 int num_inputs;
52 int width;
53 int height;
54 bool mirror_boundary;
55 std::string dump_ir_path;
56 const std::map<std::pair<int, std::string>, int>& prop_map;
57 std::string func_name;
58 int opt_level;
59 int approx_math;
60 int tile_x;
61 int tile_y;
62 ExprMode expr_mode;
63 const std::vector<std::string>& output_props;
64
65 // Analysis results
66 const analysis::ExpressionAnalysisResults& analysis_results;
67
68 CompiledFunction compileWithApproxMath(int actual_approx_math);
69};
70
71#endif // LLVMEXPR_RUNTIME_LLVM_COMPILER_HPP
ExprMode
CompiledFunction compile()
Definition Compiler.cpp:95
Compiler(std::vector< Token > tokens_in, const VSVideoInfo *out_vi, const std::vector< const VSVideoInfo * > &in_vi, int width_in, int height_in, bool mirror, std::string dump_path, const std::map< std::pair< int, std::string >, int > &p_map, std::string function_name, int opt_level_in, int approx_math_in, const analysis::ExpressionAnalysisResults &analysis_results_in, int tile_x_in=0, int tile_y_in=0, ExprMode mode=ExprMode::Expr, const std::vector< std::string > &output_props={})
Definition Compiler.cpp:77