[libc-commits] [PATCH] D154864: [libc] Fix using the `libcgpu.a` for NVPTX in non-LTO builds
Joseph Huber via Phabricator via libc-commits
libc-commits at lists.llvm.org
Mon Jul 10 11:55:04 PDT 2023
This revision was automatically updated to reflect the committed changes.
Closed by commit rGa4f553fcde75: [libc] Fix using the `libcgpu.a` for NVPTX in non-LTO builds (authored by jhuber6).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D154864/new/
https://reviews.llvm.org/D154864
Files:
libc/cmake/modules/LLVMLibCObjectRules.cmake
Index: libc/cmake/modules/LLVMLibCObjectRules.cmake
===================================================================
--- libc/cmake/modules/LLVMLibCObjectRules.cmake
+++ libc/cmake/modules/LLVMLibCObjectRules.cmake
@@ -184,8 +184,14 @@
# Append this target to a list of images to package into a single binary.
set(input_file $<TARGET_OBJECTS:${gpu_target_name}>)
- list(APPEND packager_images
- --image=file=${input_file},arch=${gpu_arch},triple=${gpu_target_triple})
+ if("${gpu_arch}" IN_LIST all_nvptx_architectures)
+ string(REGEX MATCH "\\+ptx[0-9]+" nvptx_ptx_feature ${nvptx_options})
+ list(APPEND packager_images
+ --image=file=${input_file},arch=${gpu_arch},triple=${gpu_target_triple},feature=${nvptx_ptx_feature})
+ else()
+ list(APPEND packager_images
+ --image=file=${input_file},arch=${gpu_arch},triple=${gpu_target_triple})
+ endif()
list(APPEND gpu_target_names ${gpu_target_name})
endforeach()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D154864.538757.patch
Type: text/x-patch
Size: 1021 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230710/9aeac491/attachment.bin>
More information about the libc-commits
mailing list