Warning, /acts/Traccc/device/alpaka/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 # TRACCC library, part of the ACTS project (R&D line)
0002 #
0003 # (c) 2023-2026 CERN for the benefit of the ACTS project
0004 #
0005 # Mozilla Public License Version 2.0
0006
0007 # Project include(s).
0008 include(traccc-alpaka-functions)
0009 include(traccc-compiler-options-cpp)
0010
0011 set(PUBLIC_LIBRARIES
0012 traccc::core
0013 traccc::device_common
0014 vecmem::core
0015 covfie::core
0016 )
0017 set(PRIVATE_LIBRARIES alpaka::alpaka)
0018
0019 traccc_enable_language_alpaka()
0020
0021 if(alpaka_ACC_GPU_CUDA_ENABLE)
0022 list(
0023 APPEND PRIVATE_LIBRARIES
0024 CUDA::cudart
0025 vecmem::cuda
0026 traccc::cuda_utils
0027 covfie::cuda
0028 )
0029 elseif(alpaka_ACC_GPU_HIP_ENABLE)
0030 find_package(HIPToolkit REQUIRED)
0031 list(APPEND PRIVATE_LIBRARIES HIP::hiprt vecmem::hip covfie::hip)
0032 elseif(alpaka_ACC_SYCL_ENABLE)
0033 include(traccc-compiler-options-sycl)
0034 list(APPEND PRIVATE_LIBRARIES vecmem::sycl traccc::sycl_utils covfie::sycl)
0035 endif()
0036
0037 traccc_add_alpaka_library( traccc_alpaka alpaka TYPE SHARED
0038 # Utility definitions.
0039 "include/traccc/alpaka/utils/algorithm_base.hpp"
0040 "src/utils/algorithm_base.cpp"
0041 "include/traccc/alpaka/utils/get_device_info.hpp"
0042 "include/traccc/alpaka/utils/make_magnetic_field.hpp"
0043 "src/utils/make_magnetic_field.cpp"
0044 "src/utils/get_device_info.cpp"
0045 "include/traccc/alpaka/utils/queue.hpp"
0046 "src/utils/queue.cpp"
0047 "src/utils/get_queue.hpp"
0048 "src/utils/get_queue.cpp"
0049 "include/traccc/alpaka/utils/vecmem_objects.hpp"
0050 "src/utils/vecmem_objects.cpp"
0051 "src/utils/oneDPL.hpp"
0052 "src/utils/parallel_algorithms.hpp"
0053 # Clusterization
0054 "include/traccc/alpaka/clusterization/clusterization_algorithm.hpp"
0055 "src/clusterization/clusterization_algorithm.cpp"
0056 "include/traccc/alpaka/clusterization/measurement_sorting_algorithm.hpp"
0057 "src/clusterization/measurement_sorting_algorithm.cpp"
0058 # Seeding code
0059 "include/traccc/alpaka/seeding/silicon_pixel_spacepoint_formation_algorithm.hpp"
0060 "src/seeding/silicon_pixel_spacepoint_formation_algorithm.cpp"
0061 "include/traccc/alpaka/seeding/triplet_seeding_algorithm.hpp"
0062 "src/seeding/triplet_seeding_algorithm.cpp"
0063 "include/traccc/alpaka/seeding/seed_parameter_estimation_algorithm.hpp"
0064 "src/seeding/seed_parameter_estimation_algorithm.cpp"
0065 # GBTS seeding code
0066 "include/traccc/alpaka/gbts_seeding/gbts_seeding_algorithm.hpp"
0067 "src/gbts_seeding/gbts_seeding_algorithm.cpp"
0068 # Track finding algorithm(s).
0069 "include/traccc/alpaka/finding/combinatorial_kalman_filter_algorithm.hpp"
0070 "src/finding/combinatorial_kalman_filter_algorithm.cpp"
0071 # Track fitting algorithm(s).
0072 "include/traccc/alpaka/fitting/kalman_fitting_algorithm.hpp"
0073 "src/fitting/kalman_fitting_algorithm.cpp"
0074 )
0075
0076 # Set up Thrust specifically for the traccc::alpaka library.
0077 if(alpaka_ACC_GPU_CUDA_ENABLE)
0078 thrust_create_target(traccc::cuda_thrust
0079 HOST CPP
0080 DEVICE CUDA
0081 )
0082 target_link_libraries(traccc::cuda_thrust INTERFACE CUDA::cudart)
0083 list(APPEND PRIVATE_LIBRARIES traccc::cuda_thrust)
0084 elseif(alpaka_ACC_GPU_HIP_ENABLE)
0085 list(APPEND PRIVATE_LIBRARIES roc::rocthrust)
0086 else()
0087 thrust_create_target(traccc::alpaka_thrust
0088 HOST CPP
0089 DEVICE CPP
0090 )
0091 list(APPEND PRIVATE_LIBRARIES traccc::alpaka_thrust)
0092 endif()
0093
0094 target_link_libraries(
0095 traccc_alpaka
0096 PUBLIC ${PUBLIC_LIBRARIES}
0097 PRIVATE ${PRIVATE_LIBRARIES}
0098 )