Skip to content

cleanup(rdna): drop leftover bring-up debug probes - #44

Closed
BlivionIaG wants to merge 1 commit into
rdna_extra/v0.28.0from
cursor/drop-bringup-debug-probes-f10c
Closed

BlivionIaG wants to merge 1 commit into
rdna_extra/v0.28.0from
cursor/drop-bringup-debug-probes-f10c

Conversation

@BlivionIaG

Copy link
Copy Markdown

Purpose

Remove leftover bring-up /tmp debug probes and two orphan utils from the recent Python delta. Nothing production imported those modules, and the deleted gates only logged or dumped when an unregistered env var was set. Live kernel-selection knobs stay. No new machinery, and these knobs are not registered in envs.py.

This does not duplicate an open PR. Open PRs on this repo (#2, #25, #37, #40, #41, #42, and the rest) touch other files. #41/#42 are the HIP/tools/ cleanups and were left alone.

AI assistance was used (Cursor Grok 4.7). The diff is deletions (918 lines removed, two lines rewritten so the all-reduce return and the W4A16 fallback if stay valid).

Deleted whole modules (no Python importers)

  • vllm/utils/rocm_poolwatch.py
  • vllm/utils/rocm_graph_keepalive.py (the C++ op may stay unbound from Python)

Deleted gated debug blocks

  • GDN: VLLM_LOG_GDN_PTRS, VLLM_GDN_OUT_DEBUG, VLLM_GDN_NAN_DEBUG, VLLM_GDN_STATE_DEBUG / VLLM_GDN_SAVE, VLLM_GDN_DBG. Kept VLLM_GDN_HIP_PREFILL and VLLM_GDN_DECODE_RDNA2.
  • Mamba: VLLM_MAMBA_COPY_DEBUG and the debug local.
  • QSA: _DEBUG / VLLM_QSA_RDNA2_DEBUG, the clone+print site, and _qsa_dump_bad_rows. Kept VLLM_RDNA_QSA_HIP.
  • CUDA graph / backends: VLLM_PIECE_IN_DEBUG, VLLM_CG_NAN_INPUT_CHECK, VLLM_CG_REPLAY_LOG, VLLM_PIECE_DUMP / VLLM_PIECE_TP. Kept VLLM_CG_SKIP_REPLAY, the if not copied runnable fallback, and unconditional capture-time _nan_to_num_tree.
  • All-reduce and W4A16: VLLM_W4A16_PTR_DEBUG /tmp logs.
  • Block table / zeroer: VLLM_BT_DEBUG in block_table.py and worker/utils.py.
  • Prefix cache: VLLM_DEBUG_PREFIX_HIT and VLLM_NO_PARTIAL_HASH. Prefix-hit behavior is unchanged when those vars are unset (they were never registered).
  • Dead awq_prefill arm: _rdna2_w4a16_select_kernel never returned awq_prefill. Removed _awq_prefill_available, that branch, and the else-arm call to ops.awq_gemm_rdna2_prefill. GPTQ / exllama fallback remains. VLLM_RDNA2_W4A16_RUNTIME_DISPATCH is untouched.

Skipped (in-flight or another PR)

  • vllm/v1/worker/gpu/model_runner.py VLLM_BT_DEBUG — in-flight.
  • vllm/v1/attention/backends/rdna_attn.py VLLM_BT_DEBUG — same function as in-flight VLLM_FA_RDNA2_GQA_DEBUG, immediately above that gate.
  • csrc/rocm/qsa_rdna2.cu getenv("VLLM_QSA_RDNA2_DEBUG") — HIP printf cleanup is other work (cleanup(rocm): trim dead W4A8 explore sweep from production copy #41/cleanup(tools): drop finished-experiment drivers and unread env exports #42). Python no longer reads the var.
  • envs.py, exl3.py VLLM_EXL3_*, hyperconnection.py VLLM_HC_NAN_DEBUG, rdna_all_reduce.py VLLM_RDNA_AR_DEBUG — other PRs / in-flight.
  • Historical mentions remain in docs/profiling/ and bench_results/ snapshots. benchmarks/kernels/w4a16_compile_dispatch/probe.py still names awq_gemm_rdna2_prefill inside a kernel-name regex.

Test Plan

  • rg each deleted env name and symbol under vllm/**/*.py.
  • ast.parse every edited module.
  • CPU unit test, no GPU: pytest tests/kernels/quantization/test_rdna2_w4a16_selection.py::test_rdna2_w4a16_inner_dispatch -q (pure dispatcher; AWQ still maps to "prefill").

Test Result

rg under vllm/**/*.py is empty for every deleted name (VLLM_LOG_GDN_PTRS, VLLM_GDN_OUT_DEBUG, VLLM_GDN_NAN_DEBUG, VLLM_GDN_STATE_DEBUG, VLLM_GDN_SAVE, VLLM_GDN_DBG, VLLM_MAMBA_COPY_DEBUG, VLLM_QSA_RDNA2_DEBUG, _qsa_dump_bad_rows, VLLM_PIECE_IN_DEBUG, VLLM_CG_NAN_INPUT_CHECK, VLLM_CG_REPLAY_LOG, VLLM_PIECE_DUMP, VLLM_PIECE_TP, VLLM_W4A16_PTR_DEBUG, _awq_prefill_available, VLLM_DEBUG_PREFIX_HIT, VLLM_NO_PARTIAL_HASH, VLLM_RDNA_POOLWATCH, rocm_poolwatch, rocm_graph_keepalive, and the keepalive helpers). Remaining hits are the skipped sites above plus historical docs/bench snapshots.

ast.parse succeeded on all 10 edited modules. Kept selectors still present: VLLM_GDN_HIP_PREFILL, VLLM_GDN_DECODE_RDNA2, VLLM_RDNA_QSA_HIP, VLLM_CG_SKIP_REPLAY, capture-time _nan_to_num_tree.

This sandbox has no .venv, uv, torch, or pytest, so the CPU dispatcher pytest was not executed. No GPU, and no model eval: the removed gates defaulted off and were not on the serving path. The deleted awq_prefill arm was unreachable because the selector never returned that name.

No output/accuracy change is expected. Model eval was not run.

Open in Web Open in Cursor 

Remove orphan poolwatch and graph-keepalive modules, plus env-gated
/tmp dumps that nothing production calls. Live kernel selectors stay.

Co-authored-by: Grok 4.7
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.

2 participants