opened
rndr
username_0
[this](https://github.com/iron/iron/wiki/How-to-Benchmark-hello.rs-Example) page was last time update Nov 5, 2014.
while it's definitely depends on hardware and env, i'm getting ~10x times smaller number of request/sec:
```
Running 10s test @ http://127.0.0.1:3000/
  12 threads and 900 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     2.75ms    5.42ms  16.94ms   87.35%
    Req/Sec     7.38k     1.65k   12.78k    71.13%
  68881 requests in 10.04s, 7.49MB read
  Socket errors: connect 0, read 0, write 0, timeout 3899
Requests/sec:   6858.84
Transfer/sec:    763.58KB
```
Is unboxed closures such a regress for hello.rs?
i've unsuccessfully tried to bench pre-unboxed hello.rs, but updating to latest rustc nightly before compiling was a bad idea, and updating to previous rustc nightly is such a pain.
84K number is also mentioned in [README.md](https://github.com/iron/iron/blob/master/README.md)
wiki page "How to Benchmark hello.rs Example" may be in need of update
issue
created
reem
username_1
When you run `cargo run --release --example hello` cargo ignores the `--release` flag when you set `--example`, which is why you are seeing poor performance. Build iron with `cargo build --release` and then compile `hello.rs` manually using `rustc --opt-level=3 examples/hello.rs -L target/release -L target/release/deps -C lto --cfg ndebug` to get a fully optimized binary to test with.
comment
created
rndr
username_0
i've finally been able to compile iron (deps, 1.0-alpha, ...) and with rust-lang/cargo#831 being fixed if i run `cargo run --release --example hello` i'm getting:
```
Running 10s test @ http://127.0.0.1:3000/
  12 threads and 900 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     2.11ms    2.77ms   5.91ms   65.31%
    Req/Sec    42.11k     7.80k   54.33k    65.23%
  390795 requests in 10.02s, 42.49MB read
  Socket errors: connect 0, read 0, write 0, timeout 3944
Requests/sec:  39011.24
Transfer/sec:      4.24MB
```
I've tried building by hand with your commands and it's same.
I guess it might be me running ubuntu under VMWare VM. Closing?
comment
closed
reem
username_1
issue
created
reem
username_1
It's probably because of the VM, I just ran the same thing and got 85k. Closing.
comment