This project measures how the same program performs across Go 1.19 through Go 1.26. It is the Go companion to RepoFlow's Java benchmark.
Each version is compiled and tested in its official Docker image. Runs use isolated process repeats and produce raw JSON, a Markdown report, and an interactive HTML dashboard.
The main appsim workload models a small service request with JSON parsing, SHA256, a concurrent cache, Base64 encoding, and controlled allocation pressure.
The focused workloads cover:
- JSON parsing and encoding
- SHA256
- Base64
- Regular expressions
- Integer sorting
- Concurrent map churn
- Deflate compression
The benchmark uses only the Go standard library.
You need Docker and Python 3.9 or newer. Go does not need to be installed on the host.
Run this first:
bash scripts/smoke_test_docker.shIt compiles the benchmark, runs the tests, executes every workload, and verifies the generated report. Smoke test numbers are not suitable for publication.
List the Docker images:
bash scripts/bench_docker.sh --list-imagesRun the complete matrix:
bash scripts/bench_docker.sh --pullThe default run tests eight Go release lines, three GOMEMLIMIT settings, nine workloads, and five fresh process repeats. It takes roughly one day on the reference machine.
Run it on an idle machine connected to power. Keep the Docker platform, processor allocation, and power mode unchanged for the full run.
For a host with more than 10 cores:
bash scripts/bench_docker.sh --docker-arg '--cpus=10'Run only the synthetic application:
bash scripts/bench_docker.sh \
--scenario appsim \
--memlimits 2GiB \
--warmup 20s \
--measure 10m \
--forks 5Use bash scripts/bench_docker.sh --help for every option.
Each run creates a timestamped folder under results containing:
dashboard.htmlwith interactive chartsreport.mdwith summary tablessummary.jsonwith aggregated data- Raw
result.json, process samples, environment details, and stderr for every repeat
Summary values are means across process repeats. Time series points are medians across the same repeats.
GOMEMLIMIT is a soft Go runtime memory limit. It is not a fixed heap size and is not equivalent to Java Xms or Xmx.