Skip to content

kernel: the boot's device-setup exits as one change, 0021-0025 (#627) - #663

Closed
aledbf wants to merge 2 commits into
mainfrom
kernel/627-device-setup-exits
Closed

aledbf wants to merge 2 commits into
mainfrom
kernel/627-device-setup-exits

Conversation

@aledbf

@aledbf aledbf commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

Why

The goal is a cold boot to the first SSH login under 100 ms. Five kernel patches each remove VM exits from the boot's device setup (#590, #591, #592). Alone, none moved the first login past noise. As a bound the five read −7.4 [−12.1, −2.8] at 60 a side (lab 45114405201). #627 asked for them measured as one change at 120 a side against the release, with restore-first beside it. Measured that way, they take 9.2 ms off the cold first login and leave the restore unchanged, so they are kept.

What

  • kernel/patches/0021-0025: the bound's five, from archive/exp-batch2-bound. They apply to 7.3.5 as pinned with no change and are remade with git format-patch. They are numbered from 0021 because budget: the decompressor's copy, LZ4 and parse_elf, 21 ms (bench) before the kernel's clock #645 holds 0014-0020. Each changelog now gives what was measured.
  • kernel/Dockerfile and kernel/README.md: one vmlinux assertion per patch.
  • docs/boot-time.md: a row in "What the machine carries". The IOAPIC row in "Measured and rejected" points to it.
  • docs/log.md: the dated entry.

Measured

Bench, nested, spin's shape and login, against v20261123.06, interleaved. The kernel is parts run 45228777973.

Δp50 [95%] boots a side lab
first login −9.2 [−12.2, −6.0] 120 45231943664
sshd accepting −9.0 [−12.4, −6.7] 120 45231943664
restored login, evicted −0.6 [−2.3, +1.6] 30 45232800577
restored login, cached −0.7 [−1.5, +0.8] 30 45232800577
state size +0.3 MiB [−0.1, +0.6] 30 45232800577

0022 keeps the risk #627 named. Upstream a2f1e22390ac took out pci_restore_state()'s refusal of a state that was never saved. 0022's gate (AER, EEH, s390, Xen pcifront, reset_root_port) therefore has to grow by hand with whatever calls error handlers next. It stayed in the set because the set was fixed before the run.

Checks

  • Parts run 45228777973: checkpatch --strict clean for all five, sparse passes, and "kernel patches: each is in this vmlinux".
  • The assertions read red without the patches (local objects, same config). Without 0021, enable_IO_APIC calls clear_IO_APIC once, and with it there is no such call. vp_modern_probe calls pci_find_capability 4 times without 0023 and once with it. pci_bus_add_device calls pci_find_host_bridge only with 0022. The checks for 0024 and 0025 read the source.
  • go tool task lint test passes locally.

Closes #627.

🤖 Generated with Claude Code

aledbf and others added 2 commits November 23, 2026 15:00
The five kernel patches of #590, #591 and #592 that each remove VM exits
from device setup, carried together to be measured as one arm: alone each
read within noise, as a bound the five read −7.4 [−12.1, −2.8] at 60 a side
(lab 45114405201). Rebased onto 7.3.5 as pinned (they apply unchanged),
remade with git format-patch, checkpatch --strict clean, and asserted on the
vmlinux each goes into. The budget entry names the run that decides it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
As one change against v20261123.06 (bench, spin's shape and login): the
first login −9.2 [−12.2, −6.0] and sshd accepting −9.0 [−12.4, −6.7] at
120 a side (lab 45231943664); the restored login −0.6 [−2.3, +1.6]
evicted, 30 a side (lab 45232800577). Each patch's changelog now says
what was measured, the row moves to "What the machine carries" and the
log has its entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@aledbf
aledbf force-pushed the kernel/627-device-setup-exits branch from bcc8a26 to 916e7b3 Compare November 23, 2026 18:01
@aledbf
aledbf marked this pull request as ready for review November 23, 2026 18:01
@aledbf

aledbf commented Nov 23, 2026

Copy link
Copy Markdown
Member Author

Replaced by #699: rebased onto main (kernel 7.3.6, #645's 0014-0020) on a new branch, to be decided against v20261123.07.

@aledbf

aledbf commented Nov 23, 2026

Copy link
Copy Markdown
Member Author

Superseded by #699: the same five patches rebased onto main (7.3.6, #645) and decided against v20261123.07, first login −9.4 [−14.2, −5.7] at 120 a side (lab 45260781177), restore unchanged (lab 45261629539).

@aledbf aledbf closed this Nov 23, 2026
@aledbf
aledbf deleted the kernel/627-device-setup-exits branch November 24, 2026 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

kernel: the boot's device-setup exits as one change (0014-0018 together read −7.4 ms; none alone resolves)

1 participant