18namespace Autoscheduler {
32std::vector<std::vector<int64_t>>
generate_tilings(
const vector<int64_t> &s,
int d,
int factor,
bool allow_splits);
42 std::vector<IntrusivePtr<const LoopNest>>
children;
81 h ^= (next + 0x9e3779b9 + (h << 6) + (h >> 2));
94 count += c->funcs_realized_or_inlined();
115 const LoopNest *parent =
nullptr)
const;
123 c->set_working_set_at_task_feature(working_set,
features);
124 features->get(c->stage).working_set_at_task = working_set;
139 bool use_cached_features)
const;
144 return node ==
nullptr;
149 return bounds.emplace(f, b);
158 void dump(std::ostream &os,
string prefix,
const LoopNest *parent)
const;
191 const vector<int64_t> &tiling,
200 bool in_realization)
const;
257 StageMap<std::unique_ptr<StageScheduleState>> &state_map,
261 const LoopNest *compute_site)
const;
A class representing a reference count to be used with IntrusivePtr.
A reference to a site in a Halide statement at the top of the body of a particular for loop.
A Halide variable, to be used when defining functions.
std::vector< std::vector< int64_t > > generate_tilings(const vector< int64_t > &s, int d, int factor, bool allow_splits)
const LoopNest * deepest_common_ancestor(const std::map< const LoopNest *, std::pair< const LoopNest *, int > > &parents, const LoopNest *a, const LoopNest *b)
void compute_loop_nest_parents(std::map< const LoopNest *, std::pair< const LoopNest *, int > > &parents, const LoopNest *here, int depth)
This file defines the class FunctionDAG, which is our representation of a Halide pipeline,...
@ Internal
Not visible externally, similar to 'static' linkage in C.
unsigned __INT64_TYPE__ uint64_t
signed __INT64_TYPE__ int64_t
uint64_t hash_of_producers_stored_at_root
const LoopNest * innermost
std::vector< FuncVar > vars
int vectorized_loop_index
std::ostringstream schedule_source
IntrusivePtr< const LoopNest > parallelize_in_tiles(const Adams2019Params ¶ms, const vector< int64_t > &tiling, const LoopNest *parent) const
int vectorized_loop_index
std::map< uint64_t, StageMap< ScheduleFeatures > > features
const FunctionDAG::Node * node
void recompute_inlined_features(const StageMap< Sites > &sites, StageMap< ScheduleFeatures > *features) const
void inline_func(const FunctionDAG::Node *f)
std::vector< IntrusivePtr< const LoopNest > > compute_in_tiles(const FunctionDAG::Node *f, const LoopNest *parent, const Adams2019Params ¶ms, int v, bool in_realization) const
void collect_stages(std::set< const FunctionDAG::Node::Stage * > &stages) const
bool accesses_input_buffer() const
std::vector< int64_t > size
void get_sites(StageMap< Sites > &sites, const LoopNest *task=nullptr, const LoopNest *parent=nullptr) const
const Bound & get_bounds(const FunctionDAG::Node *f) const
void compute_features(const FunctionDAG &dag, const Adams2019Params ¶ms, const StageMap< Sites > &sites, int64_t instances, int64_t parallelism, const LoopNest *parent, const LoopNest *grandparent, const LoopNest &root, int64_t *working_set, StageMap< ScheduleFeatures > *features, bool use_cached_features) const
void memoize_features(StageMap< ScheduleFeatures > &memoized_features, const StageMap< ScheduleFeatures > *features_to_insert) const
std::map< uint64_t, StageMap< ScheduleFeatures > > features_cache
bool computes(const FunctionDAG::Node *f) const
std::vector< IntrusivePtr< const LoopNest > > children
void set_working_set_at_task_feature(int64_t working_set, StageMap< ScheduleFeatures > *features) const
void copy_from(const LoopNest &n)
std::vector< std::pair< int, int > > collect_producers(const StageMap< Sites > &sites) const
const Bound & set_bounds(const FunctionDAG::Node *f, BoundContents *b) const
void memoize_points_computed_minimum(StageMap< ScheduleFeatures > &memoized_features, const StageMap< ScheduleFeatures > *features) const
static void hash_combine(uint64_t &h, uint64_t next)
void dump(std::ostream &os, string prefix, const LoopNest *parent) const
uint64_t compute_hash_of_producers_stored_at_root(const StageMap< Sites > &sites) const
int64_t max_inlined_calls() const
const FunctionDAG::Node::Stage * stage
void compute_here(const FunctionDAG::Node *f, bool tileable, int v, const Adams2019Params ¶ms)
bool calls(const FunctionDAG::Node *f) const
void copy_from_including_features(const LoopNest &n)
void structural_hash(uint64_t &h, int depth) const
size_t funcs_realized_or_inlined() const
std::set< const FunctionDAG::Node * > store_at
std::map< uint64_t, StageMap< StageMap< FeatureIntermediates > > > feature_intermediates_cache
void apply(LoopLevel here, StageMap< std::unique_ptr< StageScheduleState > > &state_map, double num_cores, int depth, const LoopNest *parent, const LoopNest *compute_site) const
NodeMap< int64_t > inlined
void compute_working_set_from_features(int64_t *working_set, const StageMap< ScheduleFeatures > *features) const
Intrusive shared pointers have a reference count (a RefCount object) stored in the class itself.
A class that can represent Vars or RVars.