CTest: Rename CudaMemcheck to CudaSanitizer
This commit is contained in:
parent
c9764c902d
commit
fea49b2df0
@ -1142,19 +1142,19 @@ Additional configuration settings include:
|
||||
* `CTest Script`_ variable: none
|
||||
* :module:`CTest` module variable: ``DRMEMORY_COMMAND_OPTIONS``
|
||||
|
||||
``CudaMemcheckCommand``
|
||||
``CudaSanitizerCommand``
|
||||
Specify a ``MemoryCheckCommand`` that is known to be a command-line
|
||||
compatible with cuda-memcheck or compute-sanitizer.
|
||||
|
||||
* `CTest Script`_ variable: none
|
||||
* :module:`CTest` module variable: ``CUDA_MEMCHECK_COMMAND``
|
||||
* :module:`CTest` module variable: ``CUDA_SANITIZER_COMMAND``
|
||||
|
||||
``CudaMemcheckCommandOptions``
|
||||
Specify command-line options to the ``CudaMemcheckCommand`` tool.
|
||||
``CudaSanitizerCommandOptions``
|
||||
Specify command-line options to the ``CudaSanitizerCommand`` tool.
|
||||
They will be placed prior to the test command line.
|
||||
|
||||
* `CTest Script`_ variable: none
|
||||
* :module:`CTest` module variable: ``CUDA_MEMCHECK_COMMAND_OPTIONS``
|
||||
* :module:`CTest` module variable: ``CUDA_SANITIZER_COMMAND_OPTIONS``
|
||||
|
||||
.. _`CTest Submit Step`:
|
||||
|
||||
|
@ -6,5 +6,5 @@ CTEST_MEMORYCHECK_TYPE
|
||||
Specify the CTest ``MemoryCheckType`` setting
|
||||
in a :manual:`ctest(1)` dashboard client script.
|
||||
Valid values are ``Valgrind``, ``Purify``, ``BoundsChecker``, ``DrMemory``,
|
||||
``CudaMemcheck``, ``ThreadSanitizer``, ``AddressSanitizer``, ``LeakSanitizer``,
|
||||
``CudaSanitizer``, ``ThreadSanitizer``, ``AddressSanitizer``, ``LeakSanitizer``,
|
||||
``MemorySanitizer`` and ``UndefinedBehaviorSanitizer``.
|
||||
|
@ -71,8 +71,8 @@ ValgrindCommand: @VALGRIND_COMMAND@
|
||||
ValgrindCommandOptions: @VALGRIND_COMMAND_OPTIONS@
|
||||
DrMemoryCommand: @DRMEMORY_COMMAND@
|
||||
DrMemoryCommandOptions: @DRMEMORY_COMMAND_OPTIONS@
|
||||
CudaMemcheckCommand: @CUDA_MEMCHECK_COMMAND@
|
||||
CudaMemcheckCommandOptions: @CUDA_MEMCHECK_COMMAND_OPTIONS@
|
||||
CudaSanitizerCommand: @CUDA_SANITIZER_COMMAND@
|
||||
CudaSanitizerCommandOptions: @CUDA_SANITIZER_COMMAND_OPTIONS@
|
||||
MemoryCheckType: @MEMORYCHECK_TYPE@
|
||||
MemoryCheckSanitizerOptions: @MEMORYCHECK_SANITIZER_OPTIONS@
|
||||
MemoryCheckCommand: @MEMORYCHECK_COMMAND@
|
||||
|
@ -326,8 +326,8 @@ void cmCTestMemCheckHandler::GenerateDartOutput(cmXMLWriter& xml)
|
||||
case cmCTestMemCheckHandler::BOUNDS_CHECKER:
|
||||
xml.Attribute("Checker", "BoundsChecker");
|
||||
break;
|
||||
case cmCTestMemCheckHandler::CUDA_MEMCHECK:
|
||||
xml.Attribute("Checker", "CudaMemcheck");
|
||||
case cmCTestMemCheckHandler::CUDA_SANITIZER:
|
||||
xml.Attribute("Checker", "CudaSanitizer");
|
||||
break;
|
||||
case cmCTestMemCheckHandler::ADDRESS_SANITIZER:
|
||||
xml.Attribute("Checker", "AddressSanitizer");
|
||||
@ -470,7 +470,7 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::BOUNDS_CHECKER;
|
||||
} else if (testerName.find("cuda-memcheck") != std::string::npos ||
|
||||
testerName.find("compute-sanitizer") != std::string::npos) {
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::CUDA_MEMCHECK;
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::CUDA_SANITIZER;
|
||||
} else {
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::UNKNOWN;
|
||||
}
|
||||
@ -492,10 +492,10 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
|
||||
this->CTest->GetCTestConfiguration("BoundsCheckerCommand");
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::BOUNDS_CHECKER;
|
||||
} else if (cmSystemTools::FileExists(
|
||||
this->CTest->GetCTestConfiguration("CudaMemcheckCommand"))) {
|
||||
this->CTest->GetCTestConfiguration("CudaSanitizerCommand"))) {
|
||||
this->MemoryTester =
|
||||
this->CTest->GetCTestConfiguration("CudaMemcheckCommand");
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::CUDA_MEMCHECK;
|
||||
this->CTest->GetCTestConfiguration("CudaSanitizerCommand");
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::CUDA_SANITIZER;
|
||||
}
|
||||
if (this->CTest->GetCTestConfiguration("MemoryCheckType") ==
|
||||
"AddressSanitizer") {
|
||||
@ -539,8 +539,8 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::VALGRIND;
|
||||
} else if (checkType == "DrMemory") {
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::DRMEMORY;
|
||||
} else if (checkType == "CudaMemcheck") {
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::CUDA_MEMCHECK;
|
||||
} else if (checkType == "CudaSanitizer") {
|
||||
this->MemoryTesterStyle = cmCTestMemCheckHandler::CUDA_SANITIZER;
|
||||
}
|
||||
}
|
||||
if (this->MemoryTester.empty()) {
|
||||
@ -566,10 +566,10 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
|
||||
.empty()) {
|
||||
memoryTesterOptions =
|
||||
this->CTest->GetCTestConfiguration("DrMemoryCommandOptions");
|
||||
} else if (!this->CTest->GetCTestConfiguration("CudaMemcheckCommandOptions")
|
||||
} else if (!this->CTest->GetCTestConfiguration("CudaSanitizerCommandOptions")
|
||||
.empty()) {
|
||||
memoryTesterOptions =
|
||||
this->CTest->GetCTestConfiguration("CudaMemcheckCommandOptions");
|
||||
this->CTest->GetCTestConfiguration("CudaSanitizerCommandOptions");
|
||||
}
|
||||
this->MemoryTesterOptions =
|
||||
cmSystemTools::ParseArguments(memoryTesterOptions);
|
||||
@ -703,8 +703,8 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
|
||||
this->MemoryTesterOptions.emplace_back("/M");
|
||||
break;
|
||||
}
|
||||
case cmCTestMemCheckHandler::CUDA_MEMCHECK: {
|
||||
// cuda-memcheck separates flags from arguments by spaces
|
||||
case cmCTestMemCheckHandler::CUDA_SANITIZER: {
|
||||
// cuda sanitizer separates flags from arguments by spaces
|
||||
if (this->MemoryTesterOptions.empty()) {
|
||||
this->MemoryTesterOptions.emplace_back("--tool");
|
||||
this->MemoryTesterOptions.emplace_back("memcheck");
|
||||
@ -800,7 +800,7 @@ bool cmCTestMemCheckHandler::ProcessMemCheckOutput(const std::string& str,
|
||||
return this->ProcessMemCheckSanitizerOutput(str, log, results);
|
||||
case cmCTestMemCheckHandler::BOUNDS_CHECKER:
|
||||
return this->ProcessMemCheckBoundsCheckerOutput(str, log, results);
|
||||
case cmCTestMemCheckHandler::CUDA_MEMCHECK:
|
||||
case cmCTestMemCheckHandler::CUDA_SANITIZER:
|
||||
return this->ProcessMemCheckCudaOutput(str, log, results);
|
||||
default:
|
||||
log.append("\nMemory checking style used was: ");
|
||||
@ -1188,7 +1188,7 @@ bool cmCTestMemCheckHandler::ProcessMemCheckCudaOutput(
|
||||
|
||||
if (memcheckLine.find(lines[cc])) {
|
||||
cmCTestOptionalLog(this->CTest, DEBUG,
|
||||
"cuda-memcheck line " << lines[cc] << std::endl,
|
||||
"cuda sanitizer line " << lines[cc] << std::endl,
|
||||
this->Quiet);
|
||||
int failure = -1;
|
||||
auto& line = lines[cc];
|
||||
@ -1219,7 +1219,7 @@ bool cmCTestMemCheckHandler::ProcessMemCheckCudaOutput(
|
||||
nonMemcheckOutput.push_back(cc);
|
||||
}
|
||||
}
|
||||
// Now put all all the non cuda-memcheck output into the test output
|
||||
// Now put all all the non cuda sanitizer output into the test output
|
||||
// This should be last in case it gets truncated by the output
|
||||
// limiting code
|
||||
for (std::string::size_type i : nonMemcheckOutput) {
|
||||
|
@ -45,7 +45,7 @@ private:
|
||||
DRMEMORY,
|
||||
BOUNDS_CHECKER,
|
||||
// checkers after here do not use the standard error list
|
||||
CUDA_MEMCHECK,
|
||||
CUDA_SANITIZER,
|
||||
ADDRESS_SANITIZER,
|
||||
LEAK_SANITIZER,
|
||||
THREAD_SANITIZER,
|
||||
|
@ -167,7 +167,7 @@ if(NOT CMake_TEST_EXTERNAL_CMAKE)
|
||||
-DPSEUDO_BC=$<TARGET_FILE:pseudo_BC>
|
||||
-DPSEUDO_PURIFY=$<TARGET_FILE:pseudo_purify>
|
||||
-DPSEUDO_VALGRIND=$<TARGET_FILE:pseudo_valgrind>
|
||||
-DPSEUDO_CUDA_MEMCHECK=$<TARGET_FILE:pseudo_cuda-memcheck>
|
||||
-DPSEUDO_CUDA_SANITIZER=$<TARGET_FILE:pseudo_cuda-memcheck>
|
||||
-DPSEUDO_BC_NOLOG=$<TARGET_FILE:pseudonl_BC>
|
||||
-DPSEUDO_PURIFY_NOLOG=$<TARGET_FILE:pseudonl_purify>
|
||||
-DPSEUDO_VALGRIND_NOLOG=$<TARGET_FILE:pseudonl_valgrind>
|
||||
|
@ -179,11 +179,11 @@ unset(CTEST_SUFFIX_CODE)
|
||||
#-----------------------------------------------------------------------------
|
||||
set(CMAKELISTS_EXTRA_CODE
|
||||
"add_test(NAME TestSan COMMAND \"${CMAKE_COMMAND}\"
|
||||
-P \"${RunCMake_SOURCE_DIR}/testCudaMemcheck.cmake\")
|
||||
-P \"${RunCMake_SOURCE_DIR}/testCudaSanitizer.cmake\")
|
||||
")
|
||||
set(CTEST_SUFFIX_CODE "message(\"Defect count: \${defect_count}\")")
|
||||
set(CTEST_MEMCHECK_ARGS "DEFECT_COUNT defect_count")
|
||||
run_mc_test(DummyCudaMemcheck "${PSEUDO_CUDA_MEMCHECK}")
|
||||
run_mc_test(DummyCudaSanitizer "${PSEUDO_CUDA_SANITIZER}")
|
||||
unset(CTEST_MEMCHECK_ARGS)
|
||||
unset(CTEST_SUFFIX_CODE)
|
||||
unset(CTEST_EXTRA_CODE)
|
||||
|
Loading…
Reference in New Issue
Block a user