diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2017-10-25 08:35:51 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2017-10-25 08:35:51 -0700 |
| commit | 6511e4675345887bd8f60bfd8296a1451a08f73c (patch) | |
| tree | 35a52e833d3b227c38f3676f11a689f0feefdd83 /src/libstd/sys/unix/stack_overflow.rs | |
| parent | b2478052f88db8c8526ee2dc4a382da91eefc76c (diff) | |
| download | rust-6511e4675345887bd8f60bfd8296a1451a08f73c.tar.gz rust-6511e4675345887bd8f60bfd8296a1451a08f73c.zip | |
std: Optimize thread park/unpark implementation
This is an adaptation of alexcrichton/futures-rs#597 for the standard library. The goal here is to avoid locking a mutex on the "fast path" for thread park/unpark where you're waking up a thread that isn't sleeping or otherwise trying to park a thread that's already been notified. Mutex performance varies quite a bit across platforms so this should provide a nice consistent speed boost for the fast path of these functions.
Diffstat (limited to 'src/libstd/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions
