Make comparison benchmarks relative
This commit is contained in:
@@ -464,6 +464,7 @@ int main() {
|
|||||||
auto simple_bench = ankerl::nanobench::Bench()
|
auto simple_bench = ankerl::nanobench::Bench()
|
||||||
.title("Simple JSON Parsing Comparison")
|
.title("Simple JSON Parsing Comparison")
|
||||||
.unit("byte")
|
.unit("byte")
|
||||||
|
.relative(true)
|
||||||
.batch(SIMPLE_JSON.size())
|
.batch(SIMPLE_JSON.size())
|
||||||
.warmup(100)
|
.warmup(100)
|
||||||
.minEpochIterations(1000);
|
.minEpochIterations(1000);
|
||||||
@@ -544,6 +545,7 @@ int main() {
|
|||||||
auto medium_bench = ankerl::nanobench::Bench()
|
auto medium_bench = ankerl::nanobench::Bench()
|
||||||
.title("Medium JSON Parsing Comparison")
|
.title("Medium JSON Parsing Comparison")
|
||||||
.unit("byte")
|
.unit("byte")
|
||||||
|
.relative(true)
|
||||||
.batch(MEDIUM_JSON.size())
|
.batch(MEDIUM_JSON.size())
|
||||||
.warmup(100)
|
.warmup(100)
|
||||||
.minEpochIterations(500);
|
.minEpochIterations(500);
|
||||||
@@ -625,6 +627,7 @@ int main() {
|
|||||||
.title("Complex JSON Parsing Comparison")
|
.title("Complex JSON Parsing Comparison")
|
||||||
.unit("byte")
|
.unit("byte")
|
||||||
.batch(COMPLEX_JSON.size())
|
.batch(COMPLEX_JSON.size())
|
||||||
|
.relative(true)
|
||||||
.warmup(100)
|
.warmup(100)
|
||||||
.minEpochIterations(200);
|
.minEpochIterations(200);
|
||||||
|
|
||||||
@@ -707,6 +710,7 @@ int main() {
|
|||||||
auto large_bench = ankerl::nanobench::Bench()
|
auto large_bench = ankerl::nanobench::Bench()
|
||||||
.title("Large JSON Parsing Comparison")
|
.title("Large JSON Parsing Comparison")
|
||||||
.unit("byte")
|
.unit("byte")
|
||||||
|
.relative(true)
|
||||||
.batch(large_json.size())
|
.batch(large_json.size())
|
||||||
.warmup(50)
|
.warmup(50)
|
||||||
.minEpochIterations(100);
|
.minEpochIterations(100);
|
||||||
|
|||||||
Reference in New Issue
Block a user