Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/PaddlePaddle/Paddle into…
Browse files Browse the repository at this point in the history
… nested-namespace-part-10
  • Loading branch information
walkalone20 committed Jul 2, 2024
2 parents 15f2ef8 + d5d5c17 commit dae9d19
Show file tree
Hide file tree
Showing 1,198 changed files with 29,191 additions and 42,374 deletions.
3 changes: 2 additions & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# Code owners are expected to take responsibility for review patches to respective file.

/CMakeLists.txt @wanghuancoder @Aurelius84 @XiaoguangHu01 @qili93
paddle/fluid/distributed/collective @sneaxiy @ForFishes
paddle/fluid/eager/autograd_meta.cc @JiabinYang @phlrain
paddle/fluid/eager/autograd_meta.h @JiabinYang @phlrain
paddle/fluid/eager/backward.cc @JiabinYang @phlrain
Expand Down Expand Up @@ -46,7 +47,7 @@ paddle/phi/infermeta/spmd_rules @LiYuRio @ForFishes @zhiqiu
paddle/scripts/paddle_build.bat @zhwesky2010 @wanghuancoder @Aurelius84
paddle/scripts/paddle_build.sh @risemeup1 @zhangbo9674 @XieYunshen
pyproject.toml @SigureMo @gouzil
python/paddle/autograd/backward_utils.py @Aurelius84 @cxxly @xiaoguoguo626807 @changeyoung98
python/paddle/autograd/backward_utils.py @Aurelius84 @cxxly @xiaoguoguo626807 @changeyoung98 @cyber-pioneer
python/paddle/autograd/ir_backward.py @Aurelius84 @cxxly @xiaoguoguo626807 @changeyoung98
python/paddle/base/backward.py @XiaoguangHu01 @zhiqiu @Xreki @qili93 @Aurelius84
python/paddle/base/compiler.py @XiaoguangHu01 @zhiqiu @Xreki @qili93 @Aurelius84
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ repos:
hooks:
- id: black
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.3.5
rev: v0.5.0
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix, --no-cache]
Expand Down
12 changes: 5 additions & 7 deletions cmake/cinn.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,11 @@ if(WITH_GPU)
/usr/lib /usr/lib64 REQUIRED)
endif()

if(WITH_ROCM)
message(STATUS "CINN Compile with ROCM support")
add_definitions(-DCINN_WITH_HIP)
endif()

