Skip to content

Commit 347bad6

Browse files
authored
Clean paddle/fluid/platform/dynload [fluid_ops] (#66386)
* Fix * Fix * Fix * Fix
1 parent c6f2050 commit 347bad6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+21
-3141
lines changed

paddle/fluid/framework/CMakeLists.txt

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -144,12 +144,6 @@ cc_library(
144144
var_type_traits
145145
SRCS var_type_traits.cc
146146
DEPS framework_proto scope phi common)
147-
if(WITH_GPU)
148-
target_link_libraries(var_type_traits dynload_cuda)
149-
endif()
150-
if(WITH_XPU)
151-
target_link_libraries(var_type_traits dynload_xpti)
152-
endif()
153147

154148
# every source file that includes "dnnl.h" must depends on onednn
155149
# or, the first one should depends on onednn
@@ -947,7 +941,6 @@ cc_library(
947941
framework_proto
948942
op_registry
949943
operator
950-
dynamic_loader
951944
string_helper
952945
phi
953946
common
@@ -971,7 +964,8 @@ set(FLUID_FRAMEWORK_MODULES
971964
executor
972965
data_feed_proto
973966
layer
974-
dynamic_loader
967+
phi
968+
common
975969
custom_operator)
976970

977971
cc_library(paddle_framework DEPS ${FLUID_FRAMEWORK_MODULES})

paddle/fluid/inference/tensorrt/CMakeLists.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,22 +27,22 @@ nv_library(
2727
nv_test(
2828
test_tensorrt
2929
SRCS test_tensorrt.cc
30-
DEPS dynload_cuda device_context dynamic_loader)
30+
DEPS device_context phi common)
3131
if(WIN32)
3232
nv_test(
3333
test_tensorrt_engine
3434
SRCS test_engine.cc test_dynamic_engine.cc
35-
DEPS dynload_cuda tensorrt_engine tensorrt_plugin)
35+
DEPS phi common tensorrt_engine tensorrt_plugin)
3636
elseif(WITH_CINN)
3737
nv_test(
3838
test_tensorrt_engine
3939
SRCS test_engine.cc test_dynamic_engine.cc
40-
DEPS fleet_executor dynload_cuda tensorrt_engine tensorrt_plugin python)
40+
DEPS fleet_executor phi common tensorrt_engine tensorrt_plugin python)
4141
else()
4242
nv_test(
4343
test_tensorrt_engine
4444
SRCS test_engine.cc test_dynamic_engine.cc
45-
DEPS fleet_executor dynload_cuda tensorrt_engine tensorrt_plugin python)
45+
DEPS fleet_executor phi common tensorrt_engine tensorrt_plugin python)
4646
endif()
4747
nv_test(
4848
test_arg_mapping_context

paddle/fluid/memory/allocation/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ if(WITH_GPU OR WITH_ROCM)
3030
pinned_allocator.cc
3131
stream_safe_cuda_allocator.cc
3232
thread_local_allocator.cc)
33-
list(APPEND ALLOCATOR_DEPS cuda_device_guard gpu_info dynload_cuda)
33+
list(APPEND ALLOCATOR_DEPS cuda_device_guard gpu_info phi common)
3434
endif()
3535

3636
if(WITH_ROCM)

paddle/fluid/operators/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ cc_library(ops_extra_info SRCS ops_extra_info.cc DEPS attribute phi common)
111111
set(COMMON_OP_DEPS ${COMMON_OP_DEPS} phi common)
112112
set(COMMON_OP_DEPS ${COMMON_OP_DEPS} selected_rows_utils
113113
lod_tensor lod_rank_table executor static_prim_api)
114-
set(COMMON_OP_DEPS ${COMMON_OP_DEPS} dynload_warpctc static_prim_api static_utils static_global_utils prim_utils)
114+
set(COMMON_OP_DEPS ${COMMON_OP_DEPS} static_prim_api static_utils static_global_utils prim_utils)
115115
set(COMMON_OP_DEPS ${COMMON_OP_DEPS} box_wrapper ps_gpu_wrapper)
116116
set(COMMON_OP_DEPS ${COMMON_OP_DEPS} processgroup_comm_utils)
117117
if(WITH_NCCL OR WITH_RCCL)

