Implementing Hazard Pointers in Rust (part 4/4)

Channel:
Subscribers:
97,800
Published on ● Video Link: https://www.youtube.com/watch?v=3oL1xokuHBE



Duration: 3:25:53
11,052 views
161


We continue our journey implementing Hazard Pointers (https://erdani.org/publications/cuj-2004-12.pdf) in Rust. We follow along with the C++ implementation in Facebook's Folly library (https://github.com/facebook/folly/blob/master/folly/synchronization/Hazptr.h), starting from where we left off last time: https://github.com/facebook/folly/tree/0e92d3c2705a45ba7850708fd7fe0c709d6a0e5f.

This time, the focus is on porting over tests and benchmarks, including using loom (for concurrency testing) and criterion (for benchmarks).

https://twitter.com/jonhoo/status/1482179476423208963

0:00:00 Introduction
0:02:22 Changes since last stream
0:11:39 The Twitter poll
0:13:35 folly's test suite
0:38:31 Domain::cleanup
0:45:19 Porting folly tests
1:44:51 Custom deleters
1:58:49 Porting spin test to loom
2:46:36 Benchmarking hazard pointer creation
3:15:12 Benchmarking retire and reclaim
3:21:08 drop(stream)

You can find the code here: https://github.com/jonhoo/haphazard/

Live version with chat: https://youtu.be/t0Nza-v1XIg







Tags:
rust
live-coding
hazard pointers
concurrency
folly
synchronization