diff --git a/.gitlab/scripts/run_performance_benchmarks.sh b/.gitlab/scripts/run_performance_benchmarks.sh index 3f41624eb..d0679cc5b 100755 --- a/.gitlab/scripts/run_performance_benchmarks.sh +++ b/.gitlab/scripts/run_performance_benchmarks.sh @@ -41,7 +41,7 @@ pika_targets=( ) pika_test_options=( "--pika:ini=pika.thread_queue.init_threads_count=100 \ ---pika:queuing=local-priority \ +--pika:scheduler=local-priority \ --repetitions=100 \ --tasks=500000" diff --git a/.jenkins/cscs-perftests/launch_perftests.sh b/.jenkins/cscs-perftests/launch_perftests.sh index 46c68db87..1623f1edf 100755 --- a/.jenkins/cscs-perftests/launch_perftests.sh +++ b/.jenkins/cscs-perftests/launch_perftests.sh @@ -11,7 +11,7 @@ set -ex pika_targets=("task_overhead_report_test") pika_test_options=( "--pika:ini=pika.thread_queue.init_threads_count=100 \ - --pika:queuing=local-priority --pika:threads=4 \ + --pika:scheduler=local-priority --pika:threads=4 \ --repetitions=100 --tasks=500000") # Build binaries for performance tests diff --git a/libs/pika/command_line_handling/include/pika/command_line_handling/command_line_handling.hpp b/libs/pika/command_line_handling/include/pika/command_line_handling/command_line_handling.hpp index 5055f67e1..b921cb929 100644 --- a/libs/pika/command_line_handling/include/pika/command_line_handling/command_line_handling.hpp +++ b/libs/pika/command_line_handling/include/pika/command_line_handling/command_line_handling.hpp @@ -61,7 +61,7 @@ namespace pika::detail { std::size_t num_cores_; std::size_t pu_step_; std::size_t pu_offset_; - std::string queuing_; + std::string scheduler_; std::string affinity_domain_; std::string affinity_bind_; std::size_t numa_sensitive_; diff --git a/libs/pika/command_line_handling/src/command_line_handling.cpp b/libs/pika/command_line_handling/src/command_line_handling.cpp index 9fa9e2d5c..c582990ef 100644 --- a/libs/pika/command_line_handling/src/command_line_handling.cpp +++ b/libs/pika/command_line_handling/src/command_line_handling.cpp @@ -48,7 +48,7 @@ namespace pika::detail { std::ostringstream strm; // default scheduler used for this run - strm << " {scheduler}: " << cfg.queuing_ << "\n"; + strm << " {scheduler}: " << cfg.scheduler_ << "\n"; // amount of threads and cores configured for this run strm << " {os-threads}: " << cfg.num_threads_ << "\n"; @@ -132,11 +132,11 @@ namespace pika::detail { return mask_string; } - std::string handle_queuing(detail::manage_config& cfgmap, + std::string handle_scheduler(detail::manage_config& cfgmap, pika::program_options::variables_map& vm, std::string const& default_) { // command line options is used preferred - if (vm.count("pika:queuing")) return vm["pika:queuing"].as(); + if (vm.count("pika:scheduler")) return vm["pika:scheduler"].as(); // use either cfgmap value or default return cfgmap.get_value("pika.scheduler", default_); @@ -453,9 +453,9 @@ namespace pika::detail { } // handle setting related to schedulers - queuing_ = detail::handle_queuing( + scheduler_ = detail::handle_scheduler( cfgmap, vm, rtcfg_.get_entry("pika.scheduler", "local-priority-fifo")); - ini_config.emplace_back("pika.scheduler=" + queuing_); + ini_config.emplace_back("pika.scheduler=" + scheduler_); affinity_domain_ = detail::handle_affinity(cfgmap, vm, rtcfg_.get_entry("pika.affinity", "pu")); @@ -557,11 +557,11 @@ namespace pika::detail { "(--pika:threads)"); } - if (!(queuing_ == "local-priority" || queuing_ == "abp-priority")) + if (!(scheduler_ == "local-priority" || scheduler_ == "abp-priority")) { throw pika::detail::command_line_error( "Invalid command line option --pika:high-priority-threads, valid for " - "--pika:queuing=local-priority and --pika:queuing=abp-priority only"); + "--pika:scheduler=local-priority and --pika:scheduler=abp-priority only"); } ini_config.emplace_back("pika.thread_queue.high_priority_queues!=" + diff --git a/libs/pika/command_line_handling/src/parse_command_line.cpp b/libs/pika/command_line_handling/src/parse_command_line.cpp index 0c460dc87..83ec92bae 100644 --- a/libs/pika/command_line_handling/src/parse_command_line.cpp +++ b/libs/pika/command_line_handling/src/parse_command_line.cpp @@ -281,21 +281,21 @@ namespace pika::detail { ("pika:pu-offset", value(), "the first processing unit this instance of pika should be " "run on (default: 0), valid for " - "--pika:queuing=local, --pika:queuing=abp-priority, " - "--pika:queuing=static, --pika:queuing=static-priority, " - "and --pika:queuing=local-priority only") + "--pika:scheduler=local, --pika:scheduler=abp-priority, " + "--pika:scheduler=static, --pika:scheduler=static-priority, " + "and --pika:scheduler=local-priority only") ("pika:pu-step", value(), "the step between used processing unit numbers for this " "instance of pika (default: 1), valid for " - "--pika:queuing=local, --pika:queuing=abp-priority, " - "--pika:queuing=static, --pika:queuing=static-priority " - "and --pika:queuing=local-priority only") + "--pika:scheduler=local, --pika:scheduler=abp-priority, " + "--pika:scheduler=static, --pika:scheduler=static-priority " + "and --pika:scheduler=local-priority only") ("pika:affinity", value(), "the affinity domain the OS threads will be confined to, " "possible values: pu, core, numa, machine (default: pu), valid for " - "--pika:queuing=local, --pika:queuing=abp-priority, " - "--pika:queuing=static, --pika:queuing=static-priority " - " and --pika:queuing=local-priority only") + "--pika:scheduler=local, --pika:scheduler=abp-priority, " + "--pika:scheduler=static, --pika:scheduler=static-priority " + " and --pika:scheduler=local-priority only") ("pika:bind", value >()->composing(), "the detailed affinity description for the OS threads, see " "the documentation for a detailed description of possible " @@ -322,7 +322,7 @@ namespace pika::detail { "the number of cores to utilize for the pika " "runtime (default: 'all', i.e. the number of cores is based on " "the number of total cores in the system)") - ("pika:queuing", value(), + ("pika:scheduler", value(), "the queue scheduling policy to use, options are " "'local', 'local-priority-fifo','local-priority-lifo', " "'abp-priority-fifo', 'abp-priority-lifo', 'static', and " @@ -331,8 +331,8 @@ namespace pika::detail { ("pika:high-priority-threads", value(), "the number of operating system threads maintaining a high " "priority queue (default: number of OS threads), valid for " - "--pika:queuing=local-priority,--pika:queuing=static-priority, " - " and --pika:queuing=abp-priority only)") + "--pika:scheduler=local-priority,--pika:scheduler=static-priority, " + " and --pika:scheduler=abp-priority only)") ("pika:numa-sensitive", value()->implicit_value(0), "makes the local-priority scheduler NUMA sensitive (" "allowed values: 0 - no NUMA sensitivity, 1 - allow only for " diff --git a/libs/pika/resource_partitioner/examples/oversubscribing_resource_partitioner.cpp b/libs/pika/resource_partitioner/examples/oversubscribing_resource_partitioner.cpp index c7be24f50..a3c6f3e49 100644 --- a/libs/pika/resource_partitioner/examples/oversubscribing_resource_partitioner.cpp +++ b/libs/pika/resource_partitioner/examples/oversubscribing_resource_partitioner.cpp @@ -209,7 +209,7 @@ void init_resource_partitioner_handler( if (pool_threads > 0) { // we use unspecified as the scheduler type and it will be set according to - // the --pika:queuing=xxx option or default. + // the --pika:scheduler=xxx option or default. auto deft = ::pika::threads::scheduler_mode::default_mode; rp.create_thread_pool(pool_name, pika::resource::scheduling_policy::shared_priority, deft); // add N pus to network pool diff --git a/libs/pika/resource_partitioner/examples/simple_resource_partitioner.cpp b/libs/pika/resource_partitioner/examples/simple_resource_partitioner.cpp index 47a0ec375..8bf25e177 100644 --- a/libs/pika/resource_partitioner/examples/simple_resource_partitioner.cpp +++ b/libs/pika/resource_partitioner/examples/simple_resource_partitioner.cpp @@ -194,7 +194,7 @@ void init_resource_partitioner_handler( if (pool_threads > 0) { // we use unspecified as the scheduler type and it will be set according to - // the --pika:queuing=xxx option or default. + // the --pika:scheduler=xxx option or default. auto deft = ::pika::threads::scheduler_mode::default_mode; rp.create_thread_pool(pool_name, pika::resource::scheduling_policy::shared_priority, deft); // add N pus to network pool diff --git a/libs/pika/resource_partitioner/src/detail_partitioner.cpp b/libs/pika/resource_partitioner/src/detail_partitioner.cpp index 1400a6062..ef008a36d 100644 --- a/libs/pika/resource_partitioner/src/detail_partitioner.cpp +++ b/libs/pika/resource_partitioner/src/detail_partitioner.cpp @@ -437,7 +437,7 @@ namespace pika::resource::detail { else { throw pika::detail::command_line_error( - "Bad value for command line option --pika:queuing"); + "Bad value for command line option --pika:scheduler"); } // set this scheduler on the pools that do not have a specified scheduler yet diff --git a/libs/pika/thread_manager/src/thread_manager.cpp b/libs/pika/thread_manager/src/thread_manager.cpp index 384cda292..c233866f1 100644 --- a/libs/pika/thread_manager/src/thread_manager.cpp +++ b/libs/pika/thread_manager/src/thread_manager.cpp @@ -260,7 +260,7 @@ namespace pika::threads::detail { pools_.push_back(std::move(pool)); #else throw pika::detail::command_line_error( - "Command line option --pika:queuing=local-priority-lifo is not configured in " + "Command line option --pika:scheduler=local-priority-lifo is not configured in " "this build. Please make sure 128bit atomics are available."); #endif break; @@ -356,7 +356,7 @@ namespace pika::threads::detail { pools_.push_back(std::move(pool)); #else throw pika::detail::command_line_error( - "Command line option --pika:queuing=abp-priority-fifo is not configured in " + "Command line option --pika:scheduler=abp-priority-fifo is not configured in " "this build. Please make sure 128bit atomics are available."); #endif break; @@ -396,7 +396,7 @@ namespace pika::threads::detail { pools_.push_back(std::move(pool)); #else throw pika::detail::command_line_error( - "Command line option --pika:queuing=abp-priority-lifo is not configured in " + "Command line option --pika:scheduler=abp-priority-lifo is not configured in " "this build. Please make sure 128bit atomics are available."); #endif break; diff --git a/libs/pika/threading_base/tests/regressions/thread_stacksize_current.cpp b/libs/pika/threading_base/tests/regressions/thread_stacksize_current.cpp index ef21743c0..5dfee560a 100644 --- a/libs/pika/threading_base/tests/regressions/thread_stacksize_current.cpp +++ b/libs/pika/threading_base/tests/regressions/thread_stacksize_current.cpp @@ -80,7 +80,7 @@ int main(int argc, char** argv) for (auto const& scheduler : schedulers) { pika::init_params iparams; - iparams.cfg = {"--pika:queuing=" + std::string(scheduler)}; + iparams.cfg = {"--pika:scheduler=" + std::string(scheduler)}; std::cout << iparams.cfg[0] << std::endl; pika::init(pika_main, argc, argv, iparams); } diff --git a/tests/performance/local/task_overhead.cpp b/tests/performance/local/task_overhead.cpp index d6567a710..9539ccb2c 100644 --- a/tests/performance/local/task_overhead.cpp +++ b/tests/performance/local/task_overhead.cpp @@ -42,7 +42,7 @@ namespace ex = pika::execution::experimental; namespace tt = pika::this_thread::experimental; // global vars we stick here to make printouts easy for plotting -static std::string queuing = "default"; +static std::string scheduler = "default"; static std::size_t numa_sensitive = 0; static std::uint64_t num_threads = 1; static std::string info_string = ""; @@ -56,14 +56,14 @@ void print_stats(char const* title, char const* wait, char const* sched, std::in if (csv) { fmt::print(temp, "{}, {:27}, {:15}, {:45}, {:8}, {:8}, {:20}, {:4}, {:4}, {:20}", count, - title, wait, sched, duration, us, queuing, numa_sensitive, num_threads, info_string); + title, wait, sched, duration, us, scheduler, numa_sensitive, num_threads, info_string); } else { fmt::print(temp, "invoked {:1}, tasks {:27} {:15} {:18} in {:8} seconds : {:8} us/task, queue " "{:20}, numa {:4}, threads {:4}, info {:20}", - count, title, wait, sched, duration, us, queuing, numa_sensitive, num_threads, + count, title, wait, sched, duration, us, scheduler, numa_sensitive, num_threads, info_string); } std::cout << temp.str() << std::endl; @@ -340,7 +340,7 @@ void function_apply_hierarchical_placement(std::uint64_t count, bool csv) int pika_main(variables_map& vm) { { - if (vm.count("pika:queuing")) queuing = vm["pika:queuing"].as(); + if (vm.count("pika:scheduler")) scheduler = vm["pika:scheduler"].as(); if (vm.count("pika:numa-sensitive")) numa_sensitive = 1; diff --git a/tests/performance/local/task_overhead_report.cpp b/tests/performance/local/task_overhead_report.cpp index dc5e4e9ce..dba4ffed0 100644 --- a/tests/performance/local/task_overhead_report.cpp +++ b/tests/performance/local/task_overhead_report.cpp @@ -27,7 +27,7 @@ using pika::program_options::variables_map; using pika::chrono::detail::high_resolution_timer; // global vars we stick here to make printouts easy for plotting -static std::string queuing = "default"; +static std::string scheduler = "default"; [[maybe_unused]] static std::size_t numa_sensitive = 0; [[maybe_unused]] static std::uint64_t num_threads = 1; static std::string info_string = ""; @@ -117,7 +117,7 @@ void measure_function_create_thread_hierarchical_placement( int pika_main(variables_map& vm) { { - if (vm.count("pika:queuing")) queuing = vm["pika:queuing"].as(); + if (vm.count("pika:scheduler")) scheduler = vm["pika:scheduler"].as(); if (vm.count("pika:numa-sensitive")) numa_sensitive = 1;