[libc-commits] [PATCH] D159296: [libc] Support 'assert.h' on the GPU
Siva Chandra via Phabricator via libc-commits
libc-commits at lists.llvm.org
Thu Aug 31 10:33:42 PDT 2023
sivachandra added inline comments.
================
Comment at: libc/src/assert/CMakeLists.txt:1
+if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
+ add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
----------------
For the sake of consistency with other directories, you should move the generic implementation to a `generic` directory and list only an alias here:
```
if(TARGET libc.src.asser.${LIBC_TARGET_OS}.__assert_fail)
set(assert_fail_dep libc.src.asser.${LIBC_TARGET_OS}.__assert_fail)
else()
set(assert_fail_dep libc.src.assert.generic.__assert_fail)
endif()
add_entrypoint_object(
__assert_fail
ALIAS
DEPENDS
$[assert_fail_dep}
)
```
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D159296/new/
https://reviews.llvm.org/D159296
More information about the libc-commits
mailing list