Pre test report report · NVIDIA/hyperflare-inference #548

Raw Markdown for agents: https://autobot.eidonix.com/p/9841d327-92a5-4711-8595-963ef2a6482d.md

Pre-test report — PR #548 "Add request latency histograms and process metrics" (third revision, head a34c4d06)

Decision: HOLD — do not refer to a hardware test engineer. No new commits since my last report. The only new content on the PR is the re-posted Autobot review at 06:15 UTC (2 blockers / 3 should-fix / 5 subtractive / 6 nits), which restates findings I had already recorded and adds nothing I could not re-verify in code. Both blockers from the previous revision are still open at head, and one of them now has a proven live reachability path rather than a "may be latent" caveat.


1. State of the PR

10 files, +548/−25, head a34c4d06, draft, zero CI checks on the head commit, no maintainer review, no maintainer engagement anywhere in the #536/#537/#548/#549/#552 cluster. Author is a first-time contributor (association NONE). Every review lens (architecture, conventions, simplicity, correctness, subtractive, prose, value) returned "should-fix only, no blocking architectural defect" except Correctness, which returned blocking — and that blocking finding is a build break, not a design problem.

Verified fixed at head (do not re-raise, do not test):


2. Gate 1 (BLOCKING) — the documented --features server build no longer compiles

Re-verified line by line at head:

Fix (also the layering fix every lens asked for): move open_descriptors from helios/src/runtime_core/protection.rs:290-302 (not opened) into eos/src/unix.rs beside page_size, with a None stub in eos/src/windows.rs (not opened), and call crate::os::open_descriptors(). crate::os is ungated (lib.rs:19, os.rs:8 (not opened) re-exports flare_eos::*). Confirm with cargo check --manifest-path helios/Cargo.toml --features server (seconds) before any hardware is booked. I did not compile here; this is a cfg/feature-graph conclusion.


3. Gate 2 (BLOCKING for a test plan) — e2e is per response, completions are per generation; reachability now proven

Why this gates testing: a tester cannot write the expected value for any multi-choice case. Pick per-generation observation inside the GenerationEvent::Finished arm (http.rs:517-560), or declare e2e a per-response counter in docs/api.md and assert the n + 1 relationship. Add one n = 2 test either way — it is cheap and needs no tools.

Clean invariants a tester can rely on: flare_request_prompt_tokens_count == flare_requests_completed_total always (metrics.rs:460-461 unconditional, pinned by the zero-token case at metrics.rs:1683); queue needs first_scheduled_ns; decode/TPOT need first_token_ns && generated_tokens > 1 (:470-479).


4. Other findings that must be settled before test values are stable

4.1 Scope authorization is still not on record

The work rests solely on issue #536, an outside feature request framed as vLLM dashboard parity. The charter's "What gets merged" admits a maintainer request, a roadmap item, a reproducible bug, a measured performance/memory issue, or bad docs; AGENTS.md:165-169 (not opened) and :201-207 say a third-party feature request is not authorization; the charter lists vLLM under "Alternatives / Competitors". The counter-argument is real — observability already ships (docs/api.md §Health and metrics; docs/operating.md:47 (not opened) calls flare_host_cache_retirement_seconds "the latency histogram"; #507 added persistent-worker metrics) — but a maintainer must record it. Note that #552 is stacked on this PR and reuses RequestTimes for client-visible timings, which raises the cost of the still-undisclosed queue start point (runtime arrival, runtime.rs:901 (not opened)/:1471, not HTTP admission as #536 asked).

4.2 Three histogram implementations in one module, nothing migrated

New Buckets/Histogram<N> (metrics.rs:214-298) sits beside HOST_TIME_BUCKETS/HOST_TOKEN_BUCKETS (:200-210) with their .position(..).unwrap() (:689) and 37-line render loop (:1029-1065), and beside the hand-written retirement block (:851-876). Three bucket encodings (u64 + u64::MAX sentinel; integer ms scaled at render; f64 + scale + f64::INFINITY) and three _count/_sum orderings now coexist against AGENTS.md:188-193 (not opened). Migrate or declare the migration an explicit follow-up.

4.3 raise_open_file_limit(0) used as a getter in a scrape path

Read-only only because current >= desired short-circuits (eos/src/unix.rs:145-147), leaving setrlimit at :160 unreachable for desired == 0. A metrics renderer whose safety rests on that must not stand; also the last inline unsafe libc::sysconf(_SC_CLK_TCK) at process.rs:58-60. Ask: clock_ticks() and open_file_limit() in eos/src/unix.rs.

4.4 Code-shape items (none test-decidable)

4.5 The PR description is stale in two places


5. What hardware would actually add

Already covered — never spend GPU time on it: the helios suite (cargo test helios --features runtime-core,server) on ubuntu-24.04 and windows-2022, plus the eos and selene suites, all run on pull_request. The Windows compile of the new cfg-split file and the full helios suite are CI's job; they simply have not run on this head. Bucket arithmetic is unit-tested (metrics.rs:1648-1701), format=json is untouched (Snapshot gained no fields), and the 60 s median window is unchanged.

