Skip to content

Commit

Permalink
Update to CCCL 2.2.0. (#1404)
Browse files Browse the repository at this point in the history
This PR updates RMM to CCCL 2.2.0. Do not merge until all of RAPIDS is ready to update.

Depends on rapidsai/rapids-cmake#495.

Replaces #1247.

Authors:
  - Bradley Dice (https://github.com/bdice)
  - Vyas Ramasubramani (https://github.com/vyasr)

Approvers:
  - Mark Harris (https://github.com/harrism)
  - Vyas Ramasubramani (https://github.com/vyasr)

URL: #1404
  • Loading branch information
bdice committed Dec 19, 2023
1 parent 77b5500 commit a4dd4f5
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 48 deletions.
21 changes: 5 additions & 16 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,7 @@ rapids_cpm_init()

include(cmake/thirdparty/get_fmt.cmake)
include(cmake/thirdparty/get_spdlog.cmake)
include(cmake/thirdparty/get_libcudacxx.cmake)
include(cmake/thirdparty/get_thrust.cmake)
include(cmake/thirdparty/get_cccl.cmake)

# ##################################################################################################
# * library targets --------------------------------------------------------------------------------
Expand All @@ -90,8 +89,7 @@ else()
target_link_libraries(rmm INTERFACE CUDA::cudart)
endif()

target_link_libraries(rmm INTERFACE libcudacxx::libcudacxx)
target_link_libraries(rmm INTERFACE rmm::Thrust)
target_link_libraries(rmm INTERFACE CCCL::CCCL)
target_link_libraries(rmm INTERFACE fmt::fmt-header-only)
target_link_libraries(rmm INTERFACE spdlog::spdlog_header_only)
target_link_libraries(rmm INTERFACE dl)
Expand Down Expand Up @@ -152,20 +150,12 @@ The goal of the [RMM](https://github.com/rapidsai/rmm) is to provide:
A collection of data structures that use the interface for memory allocation
]=])

set(code_string
[=[
if(NOT TARGET rmm::Thrust)
thrust_create_target(rmm::Thrust FROM_OPTIONS)
endif()
]=])

rapids_export(
INSTALL rmm
EXPORT_SET rmm-exports
GLOBAL_TARGETS rmm
NAMESPACE rmm::
DOCUMENTATION doc_string
FINAL_CODE_BLOCK code_string)
DOCUMENTATION doc_string)

# ##################################################################################################
# * build export -----------------------------------------------------------------------------------
Expand All @@ -175,8 +165,7 @@ rapids_export(
EXPORT_SET rmm-exports
GLOBAL_TARGETS rmm
NAMESPACE rmm::
DOCUMENTATION doc_string
FINAL_CODE_BLOCK code_string)
DOCUMENTATION doc_string)

# ##################################################################################################
# * make documentation -----------------------------------------------------------------------------
Expand All @@ -197,6 +186,6 @@ add_custom_target(
# * make gdb helper scripts ------------------------------------------------------------------------

# optionally assemble Thrust pretty-printers
if(Thrust_SOURCE_DIR)
if(CCCL_SOURCE_DIR)
configure_file(scripts/load-pretty-printers.in load-pretty-printers @ONLY)
endif()
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
# the License.
# =============================================================================

# Use CPM to find or clone libcudacxx
function(find_and_configure_libcudacxx)
# Use CPM to find or clone CCCL
function(find_and_configure_cccl)

include(${rapids-cmake-dir}/cpm/libcudacxx.cmake)
rapids_cpm_libcudacxx(BUILD_EXPORT_SET rmm-exports INSTALL_EXPORT_SET rmm-exports)
include(${rapids-cmake-dir}/cpm/cccl.cmake)
rapids_cpm_cccl(BUILD_EXPORT_SET rmm-exports INSTALL_EXPORT_SET rmm-exports)

endfunction()

find_and_configure_libcudacxx()
find_and_configure_cccl()
26 changes: 0 additions & 26 deletions cmake/thirdparty/get_thrust.cmake

This file was deleted.

2 changes: 1 addition & 1 deletion scripts/load-pretty-printers.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
source @Thrust_SOURCE_DIR@/scripts/gdb-pretty-printers.py
source @CCCL_SOURCE_DIR@/thrust/scripts/gdb-pretty-printers.py
source @PROJECT_SOURCE_DIR@/scripts/gdb-pretty-printers.py

0 comments on commit a4dd4f5

Please sign in to comment.