未验证 提交 5c1631f2 编写于 作者: N niuliling123 提交者: GitHub

Add -rf in xpu_kp.cmake when cp .kps to .xpu (#41059)

上级 4e86dff2
...@@ -128,7 +128,7 @@ macro(compile_kernel COMPILE_ARGS) ...@@ -128,7 +128,7 @@ macro(compile_kernel COMPILE_ARGS)
COMMAND COMMAND
${CMAKE_COMMAND} -E make_directory kernel_build ${CMAKE_COMMAND} -E make_directory kernel_build
COMMAND COMMAND
cp ${kernel_path}/${kernel_name}.kps kernel_build/${kernel_name}.xpu cp ${kernel_path}/${kernel_name}.kps kernel_build/${kernel_name}.xpu -rf
COMMAND COMMAND
${XPU_CLANG} --sysroot=${CXX_DIR} -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=1 ${OPT_LEVEL} -fno-builtin -mcpu=xpu2 -fPIC ${XPU_CXX_DEFINES} ${XPU_CXX_FLAGS} ${XPU_CXX_INCLUDES} ${XPU_CLANG} --sysroot=${CXX_DIR} -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=1 ${OPT_LEVEL} -fno-builtin -mcpu=xpu2 -fPIC ${XPU_CXX_DEFINES} ${XPU_CXX_FLAGS} ${XPU_CXX_INCLUDES}
-I. -o kernel_build/${kernel_name}.bin.o.sec kernel_build/${kernel_name}.xpu -I. -o kernel_build/${kernel_name}.bin.o.sec kernel_build/${kernel_name}.xpu
...@@ -151,7 +151,7 @@ macro(compile_kernel COMPILE_ARGS) ...@@ -151,7 +151,7 @@ macro(compile_kernel COMPILE_ARGS)
COMMAND COMMAND
${CMAKE_COMMAND} -E make_directory kernel_build ${CMAKE_COMMAND} -E make_directory kernel_build
COMMAND COMMAND
cp ${kernel_path}/${kernel_name}.kps kernel_build/${kernel_name}.xpu cp ${kernel_path}/${kernel_name}.kps kernel_build/${kernel_name}.xpu -rf
COMMAND COMMAND
${XPU_CLANG} --sysroot=${CXX_DIR} -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=1 ${OPT_LEVEL} -fno-builtin -mcpu=xpu2 -fPIC ${XPU_CXX_DEFINES} ${XPU_CXX_FLAGS} ${XPU_CXX_INCLUDES} ${XPU_CLANG} --sysroot=${CXX_DIR} -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=1 ${OPT_LEVEL} -fno-builtin -mcpu=xpu2 -fPIC ${XPU_CXX_DEFINES} ${XPU_CXX_FLAGS} ${XPU_CXX_INCLUDES}
-I. -o kernel_build/${kernel_name}.host.o kernel_build/${kernel_name}.xpu -I. -o kernel_build/${kernel_name}.host.o kernel_build/${kernel_name}.xpu
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册