Skip to content

device_tests and examples hold a B200 while compiling on a fraction of a CPU - #93

Merged
feitreim merged 1 commit into
mainfrom
infra/gpu-gates-cpu
Jul 28, 2026
Merged

feitreim merged 1 commit into
mainfrom
infra/gpu-gates-cpu

Conversation

@feitreim

Copy link
Copy Markdown
Owner

Found while #88 waited 44 minutes on a ::examples run that produced no
container output at all — long enough that a slow build could not be told from
a hang.

device_tests and examples declare gpu=DEFAULT_GPU and no cpu=. Both run
cargo oxide run, which compiles the crate before it launches anything —
the work build's own decorator comment prices at "ten-odd minutes" with
cpu=8, and which takes closer to forty on Modal's fractional default.

A GPU function is billed for the whole container. So those minutes are billed
at B200 rates to run a Rust compiler, which is the worst cost ratio in this
file, and it is paid on the two gates every single change runs.

build and regcount have always said cpu=8; #86 added it to bench,
ladder_bench and profile. These two were simply missed, so this is closing a
gap rather than changing a policy. Timeouts go to 5400 to match the others.

Not a guess about the cause: ladder_bench carries a comment saying the
dependency tree is ten-odd minutes of compilation and that is why it asks for
eight cores.

Why this is worth its own PR rather than riding along

Three agents are running gates right now and every one of them pays this. It
also plausibly contributed to the spend limit this workspace hit earlier today,
which took tiers 2 and 3 of CI down until it was raised.

doctor is deliberately left alone: cargo oxide doctor runs in the prebuilt
/opt/warmup, so it compiles nothing.

Verification

modal_app.py parses, and CI's build job exercises modal run modal_app.py::build — which is the function whose decorator this PR copies,
unchanged. The change is a resource annotation on two functions; it alters no
command, no path and no output.

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