mirror of
https://gitee.com/mindspore/akg.git
synced 2025-12-06 11:59:12 +08:00
@@ -420,10 +420,12 @@ void DimensionPeeler::MapDimToSpace(AffinityAnalyzer &aff, Dim *dom_dim, int axi
|
||||
if (visited.count(prod)) return false;
|
||||
if (prod != nullptr) visited.insert(prod);
|
||||
if (!this->Propagation(axis_idx, dim, prod, affinity)) return false;
|
||||
for (auto &c : prod->cons) {
|
||||
if (!visited.count(c.first)) {
|
||||
cons_visit.emplace_back(prod);
|
||||
break;
|
||||
if (prod != nullptr) {
|
||||
for (auto &c : prod->cons) {
|
||||
if (!visited.count(c.first)) {
|
||||
cons_visit.emplace_back(prod);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
@@ -432,10 +434,12 @@ void DimensionPeeler::MapDimToSpace(AffinityAnalyzer &aff, Dim *dom_dim, int axi
|
||||
if (visited.count(cons)) return false;
|
||||
if (cons != nullptr) visited.insert(cons);
|
||||
if (!this->Propagation(axis_idx, dim, cons, affinity)) return false;
|
||||
for (auto &p : cons->prod) {
|
||||
if (!visited.count(p.first)) {
|
||||
prod_visit.emplace_back(cons);
|
||||
break;
|
||||
if (cons != nullptr) {
|
||||
for (auto &p : cons->prod) {
|
||||
if (!visited.count(p.first)) {
|
||||
prod_visit.emplace_back(cons);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
||||
@@ -699,7 +699,7 @@ class ReduceVectorizeEnable : public IRMutator {
|
||||
}
|
||||
|
||||
// step 2: final reduce area
|
||||
if (!cur_reduce_data_->isolate_reduce_provide.empty()) {
|
||||
if (!cur_reduce_data_->isolate_reduce_provide.empty() && isolate_reduce_provide != nullptr) {
|
||||
isolate_value = isolate_reduce_provide->value;
|
||||
}
|
||||
auto value = reduce_provide->value;
|
||||
|
||||
Reference in New Issue
Block a user