aboutsummaryrefslogtreecommitdiff
path: root/benches/whirl_common.rs
blob: 025c719308180b6e26b3c3a2e4fcbdd4b93bf869 (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_seconds_to_hrtime() -> String {
  whirl_common::system::seconds_to_hrtime(1623058677)
}

iai::main!(
  iai_benchmark_sort_vec_alphabetically,
  iai_benchmark_system_seconds_to_hrtime
);