Go to the documentation of this file. 1 #ifndef HALIDE_DEFINITION_H
2 #define HALIDE_DEFINITION_H
17 struct DefinitionContents;
18 struct FunctionContents;
19 class ReductionDomain;
26 struct Specialization;
58 return contents.
same_as(other.contents);
77 const std::vector<Expr> &
args()
const;
78 std::vector<Expr> &
args();
83 const std::vector<Expr> &
values()
const;
84 std::vector<Expr> &
values();
const std::vector< Expr > & values() const
Get the default (no-specialization) right-hand-side of the definition.
A base class for algorithms that need to recursively walk over the IR.
A Function definition which can either represent a init or an update definition.
std::string failure_message
This file defines the class FunctionDAG, which is our representation of a Halide pipeline,...
std::vector< Expr > split_predicate() const
Split predicate into vector of ANDs.
@ Internal
Not visible externally, similar to 'static' linkage in C.
const std::vector< Expr > & args() const
Get the default (no-specialization) arguments (left-hand-side) of the definition.
std::string source_location() const
Attempt to get the source file and line where this definition was made using DWARF introspection.
bool defined() const
Definition objects are nullable.
void accept(IRVisitor *) const
Pass an IRVisitor through to all Exprs referenced in the definition.
A base class for passes over the IR which modify it (e.g.
bool is_init() const
Is this an init definition; otherwise it's an update definition.
const std::vector< Specialization > & specializations() const
You may create several specialized versions of a func with different stage-specific schedules.
const StageSchedule & schedule() const
Get the default (no-specialization) stage-specific schedule associated with this definition.
const Specialization & add_specialization(Expr condition)
A fragment of Halide syntax.
Definition()
Construct an undefined Definition object.
void mutate(IRMutator *)
Pass an IRMutator through to all Exprs referenced in the definition.
A schedule for a single stage of a Halide pipeline.
A reference-counted handle on a reduction domain, which is just a vector of ReductionVariable.
bool same_as(const Definition &other) const
Equality of identity.
const Expr & predicate() const
Get the predicate on the definition.
Definition get_copy() const
Return a copy of this Definition.
HALIDE_ALWAYS_INLINE bool same_as(const IntrusivePtr &other) const