From a5e9ccda0c0d5eff740bbf8542b6d0f5f3278462 Mon Sep 17 00:00:00 2001 From: danleifeng <52735331+danleifeng@users.noreply.github.com> Date: Fri, 26 Aug 2022 14:04:18 +0800 Subject: [PATCH] fix brpc update compile error; test=develop (#45438) --- paddle/fluid/distributed/collective/CMakeLists.txt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/paddle/fluid/distributed/collective/CMakeLists.txt b/paddle/fluid/distributed/collective/CMakeLists.txt index 02e57700c98..9e2ceb29f2a 100644 --- a/paddle/fluid/distributed/collective/CMakeLists.txt +++ b/paddle/fluid/distributed/collective/CMakeLists.txt @@ -23,9 +23,10 @@ if(WITH_NCCL OR WITH_RCCL) if(WITH_DISTRIBUTE AND WITH_PSCORE) if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 7.0) set(DISTRIBUTE_COMPILE_FLAGS "${DISTRIBUTE_COMPILE_FLAGS} -faligned-new") + set_source_files_properties( + ProcessGroupHeter.cc PROPERTIES COMPILE_FLAGS + ${DISTRIBUTE_COMPILE_FLAGS}) endif() - set_source_files_properties( - ProcessGroupHeter.cc PROPERTIES COMPILE_FLAGS ${DISTRIBUTE_COMPILE_FLAGS}) cc_library( processgroup_heter SRCS ProcessGroupHeter.cc NCCLTools.cc Common.cc @@ -47,9 +48,11 @@ if(WITH_ASCEND_CL) if(WITH_DISTRIBUTE AND WITH_PSCORE) if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 7.0) set(DISTRIBUTE_COMPILE_FLAGS "${DISTRIBUTE_COMPILE_FLAGS} -faligned-new") + set_source_files_properties( + ProcessGroupHeter.cc PROPERTIES COMPILE_FLAGS + ${DISTRIBUTE_COMPILE_FLAGS}) endif() - set_source_files_properties( - ProcessGroupHeter.cc PROPERTIES COMPILE_FLAGS ${DISTRIBUTE_COMPILE_FLAGS}) + cc_library( processgroup_heter SRCS ProcessGroupHeter.cc HCCLTools.cc Common.cc -- GitLab