aboutsummaryrefslogtreecommitdiff
path: root/benches/whirl_common_iai.rs
blob: 19093636f592fa299f3d3824156e9078effbc3d0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// Copyright (C) 2021-2021 The Whirlsplash Collective
// SPDX-License-Identifier: GPL-3.0-only

fn iai_benchmark_sort_vec_alphabetically() {
  whirl_common::sort::vec_alphabetically(&mut vec!["a", "c", "d", "b"])
}

fn iai_benchmark_system_unixts_to_hrtime() -> String {
  whirl_common::system::unixts_to_hrtime(1623058677)
}

iai::main!(
  iai_benchmark_sort_vec_alphabetically,
  iai_benchmark_system_unixts_to_hrtime
);