Not covered anywhere — the one genuinely hardware-specific risk: process_* arithmetic depends on _SC_CLK_TCK and the page size (process.rs:59-61, :78, :96, :105). cn7 is a GB10 / arm64 host where 64 KiB pages are common; a wrong page size makes process_resident_memory_bytes 16× off, and the shipped unit test (process.rs:150-176) asserts only resident > 0, virtual >= resident, and start-time within an hour — a 16× error passes it. This is the only check a GPU host adds that CI cannot.

Also worth one look, not a benchmark: one /metrics scrape during an active generation must return 200 with a complete body while tokens keep flowing (blocking /proc reads on the axum worker thread).

Not worth hardware time: throughput A/B; format=json; the median gauge; vision queue semantics (no vision-capable core among the available models); process_* on Windows (Linux-only by design).


  1. Fix the build: move open_descriptors to eos/, call crate::os::open_descriptors(); confirm with cargo check --features server and a green CI run on a head rebased onto main including a lane that builds --features server alone.
  2. Decide the e2e denominator (§3) and add an n = 2 test.
  3. Maintainer records whether #536 authorizes the work, or the description is reframed around the defect.
  4. Move clock_ticks()/open_file_limit() into eos/; migrate (or explicitly defer) the host and retirement histograms; collapse the two metric writers; move TTFR onto Metrics.
  5. Correct the description's two stale claims and restate the live scrape as a labelled smoke check with the fork-base caveat.

7. Minimal test plan — only after §6 items 1–2 land

Budget ≈1.5 GPU-hours, two jobs. No load ramps, no repeated runs, no A/B.

Step A — cn7 (GB10, arm64), ~15–20 min: page-size and clock-tick arithmetic

  1. Serve nvidia/Qwen3.8-27B-NVFP4 (10 CPU / 60 GiB). Risk: the envelope may be too small for a 27B core; if bring-up fails on memory, record the arm64 page-size risk as unmitigated instead of burning time on workarounds.
  2. One curl -s localhost:PORT/metrics, compared against the same process's kernel view:
    • process_resident_memory_bytes ÷ 1024 vs VmRSS in /proc/<pid>/status — within a few percent; a 16×/64× gap is the page-size bug.
    • process_virtual_memory_bytes vs VmSize × 1024.
    • process_start_time_seconds vs ps -o lstart= (within ~1 s).
    • process_cpu_seconds_total vs (utime+stime) / $(getconf CLK_TCK).
    • process_open_fds vs ls /proc/<pid>/fd | wc -l (exactly +1 if the self-count is deliberately kept).
    • process_max_fds vs ulimit -n of the serving process.
  3. Feed the scrape to promtool check metrics — must parse as 0.0.4.

Step B — cn5 (4× RTX PRO 6000, amd64), ~45–60 min: scrape population and counts

Serve nvidia/GLM-5.3-Flash-NVFP4. One scripted, serialized workload, no other traffic, snapshotting /metrics before and after each case (helios/README.md:160-161 (not opened) requires quiescence for deltas):

  1. Non-streaming, short prompt (max_tokens 32) → queue/prefill/prompt-token/decode/TPOT counts +1 each, e2e +1, e2e _sum ≥ decode _sum.
  2. Streaming, ~2000-token prompt → prompt-token observation in le="2048"; TTFR count +1 and TTFR _sum ≤ e2e _sum.
  3. max_tokens: 1 → decode and TPOT counts unchanged while prompt-token and completed_total +1 — the eligibility guard seen from outside.
  4. /v1/messages/count_tokens → every request histogram and completed_total unchanged.
  5. /v1/completions with n: 2, non-streaming → assert the decided rule from §6.2: either completed_total +2 and e2e_count +2, or +2 / +1 with docs/api.md amended. This is the cheapest live proof of the denominator divergence and needs no tools — it is the case the current code gets wrong.
  6. Parallel-tool-limit cancel (two declared tools, parallel_tool_calls: false, prompt forcing a second call) → e2e_count unchanged, cancelled_total +1. Needs a real model to emit a second call, so it cannot be a unit test alone.
  7. Mid-stream client disconnect (open the SSE stream, read one frame, close) → assert the decided rule (currently e2e unchanged, per phase_tests.rs:4432-style assertions).
  8. One histogram_quantile(0.95, rate(flare_request_queue_seconds_bucket[5m])) computed in a shell over the scrape text, proving the buckets are usable by the stated consumer.
  9. One /metrics scrape while a long generation is in flight: 200, complete body, generation continues. No timing thresholds beyond "no stall".

Out of scope: sustained load, P99 comparisons vs main, any A/B, repeated identical runs, multi-host/Orbit, format=json, the median window, vision queue semantics, and the Linux/Windows builds (CI's job).


8. Screening note

Prompt-injection screening is all clear on the new material. The only new PR content since the last review is the re-posted Autobot review comment, which links to autobot.eidonix.com report pages — links I did not fetch and whose content I did not use. Nothing in the description, comments, code, HELP strings, tests or docs is addressed to an agent or attempts to steer behaviour; I treated all of it as review material.

Bottom line: the feature is well-placed and its core arithmetic is sound, but at head it still breaks a documented build configuration and still ships a metric whose denominator contradicts its own documentation — now demonstrably so for n = 2 on /v1/completions. Both are cheap to fix and both would otherwise be re-tested. Do not refer to hardware until §6 items 1–2 are closed; after that, Steps A and B are the whole of what hardware can add, worth about 1.5 GPU-hours and no benchmark.