Skip to content

Keep Gemma 4 ignored gates compilable and define their maintainer runner #945

Description

@xiaguan

Problem

Gemma 4's checkpoint-backed gates are valuable but have no continuous compile contract or checked-in execution manifest.

At 69c4e149:

  • pegainfer-gemma4 has 19 ignored library gates: 8 in src/engine.rs and 11 in src/serve_oracle.rs.
  • The gates cover HF numeric parity, long/window context, generation, mixed admission, async prefill, prefix cache, CUDA Graph replay, cancellation, and lifecycle behavior.
  • GitHub CI does not build or Clippy-check pegainfer-gemma4 --features gemma4 --all-targets.
  • No checked-in runner names the maintained gate set.
  • Engine gates document --test-threads=1, but a generic --ignored command does not encode the suite membership or prove that every expected gate still exists.

The tests currently fail closed when PEGAINFER_TEST_MODEL_PATH is absent and pin their checkpoint/fixtures. The decay risk is that feature-only test code can stop compiling or individual gates can fall out of the informal command set.

Related model roadmap: #758.

Direction

Add feature-on compile/Clippy coverage without requiring a GPU in GitHub CI. Add one maintainer-run, fail-closed, serial command that owns the real checkpoint/GPU suite.

Do not split serve_oracle.rs in this issue. Establish the execution contract before reorganizing the files.

Acceptance criteria

  • GitHub CI runs release cargo check and Clippy with -D warnings for pegainfer-gemma4 --features gemma4 --all-targets using the repository's supported CUDA build setup.
  • CI does not silently drop the feature when test targets are compiled.
  • A checked-in maintainer runner explicitly names the 19 expected ignored gates, grouped by their invariant.
  • The runner always uses --test-threads=1 and fails before execution when the checkpoint, required fixture, pinned metadata, or CUDA device is unavailable.
  • The runner prints the source commit, selected gate names, and selected/completed/failed counts; any missing or skipped gate makes the command fail.
  • The runner serializes model ownership so two checkpoint-heavy tests are not launched concurrently.
  • Existing external golden, row-ownership, lifecycle, prefix-cache, async-prefill, and graph/eager-equivalence coverage is retained.
  • The PR includes one maintainer-run result for the exact head.

A GPU GitHub Actions runner is out of scope. This issue makes the manual GPU evidence reproducible and keeps the feature/test surface alive between runs.

Contributor guardrails

  • The PR description must map all 19 current gate names to an invariant group and show that the runner selects each name exactly once.
  • Do not satisfy the runner contract with source grep, test-name wildcards, log-only SKIP detection, or an unbounded repository-wide --ignored command.
  • Do not replace real checkpoint/GPU evidence with mocks, fake fixtures, simulated CUDA, or tests of the runner implementation itself.
  • CI evidence must show feature-on all-target check and Clippy commands/results. A default-feature build is not equivalent.
  • Keep the engine/oracle test bodies and production code unchanged except where required to make prerequisite failure explicit. File splitting, renaming, helper-framework extraction, and unrelated cleanup are out of scope.
  • The exact-head maintainer transcript must include selected/completed/failed counts and the serial setting; a PR-body claim without command output is insufficient.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requesthelp wantedExtra attention is neededhw:1-gpuNeeds one consumer GPU to verify

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions