21.12 · Counting wake-ups: why polling costs energy even when the work is tiny

An idle phone sleeps deeply; every wake-up pulls the processor out of that state. Energy cost scales with how often you wake, not just how much work you do.

Mental model. Wake-ups can be counted from inside the process, and replacing a poll with a blocking wait or an event removes them.

Wake-ups

Measuring context switches and what removes them.

  1. Why does a tiny repeating poll drain the battery, and how can you count wake-ups yourself? 21.12.1 · L5
    A processor in a deep idle state saves most of its power, and waking it costs a fixed amount of energy plus the time it needs to stay awake and fall back…

More in Performance & energy