Halide 19.0.0
Halide compiler and libraries
Loading...
Searching...
No Matches
included_schedule_file.schedule.h
Go to the documentation of this file.
1#ifndef included_schedule_file_SCHEDULE_H
2#define included_schedule_file_SCHEDULE_H
3
4// MACHINE GENERATED -- DO NOT EDIT
5// This schedule was automatically generated by Anderson2021
6// with autoscheduler_params=autoscheduler=Anderson2021 autoscheduler.active_block_limit=32 autoscheduler.active_warp_limit=64 autoscheduler.beam_size=32 autoscheduler.freeze_inline_compute_root=1 autoscheduler.parallelism=80 autoscheduler.random_dropout=100 autoscheduler.random_dropout_seed=32587330000 autoscheduler.randomize_tilings=1 autoscheduler.search_space_options=1111 autoscheduler.shared_memory_limit_kb=48 autoscheduler.shared_memory_sm_limit_kb=96
7
8#include "Halide.h"
9
11 ::Halide::Pipeline pipeline,
12 ::Halide::Target target) {
13 using ::Halide::Func;
14 using ::Halide::MemoryType;
15 using ::Halide::RVar;
16 using ::Halide::TailStrategy;
17 using ::Halide::Var;
18
19 Func relu = pipeline.get_func(4);
20 Func conv = pipeline.get_func(3);
21 Var c(relu.get_schedule().dims()[0].var);
22 Var ci("ci");
23 Var n(relu.get_schedule().dims()[3].var);
24 Var x(relu.get_schedule().dims()[1].var);
25 Var xi("xi");
26 Var xii("xii");
27 Var y(relu.get_schedule().dims()[2].var);
28 Var yi("yi");
29 Var yii("yii");
30 RVar r13_x(conv.update(0).get_schedule().dims()[0].var);
31 RVar r13_y(conv.update(0).get_schedule().dims()[1].var);
32 RVar r13_z(conv.update(0).get_schedule().dims()[2].var);
33 Var yi_serial_outer("yi_serial_outer");
34 Var xi_serial_outer("xi_serial_outer");
35 Var ci_serial_outer("ci_serial_outer");
36 relu
37 .split(c, c, ci, 24, TailStrategy::ShiftInwards)
38 .split(x, x, xi, 16, TailStrategy::ShiftInwards)
39 .split(y, y, yi, 4, TailStrategy::ShiftInwards)
40 .split(xi, xi, xii, 4, TailStrategy::ShiftInwards)
41 .split(yi, yi, yii, 2, TailStrategy::ShiftInwards)
42 .unroll(xii)
43 .unroll(yii)
44 .compute_root()
45 .reorder(xii, yii, ci, xi, yi, c, x, y, n)
46 .gpu_blocks(c)
47 .gpu_blocks(x)
48 .fuse(y, n, y)
49 .gpu_blocks(y)
50 .split(ci, ci_serial_outer, ci, 24, TailStrategy::GuardWithIf)
51 .gpu_threads(ci)
52 .split(xi, xi_serial_outer, xi, 4, TailStrategy::GuardWithIf)
53 .gpu_threads(xi)
54 .split(yi, yi_serial_outer, yi, 2, TailStrategy::GuardWithIf)
55 .gpu_threads(yi);
56 conv.update(0)
57 .split(c, c, ci, 24, TailStrategy::GuardWithIf)
58 .split(x, x, xi, 4, TailStrategy::GuardWithIf)
59 .split(y, y, yi, 16, TailStrategy::GuardWithIf)
60 .split(yi, yi, yii, 2, TailStrategy::GuardWithIf)
61 .unroll(yii)
62 .reorder(yii, r13_x, r13_y, r13_z, ci, xi, yi, c, x, y, n)
63 .gpu_blocks(c)
64 .gpu_blocks(x)
65 .fuse(y, n, y)
66 .gpu_blocks(y)
67 .split(ci, ci_serial_outer, ci, 24, TailStrategy::GuardWithIf)
68 .gpu_threads(ci)
69 .split(xi, xi_serial_outer, xi, 4, TailStrategy::GuardWithIf)
70 .gpu_threads(xi)
71 .split(yi, yi_serial_outer, yi, 8, TailStrategy::GuardWithIf)
72 .gpu_threads(yi);
73 conv
74 .split(c, c, ci, 24, TailStrategy::ShiftInwards)
75 .split(x, x, xi, 4, TailStrategy::ShiftInwards)
76 .split(y, y, yi, 16, TailStrategy::ShiftInwards)
77 .split(yi, yi, yii, 2, TailStrategy::ShiftInwards)
78 .unroll(yii)
79 .compute_root()
80 .reorder(yii, ci, xi, yi, c, x, y, n)
81 .gpu_blocks(c)
82 .gpu_blocks(x)
83 .fuse(y, n, y)
84 .gpu_blocks(y)
85 .split(ci, ci_serial_outer, ci, 24, TailStrategy::GuardWithIf)
86 .gpu_threads(ci)
87 .split(xi, xi_serial_outer, xi, 4, TailStrategy::GuardWithIf)
88 .gpu_threads(xi)
89 .split(yi, yi_serial_outer, yi, 8, TailStrategy::GuardWithIf)
90 .gpu_threads(yi);
91 conv.in(relu).store_in(MemoryType::Register).compute_at(relu, ci).bound_extent(c, 1).unroll(c).bound_extent(x, 4).unroll(x).bound_extent(y, 2).unroll(y).bound_extent(n, 1).unroll(n);
92}
93
94#endif // included_schedule_file_SCHEDULE_H
void apply_schedule_included_schedule_file(::Halide::Pipeline pipeline, ::Halide::Target target)
A class representing a Halide pipeline.
Definition Pipeline.h:107
Func get_func(size_t index)
Return handle to the index-th Func within the pipeline based on the topological order.
A struct representing a target machine and os to generate code for.
Definition Target.h:19