Browse Source

remove_32byte_limit_for_cpu_gatherv2

tags/v0.6.0-beta
lichenever 5 years ago
parent
commit
3398c2d74b
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      mindspore/ccsrc/parallel/ops_info/gather_v2_p_info.cc

+ 2
- 2
mindspore/ccsrc/parallel/ops_info/gather_v2_p_info.cc View File

@@ -79,8 +79,8 @@ Status GatherV2PInfo::CheckStrategy(const StrategyPtr &strategy) {
auto param_shape = inputs_shape_.at(0); auto param_shape = inputs_shape_.at(0);
auto param_strategy = strategy->GetInputDim().at(0); auto param_strategy = strategy->GetInputDim().at(0);
auto slice_shape = param_shape.at(param_shape.size() - 1) / param_strategy.at(param_strategy.size() - 1); auto slice_shape = param_shape.at(param_shape.size() - 1) / param_strategy.at(param_strategy.size() - 1);
if (slice_shape % 8 != 0 && slice_shape != 1) {
MS_LOG(DEBUG) << name_ << ": Last dim of param slice shape need 32Byte aligned.";
if ((target_ != CPU) && (slice_shape % 8 != 0) && (slice_shape != 1)) {
MS_LOG(ERROR) << name_ << ": Last dim of param slice shape need 32Byte aligned.";
return FAILED; return FAILED;
} }




Loading…
Cancel
Save