This repository was archived by the owner on Apr 28, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -334,6 +334,14 @@ std::pair<isl::union_map, isl::union_map> extractAccesses(
334334 return {finder.reads , finder.writes };
335335}
336336
337+ bool isReductionUpdate (const Provide* op) {
338+ if (const Call* call = op->values [0 ].as <Call>()) {
339+ return call->is_intrinsic (tc2halide::kReductionUpdate );
340+ } else {
341+ return false ;
342+ }
343+ }
344+
337345/*
338346 * Take a parametric expression "f" and convert it into an expression
339347 * on the iteration domains in "domain" by reinterpreting the parameters
@@ -488,14 +496,6 @@ std::vector<Reduction> findReductions(const Stmt& s) {
488496 class FindReductions : public IRVisitor {
489497 using IRVisitor::visit;
490498
491- bool isReductionUpdate (const Provide* op) {
492- if (const Call* call = op->values [0 ].as <Call>()) {
493- return call->is_intrinsic (tc2halide::kReductionUpdate );
494- } else {
495- return false ;
496- }
497- }
498-
499499 // Keep track of any reduction variable name for use in visit(Provide*)
500500 void visit (const Variable* op) {
501501 if (op->reduction_domain .defined ()) {
You can’t perform that action at this time.
0 commit comments