ctest 3.29.2 crash on Windows with oversubscription


Maybe this is the wrong place to report the following issue:

We found a heap corruption in ctest 3.29.2 while executing:
ctest --preset windows-debug --parallel 50
on a 2x18core Intel Windows 10 Enterprise machine
With ctest 3.27.1 it works!

Best regards

Does this heap corrupt? It worked on a 4-core WIndows laptop with CMake 3.29.2.

cmake_minimum_required(VERSION 3.20)

project(sleepy LANGUAGES NONE)


foreach(i RANGE 500)
  add_test(NAME test${i} COMMAND ${CMAKE_COMMAND} -E sleep 2.0)
cmake -Bbuild
ctest --test-dir build --parallel 500

Please create an issue here: https://gitlab.kitware.com/cmake/cmake/-/issues If you could provide a sample that reproduces the crash that would be great as well. A stack trace would be nice if you could get one. Thanks.


I ran the above example over and over again with high oversubscription, but I can’t get a crash in ctest.
When we ran our test-suite with 750 tests and 50 in parallel I sometimes get a heap corruption but not always! (I attach developer studio 2019 to it)
Also I do not get a readable call-stack due to no debug information.
With a linker map file it would be possible to calculate back to the faulting code. But pointer checker or address sanitizer builds would be much better.

Best regards