mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
Add ThreadSanitizer option (#2560)
Add the `SANITIZER_THREAD` CMake option which will add the `-fsanitize=thread` flag to the compiler and linker when enabled.
This commit is contained in:
committed by
GitHub
parent
941f7edb95
commit
9abcd0054c
@@ -25,6 +25,12 @@ if(USE_CL_EXPERIMENTAL)
|
||||
add_definitions(-DCL_EXPERIMENTAL)
|
||||
endif(USE_CL_EXPERIMENTAL)
|
||||
|
||||
option(SANITIZER_THREAD "Build with the thread sanitiser" OFF)
|
||||
if (SANITIZER_THREAD)
|
||||
add_compile_options(-fsanitize=thread)
|
||||
add_link_options(-fsanitize=thread)
|
||||
endif (SANITIZER_THREAD)
|
||||
|
||||
#-----------------------------------------------------------
|
||||
# Default Configurable Test Set
|
||||
#-----------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user