diff options
| author | Steven Fackler <sfackler@gmail.com> | 2015-01-13 21:24:26 -0800 |
|---|---|---|
| committer | Steven Fackler <sfackler@gmail.com> | 2015-01-16 09:17:37 -0800 |
| commit | 08f6380a9f0b866796080094f44fe25ea5636547 (patch) | |
| tree | b07f1154c5095e48f96369ce9d37988e33ae3d71 /src/rustllvm/RustWrapper.cpp | |
| parent | 3d5fbae33897a8340542f21b6ded913148ca9199 (diff) | |
| download | rust-08f6380a9f0b866796080094f44fe25ea5636547.tar.gz rust-08f6380a9f0b866796080094f44fe25ea5636547.zip | |
Rewrite Condvar::wait_timeout and make it public
**The implementation is a direct adaptation of libcxx's condition_variable implementation.** pthread_cond_timedwait uses the non-monotonic system clock. It's possible to change the clock to a monotonic via pthread_cond_attr, but this is incompatible with static initialization. To deal with this, we calculate the timeout using the system clock, and maintain a separate record of the start and end times with a monotonic clock to be used for calculation of the return value.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
