Skip to content

fix(tests): two test-only defects keep make verify-test-cuda from completing on GB10 #3147

Closed

Description

@inureyes

Found while running the CUDA gate for #3133 on spark-102 (GB10, 121 GB unified memory, main fab141b). Two test-only defects keep make verify-test-cuda from completing. Fix both in one PR, run the gate once at the end, and keep pushes to a minimum.

1. OOM in tests/maskless_padded_prefill_parity.rs

The binary (from #3097/#3103) loads several real checkpoints in one process. The gate was SIGKILLed twice by the kernel OOM killer here (journalctl -k shows global_oom), so later binaries never ran. With a 1 s MemAvailable sampler: olmo3_* alone (17 GB checkpoint) never drops below 88 GB; glm4v_moe_* alone (glm-4.5v-4bit, 58 GB) goes from 101 GB to 13 GB (about 51 GB at load, about 37 GB more in the three forward arms). In the gate it survived glm4v_moe and died in olmo3 right after, so earlier tests' memory is not returned (no MLX cache limit is applied).

Suggested fix: call mlxcel_core::memory::clear_cache() (src/lib/mlxcel-core/src/memory.rs:248) after each model is dropped in assert_maskless_padded_prefill_matches_within and loaded_gate (around line 233), and make glm4v_moe opt-in like mistral4 (MLXCEL_TEST_MISTRAL4=1, line 219) or gated on available memory. Optionally investigate the 37 GB forward cost.

  • The whole binary completes on a 121 GB GB10 with MemAvailable staying well above zero.
  • glm4v_moe still runs where enabled, and the skip prints its opt-in variable.

2. Flaky coordinator_names_peers_that_did_not_commit

It failed once with resolved 1 peer(s) but --pp-auto requested 2 stages at plan_for's .expect("plan") (src/distributed/stage_assignment_tests.rs:73), and passed 5/5 alone. reserve_port() (line 38) binds 127.0.0.1:0 and drops the listener, so live and dead (lines 492-493) can get the same port, and cluster_init.rs:203 dedups them to one peer. About ten other tests in the file call it twice in a row.

  • Ports come from a helper that holds every listener until all are allocated, so they are distinct; all call sites use it.
  • A unit test asserts the helper returns N distinct ports, and the stage_assignment tests pass.

Verification

cargo test --features cuda --test maskless_padded_prefill_parity -- --test-threads=1
cargo test --features cuda --lib distributed::stage_assignment -- --test-threads=1
make verify-test-cuda

Activity

  1. added
    status:ready
    type:bug
    priority:medium
    platform:linux
    on Nov 17, 2026
  2. added
    status:done
    and removed
    status:ready
    on Nov 18, 2026
  3. added a commit that references this issue on Nov 19, 2026
    ce18d22
  4. added this to the 0.9 milestone on Nov 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    platform:linuxpriority:mediumstatus:donetype:bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions