Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use measureme for instruction counts #76

Open
anp opened this issue Nov 3, 2020 · 0 comments
Open

Use measureme for instruction counts #76

anp opened this issue Nov 3, 2020 · 0 comments

Comments

@anp
Copy link
Owner

anp commented Nov 3, 2020

One of lolbench's main tricks is to use hardware performance counters in addition to wall time for detecting anomalies. I first implemented this using a fork of criterion which in turn makes use of a very MVP interface I wrote against perf_event_open.

Since then, https://lib.rs/crates/perf-event-open-sys was published and has apparently gotten quite mature!

@eddyb recently posted a fantastic PR to measureme adding support for instruction counts making use of the perf-event-open-sys crate, and has reported some very low-noise results using it for rustc benchmarks.

There are a few places to possibly get started, depending on ambition levels:

  1. move my mega-old criterion fork to use measureme's counter
  2. make a newer criterion fork that uses measureme's counter
  3. move off of criterion and define our own bench runner which uses measureme's counters

(1) seems easiest, (3) is what I'd actually like to do given the difficulty of doing sound statistics with the summary stats reported by criterion. But that might be too ambitious for an initial outing.

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

No branches or pull requests

1 participant