set(cinnapi_src CACHE INTERNAL "" FORCE)
set(core_src CACHE INTERNAL "" FORCE)
set(core_includes CACHE INTERNAL "" FORCE)
Expand Down Expand Up @@ -307,13 +312,6 @@ if(PUBLISH_LIBS)
add_custom_command(
TARGET cinncore_static
POST_BUILD
COMMAND
cmake -E copy ${PROJECT_SOURCE_DIR}/tools/cinn/tutorials_demo/demo.cc
${CMAKE_BINARY_DIR}/dist/demo.cc
COMMAND
cmake -E copy
${PROJECT_SOURCE_DIR}/tools/cinn/tutorials_demo/build_demo.sh
${CMAKE_BINARY_DIR}/dist/build_demo.sh
COMMAND cmake -E copy ${CMAKE_BINARY_DIR}/libcinncore_static.a
${CMAKE_BINARY_DIR}/dist/cinn/lib/libcinncore_static.a
COMMAND
Expand Down
4 changes: 2 additions & 2 deletions cmake/external/cudnn-frontend.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ endif()

if((NOT DEFINED CUDNN_FRONTEND_NAME) OR (NOT DEFINED CUDNN_FRONTEND_URL))
set(CUDNN_FRONTEND_VER
"v0.9.1"
"v1.2.0"
CACHE STRING "" FORCE)
set(CUDNN_FRONTEND_NAME
"cudnn-frontend"
Expand All @@ -38,7 +38,7 @@ if((NOT DEFINED CUDNN_FRONTEND_NAME) OR (NOT DEFINED CUDNN_FRONTEND_URL))
CACHE STRING "" FORCE)
endif()
set(CUDNN_FRONTEND_CACHE_FILENAME "${CUDNN_FRONTEND_VER}.tar.gz")
set(CUDNN_FRONTEND_URL_MD5 "da7cbad1305427f687dd4fd737178f80")
set(CUDNN_FRONTEND_URL_MD5 "35e27c098f536c8064665fb8dfc4f368")

message(
STATUS
Expand Down
21 changes: 12 additions & 9 deletions cmake/external/xpu.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ if(NOT DEFINED XPU_XRE_BASE_VERSION)
set(XPU_XRE_BASE_VERSION "4.32.0.1")
endif()
if(NOT DEFINED XPU_XHPC_BASE_DATE)
set(XPU_XHPC_BASE_DATE "20240601")
set(XPU_XHPC_BASE_DATE "20240626")
endif()
set(XPU_XCCL_BASE_VERSION "1.2.1.2")
if(NOT DEFINED XPU_XFT_BASE_VERSION)
Expand All @@ -52,9 +52,12 @@ if(NOT XPU_XFT_BASE_URL)
)
endif()

set(XPU_XPTI_BASE_URL
"https://klx-sdk-release-public.su.bcebos.com/xpti/dev/${XPU_XPTI_BASE_VERSION}"
)
if(WITH_XPTI)
set(XPU_XPTI_BASE_URL
"https://klx-sdk-release-public.su.bcebos.com/xpti/dev/${XPU_XPTI_BASE_VERSION}"
)
set(XPU_XPTI_DIR_NAME "xpti")
endif()

if(WITH_XPU_XRE5)
set(XPU_XRE_BASE_VERSION "5.0.3.1")
Expand Down Expand Up @@ -102,7 +105,6 @@ else()
set(XPU_XCCL_DIR_NAME "${XPU_XCCL_PREFIX}-ubuntu_x86_64")
set(XPU_XFT_DIR_NAME "xft_ubuntu1604_x86_64")
endif()
set(XPU_XPTI_DIR_NAME "xpti")

set(XPU_XRE_URL
"${XPU_XRE_BASE_URL}/${XPU_XRE_DIR_NAME}.tar.gz"
Expand All @@ -111,13 +113,14 @@ set(XPU_XCCL_URL
"${XPU_XCCL_BASE_URL}/${XPU_XCCL_DIR_NAME}.tar.gz"
CACHE STRING "" FORCE)
set(XPU_XFT_URL "${XPU_XFT_BASE_URL}/${XPU_XFT_DIR_NAME}.tar.gz")
set(XPU_XPTI_URL
"${XPU_XPTI_BASE_URL}/${XPU_XPTI_DIR_NAME}.tar.gz"
CACHE STRING "" FORCE)
set(XPU_XFT_GET_DEPENCE_URL
"https://baidu-kunlun-public.su.bcebos.com/paddle_depence/get_xft_dependence.sh"
CACHE STRING "" FORCE)

if(WITH_XPTI)
set(XPU_XPTI_URL "${XPU_XPTI_BASE_URL}/${XPU_XPTI_DIR_NAME}.tar.gz")
endif()

set(XPU_XHPC_URL
"https://klx-sdk-release-public.su.bcebos.com/xhpc/dev/${XPU_XHPC_BASE_DATE}/${XPU_XHPC_DIR_NAME}.tar.gz"
CACHE STRING "" FORCE)
Expand Down Expand Up @@ -168,7 +171,7 @@ ExternalProject_Add(
${XPU_XRE_DIR_NAME} ${XPU_XHPC_URL} ${XPU_XHPC_DIR_NAME} ${XPU_XCCL_URL}
${XPU_XCCL_DIR_NAME} ${XPU_XHPC_URL} ${XPU_XHPC_DIR_NAME} && wget
${XPU_XFT_GET_DEPENCE_URL} && bash get_xft_dependence.sh ${XPU_XFT_URL}
${XPU_XFT_DIR_NAME} && WITH_XPTI=${WITH_XPTI} bash
${XPU_XFT_DIR_NAME} && bash
${CMAKE_SOURCE_DIR}/tools/xpu/get_xpti_dependence.sh ${XPU_XPTI_URL}
${XPU_XPTI_DIR_NAME}
DOWNLOAD_NO_PROGRESS 1
Expand Down
28 changes: 0 additions & 28 deletions cmake/generic.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
# C++ CUDA C++ Go
# -------------------------------------------
# cc_library nv_library go_library
# cc_binary nv_binary go_binary
# cc_test nv_test go_test
# -------------------------------------------
#
Expand Down Expand Up @@ -52,11 +51,6 @@
#
# cc_library(composed DEPS dependent1 dependent2 dependent3)
#
# To build an executable binary file from some source files and
# dependent libraries:
#
# cc_binary(example SRCS main.cc something.cc DEPS example1 example2)
#
# To build an executable binary file using NVCC, use the nv_ prefixed
# version:
#
Expand Down Expand Up @@ -436,28 +430,6 @@ function(cc_library TARGET_NAME)
endif()
endfunction()

function(cc_binary TARGET_NAME)
set(options "")
set(oneValueArgs "")
set(multiValueArgs SRCS DEPS)
cmake_parse_arguments(cc_binary "${options}" "${oneValueArgs}"
"${multiValueArgs}" ${ARGN})
add_executable(${TARGET_NAME} ${cc_binary_SRCS})
if(cc_binary_DEPS)
target_link_libraries(${TARGET_NAME} ${cc_binary_DEPS})
add_dependencies(${TARGET_NAME} ${cc_binary_DEPS})
common_link(${TARGET_NAME})
endif()
get_property(os_dependency_modules GLOBAL PROPERTY OS_DEPENDENCY_MODULES)
target_link_libraries(${TARGET_NAME} ${os_dependency_modules})
if(WITH_ROCM)
target_link_libraries(${TARGET_NAME} ${ROCM_HIPRTC_LIB})
endif()

check_coverage_opt(${TARGET_NAME} ${cc_binary_SRCS})

endfunction()

function(cc_test_build TARGET_NAME)
if(WITH_TESTING)
set(oneValueArgs "")
Expand Down
8 changes: 3 additions & 5 deletions cmake/operators.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ function(register_cu_kernel TARGET)
"${multiValueArgs}" ${ARGN})

set(cu_srcs)
set(op_common_deps operator op_registry layer common_infer_shape_functions)
set(op_common_deps operator op_registry layer)
foreach(cu_src ${register_cu_kernel_SRCS})
if(${cu_src} MATCHES ".*\\.cu$")
list(APPEND cu_srcs ${cu_src})
Expand Down Expand Up @@ -112,8 +112,7 @@ function(register_onednn_kernel TARGET)
"${multiValueArgs}" ${ARGN})

set(onednn_cc_srcs)
set(op_common_deps operator op_registry phi layer
common_infer_shape_functions)
set(op_common_deps operator op_registry phi layer)
foreach(onednn_src ${register_onednn_kernel_SRCS})
if(${onednn_src} MATCHES ".*_onednn_op.cc$")
list(APPEND onednn_cc_srcs onednn/${onednn_src})
Expand Down Expand Up @@ -163,8 +162,7 @@ function(op_library TARGET)
set(MIOPEN_FILE)
set(onednn_cc_srcs)
set(ONEDNN_FILE)
set(op_common_deps operator op_registry phi layer
common_infer_shape_functions)
set(op_common_deps operator op_registry phi layer)

# Option `UNITY` is used to specify that operator `TARGET` will compiles with Unity Build.
set(options UNITY)
Expand Down
1 change: 0 additions & 1 deletion paddle/cinn/ast_gen_ius/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,4 @@ core_gather_headers()

gather_srcs(cinnapi_src SRCS ast_gen.cc tensor_group.cc)

cinn_cc_test(test_ast_gen_ius SRCS ast_gen_test.cc DEPS cinncore)
cinn_cc_test(test_tensor_group SRCS tensor_group_test.cc DEPS cinncore)
Loading

0 comments on commit dae9d19

Please sign in to comment.