paddle/fluid/platform/CMakeLists.txt

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ else()
4444
endif()
4545

4646
add_subdirectory(device)
47-
add_subdirectory(dynload)
4847

4948
cc_library(
5049
cpu_helper
@@ -61,11 +60,11 @@ if(WITH_DGC)
6160
endif()
6261

6362
if(WITH_GPU OR WITH_ROCM)
64-
set(GPU_CTX_DEPS dynload_cuda dynamic_loader)
63+
set(GPU_CTX_DEPS phi common)
6564
endif()
6665

6766
if(WITH_XPU)
68-
set(XPU_CTX_DEPS dynload_xpti dynamic_loader)
67+
set(XPU_CTX_DEPS phi common)
6968
endif()
7069

7170
if(WITH_IPU)
@@ -258,13 +257,7 @@ if(WITH_GPU)
258257
nv_library(
259258
profiler
260259
SRCS profiler.cc profiler.cu
261-
DEPS phi
262-
common
263-
gpu_info
264-
enforce
265-
dynload_cuda
266-
op_proto_maker
267-
shape_inference)
260+
DEPS phi common gpu_info enforce op_proto_maker shape_inference)
268261
elseif(WITH_ROCM)
269262
hip_library(
270263
profiler
@@ -274,7 +267,7 @@ elseif(WITH_XPU)
274267
cc_library(
275268
profiler
276269
SRCS profiler.cc
277-
DEPS phi common enforce dynload_xpti op_proto_maker shape_inference)
270+
DEPS phi common enforce op_proto_maker shape_inference)
278271
else()
279272
cc_library(
280273
profiler

paddle/fluid/platform/device/gpu/CMakeLists.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,25 +3,25 @@ if(WITH_GPU)
33
nv_library(
44
gpu_info
55
SRCS gpu_info.cc
6-
DEPS phi common glog enforce monitor dynload_cuda)
6+
DEPS phi common glog enforce monitor)
77

88
nv_test(cuda_helper_test SRCS cuda_helper_test.cu)
99
nv_test(
1010
cudnn_desc_test
1111
SRCS cudnn_desc_test.cc
12-
DEPS dynload_cuda)
12+
DEPS phi common)
1313
elseif(WITH_ROCM)
1414
add_subdirectory(rocm)
1515
hip_library(
1616
gpu_info
1717
SRCS gpu_info.cc
18-
DEPS phi common glog enforce monitor dynload_cuda)
18+
DEPS phi common glog enforce monitor)
1919

2020
hip_test(cuda_helper_test SRCS cuda_helper_test.cu)
2121
hip_test(
2222
cudnn_desc_test
2323
SRCS cudnn_desc_test.cc
24-
DEPS dynload_cuda)
24+
DEPS phi common)
2525
endif()
2626

2727
cc_library(

paddle/fluid/platform/device/gpu/cuda/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ nv_library(
66
nv_test(
77
cudnn_helper_test
88
SRCS cudnn_helper_test.cc
9-
DEPS dynload_cuda)
9+
DEPS phi common)
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
hip_test(
22
miopen_helper_test
33
SRCS miopen_helper_test.cc
4-
DEPS dynload_cuda)
4+
DEPS phi common)

paddle/fluid/platform/device/xpu/CMakeLists.txt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,7 @@ cc_library(
1919
xpulib
2020
device_context
2121
phi
22-
common
23-
dynload_xpti)
22+
common)
2423
cc_library(
2524
xpu_op_list
2625
SRCS xpu_op_list.cc
@@ -30,8 +29,7 @@ cc_library(
3029
device_context
3130
op_kernel_type
3231
phi
33-
common
34-
dynload_xpti)
32+
common)
3533
cc_library(
3634
xpu_resource_pool
3735
SRCS xpu_resource_pool.cc

paddle/fluid/platform/dynload/CMakeLists.txt

Lines changed: 0 additions & 87 deletions
This file was deleted.

0 commit comments

Comments
 (0)