rust/tests/run-make/test-benches/smokebench.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

15 lines
231 B
Rust
Raw Normal View History

#![feature(test)]
extern crate test;
#[bench]
fn smoke_yesiter(b: &mut test::Bencher) {
let mut i = 0usize;
b.iter(|| {
i = i.wrapping_add(1);
i
})
}
#[bench]
fn smoke_noiter(_: &mut test::Bencher) {}