Re:Rust at speed – building a fast concurrent database [video]
by NovaX on Sunday January 06, 2019 @03:08AM
(#18837223)
It is not lock-free. Every time he reads he acquires a lock by calling epochs.lock(). That may not explain the numbers entirely, but this benchmark is completely bogus.
[ Parent
| on HN ]
Re:Rust at speed – building a fast concurrent database [video]
by the_mitsuhiko on Sunday January 06, 2019 @06:08AM
(#18837726)
> Every time he reads he acquires a lock by calling epochs.lock().
Where do you see this? I only see it lock on refresh.
Re:Rust at speed – building a fast concurrent database [video]
by NovaX on Sunday January 06, 2019 @12:34PM
(#18839415)
The benchmark allocates a new ReadHandle on every get(key) operation, whose constructor performs work under a shared lock. This is a design flaw of the benchmark, not the library.
Re:Rust at speed – building a fast concurrent database [video]
by Jonhoo on Sunday January 06, 2019 @01:03PM
(#18839587)
I'm not sure where you get that from? The benchmark code clones one read handle for each read thread at the beginning, which is then used for the entire benchmark: https://github.com/jonhoo/rust-evmap/blob/d307999c1ad78d10ec...