{
  "slug": "semi-preemptible-io",
  "term": "Semi-preemptible I/O",
  "aliases": [
    "semi-preemptible disk I/O"
  ],
  "definition": "Semi-preemptible I/O divides a disk request into shorter commands so that another request can be served at command boundaries.",
  "note": "A priority policy selects pending work; it does not make an executing command interruptible. The FAST 2003 design exposes intermediate scheduling points while each individual command remains non-preemptible. [fast2003]\n\nChunking splits a transfer. JIT-seek delays dispatch to turn predicted rotational waiting into preemptible slack. Seek splitting inserts boundaries into a long head movement, but repeated acceleration can increase total seek time. These are distinct mechanisms, not three names for smaller reads. [fast2003]\n\nUnder a uniform arrival over the entire operation, command durations t_i and fully preemptible slack s give mean residual blocking sum(t_i^2) / (2 * (sum(t_i) + s)). Longer commands are more likely to be encountered; averaging their half-durations without time weighting is wrong. This is blocking before service, not the arriving request's response time. [tc2005]\n\nFor hypothetical commands [8], [4,4] and [7,1] ms with no slack or overhead, mean blocking is 4, 2 and 3.125 ms. All three occupy 8 ms, but the longest non-preemptible interval is 8, 4 and 7 ms respectively. These calculated examples are not device measurements. [example]\n\nHost-visible completion also need not mean that the device is idle. Buffered writes can leave internal writeback ahead of a later request. The prototype's last-chunk FUA technique addresses its tested drive behavior; it is not a general flush of earlier unrelated writes. [fast2003] [cache-control]\n\nIn a synthetic 16 ms window, [8] ms + 8 ms slack gives mean/max blocking 2/8 ms; [6,6] ms + 4 ms slack gives 2.25/6 ms. Less maximum blocking can coexist with a larger mean when active work replaces slack. [tc2005] [tradeoff]",
  "status": "research",
  "advantages": [],
  "limitations": [
    {
      "text": "Accurate positioning profiles and drive-cache behavior matter; actual preemption can add return seeks and reduce throughput.",
      "citationIds": [
        "tc2005"
      ]
    },
    {
      "text": "The uniform-arrival formula omits other queued work, recovery activity and the new request's own service time.",
      "citationIds": [
        "tc2005"
      ]
    }
  ],
  "related": [
    "io-scheduler",
    "freeblock-scheduling",
    "rotational-latency",
    "seek-time",
    "write-back-cache",
    "shortest-remaining-processing-time",
    "non-preemptive-priority"
  ],
  "supersedes": [],
  "supersededBy": [],
  "firstSeen": null,
  "lastSeen": null,
  "updated": "2026-11-20",
  "citations": [
    {
      "id": "fast2003",
      "title": "Dimitrijevic, Rangaswami and Chang. Design and Implementation of Semi-preemptible IO. FAST 2003, pp. 145-158.",
      "url": "https://www.usenix.org/legacy/events/fast03/tech/full_papers/dimitrijevic/dimitrijevic.pdf",
      "accessed": "2026-11-09"
    },
    {
      "id": "tc2005",
      "title": "Dimitrijevic, Rangaswami and Chang. Systems Support for Preemptive Disk Scheduling. IEEE TC 54(10), 2005, equations 1-2.",
      "url": "https://users.cs.fiu.edu/~raju/WWW/publications/ieeetoc2005/paper.pdf",
      "accessed": "2026-11-09"
    },
    {
      "id": "cache-control",
      "title": "Linux 6.16: Explicit volatile write back cache control, FUA and preflush scope",
      "url": "https://docs.kernel.org/6.16/block/writeback_cache_control.html",
      "accessed": "2026-11-09"
    },
    {
      "id": "example",
      "title": "Hesela: synthetic residual-blocking examples, generated by model.mjs",
      "url": "https://hesela.dev/research/semi-preemptible-io/examples.json",
      "accessed": "2026-11-09"
    },
    {
      "id": "code",
      "title": "Hesela: residual-blocking calculation source (Node.js)",
      "url": "https://hesela.dev/research/semi-preemptible-io/model.mjs",
      "accessed": "2026-11-09"
    },
    {
      "id": "tradeoff",
      "title": "Hesela: synthetic mean-versus-maximum blocking counterexample, generated by model.mjs",
      "url": "https://hesela.dev/research/semi-preemptible-io/tradeoffs.json",
      "accessed": "2026-11-09"
    },
    {
      "id": "analysis",
      "title": "Hesela: Sharing an SSD, host-dispatch and interruption boundaries",
      "url": "https://hesela.com/analyses/ssd-fairness-shared-queues/",
      "accessed": "2026-11-09"
    }
  ],
  "provenance": [
    "FAST 2003 evaluated a Linux user-space SCSI-generic prototype on a Seagate ST318437LW with synthetic and trace workloads. Its results are not guarantees for modern HDDs or SSDs.",
    "Research mechanism, not an available Linux scheduler name. Source synthesis and worked arithmetic only; no hardware benchmark or paper replication was performed.",
    "TC2005 section 4.1.1 derives blocking from command timings without high-priority requests; actual-preemption response-time experiments are separate (section 4.2.3). The expectation is not a measured response-time percentile. [tc2005]",
    "Hesela's uniform-arrival calculation gives strict blocking exceedance above 2 ms of 37.5% versus 50%, but above 6 ms of 12.5% versus 0%, in the two 16 ms cases. These are window probabilities, not measured end-to-end deadline misses. [tradeoff]"
  ]
}
