Hacker News new | past | comments | ask | show | jobs | submit login

Rust mutexes are in the process of being redone. The popular parking-lot library js about to replace the platform native ones.



Can you link to the discussion this is referencing? I can't imagine parking_lot outright replacing the mutex in std, rather than being added as an optional alternative... what would be the supported way of deliberately using the platform-native mutex?


The discussion is partially here: https://internals.rust-lang.org/t/standard-library-synchroni...

The PR for std is here: https://github.com/rust-lang/rust/pull/56410

Mostly comes to the platform native APIs habing various soundness issues.


My hunch would be that the results from the talk wouldn't materially change, except that the Mutex numbers would perhaps be _slightly_ better. The scalability issue would remain though, as it is fundamental to mutexes!


parking-lot mutexes don't support lock poisoning like the standard library mutexes. Wouldn't this be a totally breaking change? Unless poisoning has been added to parking-lot?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: