diff --git a/.jenkins/lsu/env-clang-12.sh b/.jenkins/lsu/env-clang-12.sh index c9b5e4a5ee10..4c24999ca78d 100644 --- a/.jenkins/lsu/env-clang-12.sh +++ b/.jenkins/lsu/env-clang-12.sh @@ -37,3 +37,4 @@ configure_extra_options+=" -DHPX_WITH_LOGGING=OFF" configure_extra_options+=" -DHPX_TOPOLOGY_WITH_ADDITIONAL_HWLOC_TESTING=ON" configure_extra_options+=" -DHPX_COROUTINES_WITH_THREAD_SCHEDULE_HINT_RUNS_AS_CHILD=ON" +configure_extra_options+=" -DHPX_WITH_TESTS_COMMAND_LINE=--hpx:queuing=local-workrequesting-mc" diff --git a/.jenkins/lsu/env-gcc-10.sh b/.jenkins/lsu/env-gcc-10.sh index 9c4064825a0a..a1fab92d356c 100644 --- a/.jenkins/lsu/env-gcc-10.sh +++ b/.jenkins/lsu/env-gcc-10.sh @@ -32,3 +32,4 @@ configure_extra_options+=" -DCMAKE_C_FLAGS=-fPIC" # configure_extra_options+=" -DHPX_WITH_POWER_COUNTER=ON" configure_extra_options+=" -DHPX_COROUTINES_WITH_THREAD_SCHEDULE_HINT_RUNS_AS_CHILD=ON" +configure_extra_options+=" -DHPX_WITH_TESTS_COMMAND_LINE=--hpx:queuing=local-workrequesting-mc" diff --git a/libs/core/schedulers/include/hpx/schedulers/local_workrequesting_scheduler.hpp b/libs/core/schedulers/include/hpx/schedulers/local_workrequesting_scheduler.hpp index a740cffde3a6..5ec8aaf2ba07 100644 --- a/libs/core/schedulers/include/hpx/schedulers/local_workrequesting_scheduler.hpp +++ b/libs/core/schedulers/include/hpx/schedulers/local_workrequesting_scheduler.hpp @@ -875,9 +875,9 @@ namespace hpx::threads::policies { if (max_num_to_steal != 0) { task_data thrds(d.num_thread_); - thrds.tasks_.reserve(max_num_to_steal); #ifdef HPX_HAVE_THREAD_STEALING_COUNTS + thrds.tasks_.reserve(max_num_to_steal); thread_id_ref_type thrd; while (max_num_to_steal-- != 0 && d.queue_->get_next_thread(thrd, false, true)) @@ -887,6 +887,7 @@ namespace hpx::threads::policies { thrd = thread_id_ref_type{}; } #else + thrds.tasks_.resize(max_num_to_steal); d.queue_->get_next_threads( thrds.tasks_.begin(), thrds.tasks_.size(), false, true); #endif