diff --git a/paddle/fluid/framework/details/bind_threaded_ssa_graph_executor.cc b/paddle/fluid/framework/details/bind_threaded_ssa_graph_executor.cc index cdb96eb8effc016aa01022d93c4c21c2e8453cb8..aa31a556c92c6fe3c1fb1c7cdd76b5fffa1291fd 100644 --- a/paddle/fluid/framework/details/bind_threaded_ssa_graph_executor.cc +++ b/paddle/fluid/framework/details/bind_threaded_ssa_graph_executor.cc @@ -274,8 +274,8 @@ void BindThreadedSSAGraphExecutor::RunMultiDeviceOpAsync( } } catch (...) { error_state = 1; - ready_ops->Push(nullptr); exception_.Catch(std::current_exception()); + ready_ops->Push(nullptr); } { std::lock_guard lock(mutex_); @@ -308,8 +308,8 @@ void BindThreadedSSAGraphExecutor::RunOpAsyncMainStream( } } catch (...) { error_state = 1; - ready_ops->Push(nullptr); exception_.Catch(std::current_exception()); + ready_ops->Push(nullptr); } { std::lock_guard lock(mutex_);