Files
rocm-systems/tests/catch/unit/deviceLib/CMakeLists.txt
T
cjatin 5cb9a06278 SWDEV-289409 - Batch 2 of device tests
Change-Id: I3976b5565bf040e77196ca797afb3f71f0e81d6c
2021-07-06 02:42:14 -04:00

42 lines
908 B
CMake

# Common Tests - Test independent of all platforms
set(TEST_SRC
floatMath.cc
anyAll.cc
ballot.cc
clz.cc
ffs.cc
funnelshift.cc
brev.cc
popc.cc
ldg.cc
syncthreadsand.cc
syncthreadscount.cc
syncthreadsor.cc
threadfence_system.cc
)
# AMD only tests
set(AMD_TEST_SRC
vectorTypesDevice.cc
mbcnt.cc
bitExtract.cc
bitInsert.cc
floatTM.cc
)
if(HIP_PLATFORM MATCHES "amd")
set(TEST_SRC ${TEST_SRC} ${AMD_TEST_SRC})
set_source_files_properties(floatTM.cc PROPERTIES COMPILE_FLAGS -std=c++17)
endif()
# Create shared lib of all tests
add_library(UnitDeviceTests SHARED EXCLUDE_FROM_ALL ${TEST_SRC})
if(HIP_PLATFORM MATCHES "nvidia")
target_compile_options(UnitDeviceTests PUBLIC --Wno-deprecated-declarations)
endif()
# Add dependency on build_tests to build it on this custom target
add_dependencies(build_tests UnitDeviceTests)