Skip to content

Read the memory before an engine starts only after the calibration's GPU memory is released - #53

Merged
audenvenn merged 1 commit into
mainfrom
calibration-release
Nov 21, 2026
Merged

audenvenn merged 1 commit into
mainfrom
calibration-release

Conversation

@audenvenn

Copy link
Copy Markdown
Owner

The GPU calibration's memory stays wired for about a second after its process ends. On 2026-11-21 that was 2.1 GB: 2.62 GB wired before, 4.73 GB at once, 2.67 GB a second later.

The problem: memory_at_start was read at once, so it counted that memory as held by the other apps. Two figures read low by it, 2–3.5 GB in the runs:

  • "estimated available before launch";
  • the speed test's baseline for "system taken".

The engines start seconds later and don't see it: oMLX's default guard computed its 11.10 GB ceiling after the release.

The fix: calibrated() runs the calibration and waits until wired memory is back within 0.3 GB of its level before, at most 10 s. The run and the speed test now read their memory after it, and record calibration_release_seconds.

Published pages: not changed here; whether to correct the earlier rounds' figures is the maintainer's call.

Tests: tests/test_calibration_release.py; the suite passes (78).

🤖 Generated with Claude Code

…GPU memory is released

The GPU calibration's memory stays wired for about a second after its process ends. On 2026-11-21 that was 2.1 GB:
2.62 GB wired before, 4.73 GB at once, 2.67 GB a second later. memory_at_start was read at once, so it counted
that memory as held by the other apps. "Estimated available before launch" read low by it, 2-3.5 GB in the runs,
and so did the speed test's baseline for "system taken". The engines themselves start seconds later and do not
see it: oMLX's default guard computed its 11.10 GB ceiling after the release.

calibrated() runs the calibration and waits until wired memory is back within 0.3 GB of its level before, at
most 10 s. The run and the speed test now read their memory after it, and record calibration_release_seconds.

Tests: tests/test_calibration_release.py; the suite passes (78).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@audenvenn
audenvenn merged commit ee9e319 into main Nov 21, 2026
audenvenn added a commit that referenced this pull request Nov 21, 2026
…the pi-LoRA page reads low (#54)

The maintainer's #85 ①: notes only, no records changed.

Both readings were taken the moment solvetime's GPU calibration process had ended, before macOS released the
memory that process had used. That memory stays wired for about a second (2.1 GB in a test on 2026-11-21), so
"estimated available before launch" reads low:
- 27B page: wired memory at launch 5.3-6.5 GB against about 2.4-2.8 GB at idle, so roughly 2.5-4 GB low. The
  speed table's "Memory taken (system)" counts from the same reading and reads low by about as much.
- pi-LoRA page: roughly 3-3.7 GB low. The four runs carry about the same offset, so their order stands.

The anonymous-memory readings are not affected, and the engines started seconds after the release. solvetime #53
now reads the memory after the release. The 35B page predates the per-run reading (#27); its own calibration
defect is already described on it.

Co-authored-by: Claude Opus 5.5 <[email protected]>
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.

1 participant