cc1bbd0ab7
Move the GEMM + allreduce sweep/render logic out of scripts/ and tests/
into two self-contained eval benches so a user can regenerate every
result + figure with one command:
kernbench run --bench milestone-1h-gemm (MILESTONE_FAST=1 reuses JSON)
kernbench run --bench milestone-1h-ccl
- benches/milestone_1h_{gemm,ccl}.py: single home for each domain; the
run(torch) entry drives the sweeps and writes figures into
benches/1H_milestone_output/{gemm,ccl}/ (gitignored), then submits a
sentinel tensor to satisfy the run_bench contract.
- tests/gemm + tests/sccl helpers and scripts/gemm_sweep.py become thin
re-export/wrapper shims over the benches (single source preserved); the
pytest-only param builders + _run_distributed wrapper stay in the shim.
- eval-bench pattern: a bench may drive many configs + build its own
per-config engines (extends ADR-0045 D5; reverses ADR-0044 D1/D2).
ADR-0054 (EN+KO) records the design; ADR-0043/0044/0045 + CLAUDE.md CLI
Semantics amended; ADR INDEX regenerated. Verified: milestone benches run
clean (ok=True, all artifacts), full suite 67 passed, lang-pairs OK.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
32 lines
947 B
Python
32 lines
947 B
Python
"""Thin re-export shim for the GEMM figure tests.
|
|
|
|
Not a test module (no ``test_`` prefix → pytest does not collect it).
|
|
|
|
The sweep + renderer logic now lives in
|
|
``kernbench.benches.milestone_1h_gemm`` (production single home, ADR-0054,
|
|
also driven by ``scripts/gemm_sweep.py``). The figure tests import the same
|
|
names from here; behavior is unchanged (defaults still target
|
|
``docs/diagrams/gemm_plots/``).
|
|
"""
|
|
from __future__ import annotations
|
|
|
|
from kernbench.benches.milestone_1h_gemm import (
|
|
DEFAULT_PLOTS_DIR as GEMM_PLOTS_DIR,
|
|
DEFAULT_SWEEP_JSON as GEMM_SWEEP_JSON,
|
|
ROOT,
|
|
emit_all_gemm_plots,
|
|
emit_mac_utilization_measured,
|
|
emit_mac_utilization_theoretical_vs_measured,
|
|
emit_stage_breakdown,
|
|
)
|
|
|
|
__all__ = [
|
|
"GEMM_PLOTS_DIR",
|
|
"GEMM_SWEEP_JSON",
|
|
"ROOT",
|
|
"emit_all_gemm_plots",
|
|
"emit_mac_utilization_measured",
|
|
"emit_mac_utilization_theoretical_vs_measured",
|
|
"emit_stage_breakdown",
|
|
]
|