pub(super) trait EvalContextExtPriv<'mir, 'tcx: 'mir>: MiriInterpCxExt<'mir, 'tcx> {
    // Provided methods
    fn get_or_create_id<Id: SyncId>(
        &mut self,
        next_id: Id,
        lock_op: &OpTy<'tcx, Provenance>,
        lock_layout: TyAndLayout<'tcx>,
        offset: u64
    ) -> InterpResult<'tcx, Option<Id>> { ... }
    fn rwlock_dequeue_and_lock_reader(&mut self, id: RwLockId) -> bool { ... }
    fn rwlock_dequeue_and_lock_writer(&mut self, id: RwLockId) -> bool { ... }
    fn mutex_dequeue_and_lock(&mut self, id: MutexId) -> bool { ... }
}

Provided Methods§

source

fn get_or_create_id<Id: SyncId>( &mut self, next_id: Id, lock_op: &OpTy<'tcx, Provenance>, lock_layout: TyAndLayout<'tcx>, offset: u64 ) -> InterpResult<'tcx, Option<Id>>

Lazily initialize the ID of this Miri sync structure. (‘0’ indicates uninit.)

source

fn rwlock_dequeue_and_lock_reader(&mut self, id: RwLockId) -> bool

Take a reader out of the queue waiting for the lock. Returns true if some thread got the rwlock.

source

fn rwlock_dequeue_and_lock_writer(&mut self, id: RwLockId) -> bool

Take the writer out of the queue waiting for the lock. Returns true if some thread got the rwlock.

source

fn mutex_dequeue_and_lock(&mut self, id: MutexId) -> bool

Take a thread out of the queue waiting for the mutex, and lock the mutex for it. Returns true if some thread has the mutex now.

Implementors§

source§

impl<'mir, 'tcx: 'mir> EvalContextExtPriv<'mir, 'tcx> for MiriInterpCx<'mir, 'tcx>