1#ifndef HALIDE_INTERVAL_H
2#define HALIDE_INTERVAL_H
17#ifdef COMPILING_HALIDE
26 return pos_inf_noinline();
29 return neg_inf_noinline();
44 : min(min), max(max) {
105 static Expr neg_inf_expr, pos_inf_expr;
109 static Expr pos_inf_noinline();
110 static Expr neg_inf_noinline();
#define internal_assert(c)
Base classes for Halide expressions (Halide::Expr) and statements (Halide::Internal::Stmt)
#define HALIDE_ALWAYS_INLINE
This file defines the class FunctionDAG, which is our representation of a Halide pipeline,...
@ Internal
Not visible externally, similar to 'static' linkage in C.
A fragment of Halide syntax.
A class to represent ranges of Exprs.
static Interval single_point(const Expr &e)
Construct an interval representing a single point.
void include(const Interval &i)
Expand the interval to include another Interval.
bool operator==(const Interval &other) const
Equivalent to same_as.
static Interval make_union(const Interval &a, const Interval &b)
Construct the smallest interval containing two intervals.
static Interval make_intersection(const Interval &a, const Interval &b)
Construct the largest interval contained within two other intervals.
Expr min
The lower and upper bound of the interval.
Interval(const Expr &min, const Expr &max)
Construct an interval from a lower and upper bound.
static Interval nothing()
The interval representing nothing.
static Interval everything()
The interval representing everything.
bool has_lower_bound() const
Does the interval have a finite greatest lower bound.
static Expr pos_inf()
Exprs to represent positive and negative infinity.
bool same_as(const Interval &other) const
Is the interval the same as another interval.
bool is_single_point(const Expr &e) const
Is the interval a particular single value.
void include(const Expr &e)
Expand the interval to include an Expr.
bool is_empty() const
Is the interval the empty set.
bool is_everything() const
Is the interval the entire range.
static Expr make_min(const Expr &a, const Expr &b)
An eagerly-simplifying min of two Exprs that respects infinities.
static Expr make_max(const Expr &a, const Expr &b)
An eagerly-simplifying max of two Exprs that respects infinities.
bool has_upper_bound() const
Does the interval have a finite least upper bound.
bool is_single_point() const
Is the interval just a single value (min == max)
bool is_bounded() const
Does the interval have a finite upper and lower bound.
Interval()
A default-constructed Interval is everything.