From 35902ec635868340c2172d12903a479197d66edf Mon Sep 17 00:00:00 2001 From: zyfncg Date: Wed, 30 Nov 2022 11:14:07 +0800 Subject: [PATCH] Fix bug of wrong eigen dependency (#48485) * fix bug of eigen_dependency * fix xpu compile --- paddle/fluid/framework/op_kernel_type.h | 4 ++-- paddle/fluid/platform/device/xpu/xpu_op_list.h | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/paddle/fluid/framework/op_kernel_type.h b/paddle/fluid/framework/op_kernel_type.h index 78b38eed080..a609313e848 100644 --- a/paddle/fluid/framework/op_kernel_type.h +++ b/paddle/fluid/framework/op_kernel_type.h @@ -19,8 +19,8 @@ limitations under the License. */ #include "paddle/fluid/framework/data_layout.h" #include "paddle/fluid/framework/data_type.h" #include "paddle/fluid/framework/library_type.h" -#include "paddle/fluid/platform/device_context.h" #include "paddle/fluid/platform/place.h" +#include "paddle/phi/core/device_context.h" namespace paddle { namespace framework { @@ -50,7 +50,7 @@ class OpKernelType { customized_type_value_(customized_type_value) {} OpKernelType(proto::VarType::Type data_type, - const platform::DeviceContext& dev_ctx, + const phi::DeviceContext& dev_ctx, DataLayout data_layout = DataLayout::kAnyLayout, LibraryType library_type = LibraryType::kPlain, int customized_type_value = kDefaultCustomizedTypeValue) diff --git a/paddle/fluid/platform/device/xpu/xpu_op_list.h b/paddle/fluid/platform/device/xpu/xpu_op_list.h index e008e9d111c..d701294865d 100644 --- a/paddle/fluid/platform/device/xpu/xpu_op_list.h +++ b/paddle/fluid/platform/device/xpu/xpu_op_list.h @@ -15,6 +15,7 @@ limitations under the License. */ #include #include "paddle/fluid/framework/op_kernel_type.h" +#include "paddle/fluid/platform/device/xpu/xpu_info.h" #include "paddle/phi/backends/xpu/xpu_op_list.h" namespace paddle { -- GitLab