!19318 fix some models run gpu_cl fail in galaxys9
Merge pull request !19318 from yeyunpeng2020/gpu
This commit is contained in:
commit
11b6b6b5a5
|
@ -62,7 +62,7 @@ int OpenCLExecutor::RunOrTune(const std::vector<Tensor *> &inputs, const std::ve
|
|||
if (zero_shape_num != kernel->out_tensors().size()) {
|
||||
if (is_tune) {
|
||||
ret = op_kernel->PreProcess();
|
||||
if (RET_OK != ret) {
|
||||
if (ret != RET_OK) {
|
||||
MS_LOG(WARNING) << "PreProcess kernel failed, name: " << kernel->name() << " in tuning";
|
||||
opencl_runtime_ins->SetProfiling(profiling_tmp);
|
||||
return RET_OK;
|
||||
|
@ -72,6 +72,12 @@ int OpenCLExecutor::RunOrTune(const std::vector<Tensor *> &inputs, const std::ve
|
|||
MS_LOG(ERROR) << "tuning kernel failed, name: " << kernel->name();
|
||||
return ret;
|
||||
}
|
||||
ret = op_kernel->PostProcess();
|
||||
if (ret != RET_OK) {
|
||||
MS_LOG(WARNING) << "PostProcess kernel failed, name: " << kernel->name() << " in tuning";
|
||||
opencl_runtime_ins->SetProfiling(profiling_tmp);
|
||||
return RET_OK;
|
||||
}
|
||||
} else {
|
||||
ret = kernel->Execute();
|
||||
if (ret != RET_OK) {
|
||||
|
|
Loading…
Reference in New Issue