mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
30 lines
450 B
C
30 lines
450 B
C
import std::thread;
|
|
|
|
fn void! bench1() @benchmark
|
|
{
|
|
return std::thread::sleep_ms(1);
|
|
}
|
|
|
|
fn void! bench123456789() @benchmark
|
|
{
|
|
return std::thread::sleep_ms(2);
|
|
}
|
|
|
|
fn void! long_name_bench() @benchmark
|
|
{
|
|
return std::thread::sleep_ms(3);
|
|
}
|
|
|
|
fn void! very_long_name_bench() @benchmark
|
|
{
|
|
return std::thread::sleep_ms(10);
|
|
}
|
|
|
|
fn void initialize() @init
|
|
{
|
|
set_benchmark_warmup_iterations(5);
|
|
set_benchmark_max_iterations(1000);
|
|
}
|
|
|
|
|