zkus optimalizace, Rust schvalne by default neoptimalizuje vubec, viz FAQ:
Why is my program slow?
The Rust compiler doesn’t compile with optimizations unless asked to, as optimizations slow down compilation and are usually undesirable during development.:
Ale jinak z takto kratkeho programu se moc nezjisti, protoze 6 nebo 10 ms je tak nizka hodnota, ze se do toho nutne zapocita start runtime (to je problem vetsiny mikrobenchmarku). Zacal bych s necim slozitejsim, co psali lidi, kteri ten ktery jazyk znaji: