Skip to content

Commit

Permalink
Merge pull request #975 from steffenlarsen/steffen/increase_fragment_…
Browse files Browse the repository at this point in the history
…size

Increase math builtin test fragment size
  • Loading branch information
bader authored Jan 23, 2025
2 parents 92ac711 + 34c138b commit b842c40
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
11 changes: 11 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,17 @@ if(SYCL_CTS_MEASURE_BUILD_TIMES)
endif()
# ------------------

# ------------------
# Math builtin fragment size option
set(SYCL_CTS_MATH_BUILTIN_FRAGMENT_SIZE "230" CACHE STRING
"Control the size of the fragment files generated for the math builtin tests.\
Decreasing this may help increase the parallelizability of the compilation of\
the math builtin, but may also increase the overall compilation time.")
if(NOT "${SYCL_CTS_MATH_BUILTIN_FRAGMENT_SIZE}" MATCHES "^[1-9][0-9]*$")
message(FATAL_ERROR "SYCL_CTS_MATH_BUILTIN_FRAGMENT_SIZE (${SYCL_CTS_MATH_BUILTIN_FRAGMENT_SIZE}) must be an integer greater than 0.")
endif()
# ------------------

enable_testing()

add_subdirectory(util)
Expand Down
4 changes: 2 additions & 2 deletions tests/math_builtin_api/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ foreach(cat ${MATH_CAT_WITH_VARIANT})
FILE_PREFIX "math_builtin_${cat}_${var}"
EXT "cpp"
INPUT "math_builtin.template"
EXTRA_ARGS -test ${cat} -variante ${var} -marray true -fragment-size 150
EXTRA_ARGS -test ${cat} -variante ${var} -marray true -fragment-size ${SYCL_CTS_MATH_BUILTIN_FRAGMENT_SIZE}
DEPENDS ${math_builtin_depends}
)
endforeach()
Expand All @@ -44,7 +44,7 @@ foreach(cat ${MATH_CAT})
FILE_PREFIX "math_builtin_${cat}"
EXT "cpp"
INPUT "math_builtin.template"
EXTRA_ARGS -test ${cat} -marray true -fragment-size 150
EXTRA_ARGS -test ${cat} -marray true -fragment-size ${SYCL_CTS_MATH_BUILTIN_FRAGMENT_SIZE}
DEPENDS ${math_builtin_depends}
)
endforeach()
Expand Down

0 comments on commit b842c40

Please sign in to comment.