Skip to content

comfit-lab/gapbs

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

183 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GAP Benchmark Suite with steady clock & geometric mean

This repository is a modified fork of the original GAP Benchmark Suite, created to enhance timing precision and improve benchmark result reliability. The modifications focus on more accurate timing measurement, refined reporting precision, and improved average time computation.

Key Modifications

  • High-precision timing using steady clock
    The timing mechanism has been updated to use std::chrono::steady_clock instead of std::chrono::system_clock. This ensures that timing measurements are monotonic and not affected by system clock adjustments.

  • Extended precision in terminal output
    Benchmark time results printed to the terminal now display up to nine decimal places (%6.9lf) instead of the previous limited precision, providing fine-grained reproducibility and easier comparison across runs.

  • Warm-up iteration exclusion
    The first iteration in each benchmark run is treated as a warm-up and excluded from average time computation. This change helps eliminate transient initialization effects and produce more stable timing results.

  • Geometric mean for averaging
    Instead of computing an arithmetic mean across multiple iterations, the benchmark now computes the geometric mean. This method better represents central tendency when dealing with multiplicative performance factors, common in timing-based evaluations.

Motivation

Graph processing workloads often exhibit warm-up effects related to cache priming and dynamic system behavior. Similarly, arithmetic averages can be skewed by occasional outliers. These modifications address both issues and aim to make time measurements more robust for system-level benchmarking and architectural research.

Example Usage

You can build and run benchmarks as in the original GAP Benchmark Suite:

# Build the project
$ make

# Override the default C++ compiler
$ CXX=g++-13 make

# Run BFS on a small synthetic graph
$ ./bfs -g 10 -n 5

Implementation Notes

The key changes are located in the benchmark timing and reporting sections:

  • File: src/benchmark_util.h and related kernel source files
  • Timing function replaced with steady_clock
  • printf formatting updated to %6.9lf
  • Average calculation modified to:
    • Skip the first measurement
    • Compute geometric mean using logarithmic accumulation

Compatibility

All original GAP features, command-line options, and input formats remain unchanged.

About

GAP Benchmark Suite_with geometric mean & steady clock

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • C++ 92.9%
  • Makefile 6.2%
  • Emacs Lisp 0.9%