Halide
AddImageChecks.h
Go to the documentation of this file.
1 #ifndef HALIDE_INTERNAL_ADD_IMAGE_CHECKS_H
2 #define HALIDE_INTERNAL_ADD_IMAGE_CHECKS_H
3 
4 /** \file
5  *
6  * Defines the lowering pass that adds the assertions that validate
7  * input and output buffers.
8  */
9 #include <map>
10 #include <string>
11 #include <vector>
12 
13 #include "Bounds.h"
14 #include "Expr.h"
15 
16 namespace Halide {
17 
18 struct Target;
19 
20 namespace Internal {
21 
22 class Function;
23 
24 /** Insert checks to make sure a statement doesn't read out of bounds
25  * on inputs or outputs, and that the inputs and outputs conform to
26  * the format required (e.g. stride.0 must be 1).
27  */
28 Stmt add_image_checks(const Stmt &s,
29  const std::vector<Function> &outputs,
30  const Target &t,
31  const std::vector<std::string> &order,
32  const std::map<std::string, Function> &env,
33  const FuncValueBounds &fb,
34  bool will_inject_host_copies);
35 
36 } // namespace Internal
37 } // namespace Halide
38 
39 #endif
Halide::Internal::ArgInfoKind::Function
@ Function
Bounds.h
Halide::Internal::FuncValueBounds
std::map< std::pair< std::string, int >, Interval > FuncValueBounds
Definition: Bounds.h:15
Halide
This file defines the class FunctionDAG, which is our representation of a Halide pipeline,...
Definition: AbstractGenerator.h:19
Halide::LinkageType::Internal
@ Internal
Not visible externally, similar to 'static' linkage in C.
Expr.h
Halide::Internal::add_image_checks
Stmt add_image_checks(const Stmt &s, const std::vector< Function > &outputs, const Target &t, const std::vector< std::string > &order, const std::map< std::string, Function > &env, const FuncValueBounds &fb, bool will_inject_host_copies)
Insert checks to make sure a statement doesn't read out of bounds on inputs or outputs,...