hello world - adilsoncarvalho/rust.n.go GitHub Wiki

Pull request: https://github.com/adilsoncarvalho/rust.n.go/pull/1

Result after compilation

  • Go: 1.9M
  • Rust: 454k

Benchmark

Go

❯ hyperfine -w 100 -r 2000 -N "./hello-world"
Benchmark 1: ./hello-world
  Time (mean ± σ):       2.9 ms ±   0.2 ms    [User: 1.1 ms, System: 1.1 ms]
  Range (min … max):     2.5 ms …   4.5 ms    2000 runs

Rust

❯ hyperfine -w 100 -r 2000 -N "./hello-world"
Benchmark 1: ./hello-world
  Time (mean ± σ):       2.3 ms ±   0.3 ms    [User: 0.8 ms, System: 0.7 ms]
  Range (min … max):     2.0 ms …   7.1 ms    2000 runs