dvfs
**Dynamic Voltage and Frequency Scaling (DVFS)** is the **power management technique that dynamically adjusts the supply voltage and clock frequency of a processor or SoC based on workload demand** — exploiting the cubic relationship between power and voltage (P ∝ V²f ∝ V³ for frequency-linked voltage) to achieve 10-50× power reduction during idle or light workloads, making DVFS the single most impactful runtime power optimization in all modern processors from mobile phones to data center servers.
**Power-Voltage-Frequency Relationship**
- **Dynamic power**: P_dyn = α × C × V² × f (switching activity × capacitance × voltage² × frequency).
- **Frequency depends on voltage**: f_max ∝ (V - Vth)^α / V (higher voltage → faster switching → higher frequency).
- Reducing V by 50%: Power drops ~75% (V² factor), and frequency drops ~proportionally.
- Net effect: 50% voltage reduction → ~87.5% power reduction (V³ approximation).
**DVFS Operating Points**
| Mode | Voltage | Frequency | Power | Use Case |
|------|---------|-----------|-------|----------|
| Turbo | 1.2V | 5.0 GHz | 200W | Peak single-thread burst |
| High Performance | 1.0V | 4.0 GHz | 110W | Sustained multi-core |
| Balanced | 0.85V | 3.0 GHz | 55W | Typical workloads |
| Low Power | 0.7V | 2.0 GHz | 20W | Background tasks |
| Ultra Low | 0.55V | 1.0 GHz | 5W | Idle-active |
| Retention | 0.4V | 0 Hz | 0.5W | Sleep state |
**Implementation Architecture**
- **Voltage regulator**: On-die or external PMIC delivers variable voltage.
- LDO (Low-Dropout Regulator): Fast response (ns), lower efficiency (80-90%).
- Buck converter: Slower response (µs), higher efficiency (90-98%).
- **PLL/Clock generator**: Adjusts frequency — PLL relock time is 5-50 µs → frequency changes are slow.
- **Power management unit (PMU)**: Firmware/hardware controller selects voltage-frequency pair.
- **P-states**: Predefined (V, f) operating points characterized during silicon validation.
**Transition Timing**
- Voltage ramp: ~10-100 mV/µs → 0.3V transition takes 3-30 µs.
- Frequency change: PLL relock or glitchless mux between clock sources.
- **Critical rule**: Always raise voltage BEFORE raising frequency, lower frequency BEFORE lowering voltage.
- Violation → timing failures, data corruption.
**Modern DVFS Challenges**
- **Per-core DVFS**: Each CPU core has independent voltage/frequency domain.
- Requires per-core voltage regulator → area and routing cost.
- Benefit: One core at turbo while others idle → best perf/watt.
- **Adaptive voltage scaling (AVS)**: Closed-loop voltage adjustment based on on-die speed monitors.
- Critical path monitors detect actual silicon speed → reduce voltage until hitting margin.
- Saves 10-20% power beyond static voltage tables.
**Software Interface**
- Linux: cpufreq governor (performance, powersave, schedutil).
- ARM: SCMI (System Control and Management Interface) protocol.
- x86: Intel SpeedStep / Speed Shift, AMD Cool'n'Quiet / Precision Boost.
DVFS is **the cornerstone of modern processor power management** — without dynamic voltage-frequency scaling, mobile phones would last minutes instead of hours, and data center power bills would be 3-5× higher, making it the single most important technique enabling the energy-efficient computing that powers billions of devices worldwide.