News for hackers. Stuff that matters.
Re:Benchmarking Rust with Project Euler Solutions by jasondavies on Saturday August 30, 2014 @04:59PM (#8247587)
It's probably to avoid dead-code elimination, which would defeat the purpose of the benchmark. The rust benchmarks use test::black_box [0], which does the same thing, so there's no unfair advantage there.

[0]: http://doc.rust-lang.org/test/fn.black_box.html

Re:Benchmarking Rust with Project Euler Solutions by bilalhusain on Saturday August 30, 2014 @05:57PM (#8247704)
But it appears that the Rust code is avoiding optimization over f() whereas for C code `asm("");` is inside iteration loop.