SWDEV-464648 - code and comment cleanups

Change-Id: I10b462078fa9eed73372d81dff92d7278731f736
This commit is contained in:
Ioannis Assiouras
2024-06-01 22:23:10 +01:00
committed by Maneesh Gupta
parent aee4042e09
commit 38f67d4a0b
14 changed files with 39 additions and 59 deletions
+8 -8
View File
@@ -53,8 +53,8 @@ set(TEST_SRC
hipMipmappedArrayGetLevel.cc
)
# tests not for MI200+
set(NOT_FOR_MI200_AND_ABOVE_TEST
# tests not for gfx90a+
set(NOT_FOR_gfx90a_AND_ABOVE_TEST
tex1Dfetch.cc
tex1D.cc
tex1DLayered.cc
@@ -82,14 +82,14 @@ set(NOT_FOR_MI200_AND_ABOVE_TEST
tex3DLod.cc
tex3DGrad.cc
)
set(MI200_AND_ABOVE_TARGETS gfx90a gfx940 gfx941 gfx942)
set(gfx90a_AND_ABOVE_TARGETS gfx90a gfx940 gfx941 gfx942)
function(CheckRejectedArchs OFFLOAD_ARCH_STR_LOCAL)
set(ARCH_CHECK -1 PARENT_SCOPE)
string(REGEX MATCHALL "--offload-arch=gfx[0-9a-z]+" OFFLOAD_ARCH_LIST ${OFFLOAD_ARCH_STR_LOCAL})
foreach(OFFLOAD_ARCH IN LISTS OFFLOAD_ARCH_LIST)
string(REGEX MATCHALL "--offload-arch=(gfx[0-9a-z]+)" matches ${OFFLOAD_ARCH})
if (CMAKE_MATCH_COUNT EQUAL 1)
if (CMAKE_MATCH_1 IN_LIST MI200_AND_ABOVE_TARGETS)
if (CMAKE_MATCH_1 IN_LIST gfx90a_AND_ABOVE_TARGETS)
set(ARCH_CHECK 1 PARENT_SCOPE)
endif() # CMAKE_MATCH_1
endif() # CMAKE_MATCH_COUNT
@@ -105,13 +105,13 @@ if(HIP_PLATFORM MATCHES "amd")
set(ARCH_CHECK -1)
endif()
if(${ARCH_CHECK} EQUAL -1)
message(STATUS "Adding test: ${NOT_FOR_MI200_AND_ABOVE_TEST}")
set(TEST_SRC ${TEST_SRC} ${NOT_FOR_MI200_AND_ABOVE_TEST})
message(STATUS "Adding test: ${NOT_FOR_gfx90a_AND_ABOVE_TEST}")
set(TEST_SRC ${TEST_SRC} ${NOT_FOR_gfx90a_AND_ABOVE_TEST})
else()
message(STATUS "Removing test: ${NOT_FOR_MI200_AND_ABOVE_TEST}")
message(STATUS "Removing test: ${NOT_FOR_gfx90a_AND_ABOVE_TEST}")
endif()
else()
set(TEST_SRC ${TEST_SRC} ${NOT_FOR_MI200_AND_ABOVE_TEST})
set(TEST_SRC ${TEST_SRC} ${NOT_FOR_gfx90a_AND_ABOVE_TEST})
endif()
if(WIN32)