Skip to content

Commit 934eb8b

Browse files
committed
std: replace pthread RwLock with custom implementation inspired by usync
1 parent 972452c commit 934eb8b

File tree

5 files changed

+506
-198
lines changed

5 files changed

+506
-198
lines changed

library/std/src/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -339,12 +339,14 @@
339339
#![feature(portable_simd)]
340340
#![feature(prelude_2024)]
341341
#![feature(ptr_as_uninit)]
342+
#![feature(ptr_mask)]
342343
#![feature(slice_internals)]
343344
#![feature(slice_ptr_get)]
344345
#![feature(slice_range)]
345346
#![feature(std_internals)]
346347
#![feature(str_internals)]
347348
#![feature(strict_provenance)]
349+
#![feature(strict_provenance_atomic_ptr)]
348350
// tidy-alphabetical-end
349351
//
350352
// Library features (alloc):

library/std/src/sys/pal/unix/locks/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ cfg_if::cfg_if! {
2222
pub(crate) use futex_condvar::Condvar;
2323
} else {
2424
mod pthread_mutex;
25-
mod pthread_rwlock;
2625
mod pthread_condvar;
26+
mod queue_rwlock;
2727
pub(crate) use pthread_mutex::Mutex;
28-
pub(crate) use pthread_rwlock::RwLock;
28+
pub(crate) use queue_rwlock::RwLock;
2929
pub(crate) use pthread_condvar::Condvar;
3030
}
3131
}

library/std/src/sys/pal/unix/locks/pthread_rwlock.rs

Lines changed: 0 additions & 195 deletions
This file was deleted.

0 commit comments

Comments
 (0)