From a5999d834514779090d49f0ea465f08fc1537075 Mon Sep 17 00:00:00 2001 From: Ruibiao Chen Date: Thu, 8 Dec 2022 12:02:56 +0800 Subject: [PATCH] Set WaiterType of kGpuSync to kCPU (#48758) --- .../framework/new_executor/interpreter/stream_analyzer.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/paddle/fluid/framework/new_executor/interpreter/stream_analyzer.cc b/paddle/fluid/framework/new_executor/interpreter/stream_analyzer.cc index 920fec72bd..88fac23338 100644 --- a/paddle/fluid/framework/new_executor/interpreter/stream_analyzer.cc +++ b/paddle/fluid/framework/new_executor/interpreter/stream_analyzer.cc @@ -356,7 +356,8 @@ void StreamAnalyzer::ShrinkEventInfo( platform::DeviceType StreamAnalyzer::GetWaiterType( const Instruction& instr) const { - if (instr.KernelType() == OpFuncType::kCpuSync) { + if (instr.KernelType() == OpFuncType::kCpuSync || + instr.KernelType() == OpFuncType::kGpuSync) { return platform::kCPU; } else { if (platform::is_xpu_place(place_)) { -- GitLab