Skip to content

nsfcac/ECHO

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ECHO

Empirical Curve-fitting for HPC Optimization of DVFS

Lightweight DVFS controller that measures IPC curves to find optimal CPU frequency

Paper

"ECHO: Empirical Curve-fitting for HPC Optimization of DVFS" Target: SC or HPDC

Overview

ECHO dynamically adjusts CPU frequency by directly measuring the IPC curve — the relationship between CPU frequency and achieved throughput. Rather than classifying workloads or training ML models, ECHO probes IPC at 2-3 frequency points, fits a curve, and solves for the minimum frequency that maintains a configurable throughput target.

Key insight: You don't need to model why IPC changes with frequency. Just measure how much it changes, fit a curve, and find the knee.

How it works:

  1. Probe phase (~600ms): Measure IPC at 3 frequencies (f_ref, 0.85×f_ref, 0.70×f_ref)
  2. Fit: IPC(f) = af² + bf + c (quadratic least-squares)
  3. Solve: Find the lowest f where IPC(f) × f preserves target throughput
  4. Hold: Maintain f_opt, monitor MPKI for phase changes, re-probe when needed

ECHO operates as a standalone userspace daemon — no kernel modifications, no MPI integration, no application source code changes, no per-workload training.

Research Questions

  1. Curve quality — Does the 3-point quadratic IPC fit achieve R² > 0.99 across diverse HPC workloads?
  2. Energy savings — How much energy does ECHO save compared to Linux governors?
  3. Performance impact — What is the throughput degradation at R = 0.98?
  4. Phase detection — How accurately does MPKI-based detection identify workload changes?
  5. Platform portability — Does ECHO work across AMD Zen 2/3/4 without recalibration?

Project Structure

echo-dvfs/
├── README.md           ← This file
├── PROPOSAL.md         ← Research proposal / paper draft
├── figures/            ← Paper figures
├── docs/               ← Internal documentation
├── deploy/             ← Cluster/systemd deployment assets
├── src/
│   ├── daemon/c/       ← ECHO daemon (C)
│   │   ├── echo.h          ← Core header
│   │   ├── main.c          ← CLI
│   │   ├── pmc.c           ← PMC reader (raw perf_event_open)
│   │   ├── freq.c          ← Frequency control (cpufreq sysfs)
│   │   ├── curve_fitter.c  ← IPC curve fitting
│   │   ├── daemon.c        ← Two-phase control loop (probe + hold)
│   │   ├── collect.c       ← Frequency sweep collector
│   │   └── Makefile
│   ├── daemon/README.md
│   └── tools/
│       ├── run_echo_experiment.sh  ← Full experiment runner
│       ├── curve_analyzer.py       ← IPC curve analysis & plots
│       ├── collect_pmc.py          ← PMC data collection
│       ├── generate_synthetic.py   ← Synthetic data generator
│       └── run_sweep.sh            ← Standalone frequency sweep
├── experiments/        ← Experiment results
└── references/         ← Papers, articles, specs

Quick Start

# Build C daemon
cd src/daemon/c && make

# Dry-run test
./echo daemon --dry-run --duration 30 --verbose

# Frequency sweep (real hardware, needs root)
sudo bash src/tools/run_echo_experiment.sh --sweep-only --freqs 1500 2000 2500 3000

# Analyze sweep data
python3 src/tools/curve_analyzer.py -i experiments/run_*/sweep/parsed.csv -o analysis/

# Run daemon on real hardware
sudo ./echo daemon --duration 600 --log echo.csv --verbose

# Run daemon and log ECHO overhead/probe-time metrics
sudo ./echo daemon --duration 600 --log echo.csv --collect-overhead

# Full experiment (sweep + analysis + daemon + baseline)
sudo bash src/tools/run_echo_experiment.sh --all

# Cluster deployment package
# See deploy/systemd/README.md for the root-owned systemd service template
# and the per-job wrapper used from scheduler hooks or restricted sudo.
# Slurm per-job opt-in with overhead collection: sbatch --comment='ECHO=1,COLLECT_OVERHEAD=1' job.sh
# That also appends the final overhead summary to the job's Slurm stdout file.

Current Status

  • Literature review (MCBound, GEOPM, DRL-DVFS, DVFO, Frontier study)
  • Methodology design (empirical IPC curve fitting)
  • Paper draft (all sections)
  • C daemon implementation
  • Experiment scripts
  • Analysis tools (curve_analyzer.py)
  • Real hardware experiments on AMD EPYC
  • Paper revision with experimental results

About

Lightweight DVFS controller that measures IPC curves to find optimal CPU frequency

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors