diff --git a/paddle/fluid/framework/operator.cc b/paddle/fluid/framework/operator.cc index 991476dff55b9a4c7e8ff3c1093e18e0b3380fc1..eb7ad8ed94ec95e2ef8fabd85d816d949aa0953d 100644 --- a/paddle/fluid/framework/operator.cc +++ b/paddle/fluid/framework/operator.cc @@ -1603,11 +1603,11 @@ void OperatorWithKernel::RunImpl(const Scope& scope, } #endif - auto exe_ctx = ExecutionContext(*this, scope, *dev_ctx, *runtime_ctx); // using cache if (kernel_type_.get()) { dev_ctx = pool.Get(kernel_type_->place_); } + auto exe_ctx = ExecutionContext(*this, scope, *dev_ctx, *runtime_ctx); // TODO(Liu-xiandong): Now we are using too much if-else and hard code in XPU // device, it's ugly, and we will refactor in the future.