-
Notifications
You must be signed in to change notification settings - Fork 269
Rework scheduler options and defaults #1251
Copy link
Copy link
Closed
Labels
Component: DocumentationIn-repository documentation, under docs/In-repository documentation, under docs/Component: MainComposing the core Shadow executableComposing the core Shadow executablePriority: MediumImportant but not urgentImportant but not urgentStatus: AcceptedBug is reproducible or effort is allocatedBug is reproducible or effort is allocatedType: MaintenanceRefactoring, cleanup, documenation, or process improvementsRefactoring, cleanup, documenation, or process improvements
Description
I think things are heading towards always using the "host" scheduler (-t host) with --max-concurrency set to what would previously have been the number of workers; e.g. the number of physical CPU cores available, and the number of workers (-w) set to something in between "number of hosts in the simulations" and "number of hosts in the simulation / ~100". This is all a bit confusing and fiddly for users.
Current proposal:
- Remove schedulers other than the host scheduler, reclaiming the
-tflag - Remove the "0 worker" special case that runs hosts on the main shadow thread. Running a single worker isn't much more overhead, and this would get rid of some extra complexity in the code.
- Rename
--max-concurrencyto--processorsand-p, described as "Number of processors to utilize to execute simulated hosts". We decided against calling this something more specific like--logical-processors, since that's an implementation detail we'd like to be able to change without a major release. - Add a flag
--hosts-per-thread, and by default set the number of worker threads based on this and the number of hosts in the simulation. On one hand this leaks a bit about the "logical processor" implementation, but OTOH it probably does need to be a tunable parameter. Maybe this should be in the experimental/unstable section, and/or should not have a single-character-alias, so that we can later change it to silently do nothing. - Keep
--workersbut drop-w, and again make it a flag that could in the future may be silently ignored. If set, this would override--processors
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Component: DocumentationIn-repository documentation, under docs/In-repository documentation, under docs/Component: MainComposing the core Shadow executableComposing the core Shadow executablePriority: MediumImportant but not urgentImportant but not urgentStatus: AcceptedBug is reproducible or effort is allocatedBug is reproducible or effort is allocatedType: MaintenanceRefactoring, cleanup, documenation, or process improvementsRefactoring, cleanup, documenation, or process improvements