Default Behavior & Activation Flags for Each Mode
Compaction of Load is the Erlang VM's default load balancing strategy. To switch to Utilization Balancing, users must explicitly enable it via the `+sub true` flag at startup or configure `erlang.schedulers.utilization_balancing` to `true`, which implicitly disables compaction.
The top 3
- Erlang's Default: Compacting Load for Efficiency: By default, the Erlang scheduler operates in compaction mode, enabled by `+scl true`, which prioritizes fully loading active scheduler threads to reduce idle cores and potentially improve power efficiency.
- Maximize Core Usage with Utilization Balancing: To evenly spread workload across all available CPU cores, the `+sub true` flag enables utilization balancing, actively striving for equal scheduler utilization and overriding the default compaction behavior.
- Subtle Differences: +scl false vs. +sub true: Disabling compaction with `+scl false` prevents load consolidation but does not guarantee balanced utilization; `+sub true` is specifically designed to achieve an even distribution of work across all schedulers.
Open the full topic