@@ -129,14 +129,14 @@ fn mutex_set_kind<'mir, 'tcx: 'mir>(
129129fn mutex_get_id < ' mir , ' tcx : ' mir > (
130130 ecx : & MiriEvalContext < ' mir , ' tcx > ,
131131 mutex_op : OpTy < ' tcx , Tag > ,
132- ) -> InterpResult < ' tcx , ScalarMaybeUndef < Tag > > {
132+ ) -> InterpResult < ' tcx , ScalarMaybeUninit < Tag > > {
133133 get_at_offset ( ecx, mutex_op, 4 , ecx. machine . layouts . u32 , PTHREAD_MUTEX_T_MIN_SIZE )
134134}
135135
136136fn mutex_set_id < ' mir , ' tcx : ' mir > (
137137 ecx : & mut MiriEvalContext < ' mir , ' tcx > ,
138138 mutex_op : OpTy < ' tcx , Tag > ,
139- id : impl Into < ScalarMaybeUndef < Tag > > ,
139+ id : impl Into < ScalarMaybeUninit < Tag > > ,
140140) -> InterpResult < ' tcx , ( ) > {
141141 set_at_offset ( ecx, mutex_op, 4 , id, ecx. machine . layouts . u32 , PTHREAD_MUTEX_T_MIN_SIZE )
142142}
@@ -176,7 +176,7 @@ fn rwlock_get_id<'mir, 'tcx: 'mir>(
176176fn rwlock_set_id < ' mir , ' tcx : ' mir > (
177177 ecx : & mut MiriEvalContext < ' mir , ' tcx > ,
178178 rwlock_op : OpTy < ' tcx , Tag > ,
179- id : impl Into < ScalarMaybeUndef < Tag > > ,
179+ id : impl Into < ScalarMaybeUninit < Tag > > ,
180180) -> InterpResult < ' tcx , ( ) > {
181181 set_at_offset ( ecx, rwlock_op, 4 , id, ecx. machine . layouts . u32 , PTHREAD_RWLOCK_T_MIN_SIZE )
182182}
@@ -208,14 +208,14 @@ const PTHREAD_CONDATTR_T_MIN_SIZE: u64 = 4;
208208fn condattr_get_clock_id < ' mir , ' tcx : ' mir > (
209209 ecx : & MiriEvalContext < ' mir , ' tcx > ,
210210 attr_op : OpTy < ' tcx , Tag > ,
211- ) -> InterpResult < ' tcx , ScalarMaybeUndef < Tag > > {
211+ ) -> InterpResult < ' tcx , ScalarMaybeUninit < Tag > > {
212212 get_at_offset ( ecx, attr_op, 0 , ecx. machine . layouts . i32 , PTHREAD_CONDATTR_T_MIN_SIZE )
213213}
214214
215215fn condattr_set_clock_id < ' mir , ' tcx : ' mir > (
216216 ecx : & mut MiriEvalContext < ' mir , ' tcx > ,
217217 attr_op : OpTy < ' tcx , Tag > ,
218- clock_id : impl Into < ScalarMaybeUndef < Tag > > ,
218+ clock_id : impl Into < ScalarMaybeUninit < Tag > > ,
219219) -> InterpResult < ' tcx , ( ) > {
220220 set_at_offset ( ecx, attr_op, 0 , clock_id, ecx. machine . layouts . i32 , PTHREAD_CONDATTR_T_MIN_SIZE )
221221}
@@ -234,14 +234,14 @@ const PTHREAD_COND_T_MIN_SIZE: u64 = 12;
234234fn cond_get_id < ' mir , ' tcx : ' mir > (
235235 ecx : & MiriEvalContext < ' mir , ' tcx > ,
236236 cond_op : OpTy < ' tcx , Tag > ,
237- ) -> InterpResult < ' tcx , ScalarMaybeUndef < Tag > > {
237+ ) -> InterpResult < ' tcx , ScalarMaybeUninit < Tag > > {
238238 get_at_offset ( ecx, cond_op, 4 , ecx. machine . layouts . u32 , PTHREAD_COND_T_MIN_SIZE )
239239}
240240
241241fn cond_set_id < ' mir , ' tcx : ' mir > (
242242 ecx : & mut MiriEvalContext < ' mir , ' tcx > ,
243243 cond_op : OpTy < ' tcx , Tag > ,
244- id : impl Into < ScalarMaybeUndef < Tag > > ,
244+ id : impl Into < ScalarMaybeUninit < Tag > > ,
245245) -> InterpResult < ' tcx , ( ) > {
246246 set_at_offset ( ecx, cond_op, 4 , id, ecx. machine . layouts . u32 , PTHREAD_COND_T_MIN_SIZE )
247247}
@@ -265,14 +265,14 @@ fn cond_get_or_create_id<'mir, 'tcx: 'mir>(
265265fn cond_get_clock_id < ' mir , ' tcx : ' mir > (
266266 ecx : & MiriEvalContext < ' mir , ' tcx > ,
267267 cond_op : OpTy < ' tcx , Tag > ,
268- ) -> InterpResult < ' tcx , ScalarMaybeUndef < Tag > > {
268+ ) -> InterpResult < ' tcx , ScalarMaybeUninit < Tag > > {
269269 get_at_offset ( ecx, cond_op, 8 , ecx. machine . layouts . i32 , PTHREAD_COND_T_MIN_SIZE )
270270}
271271
272272fn cond_set_clock_id < ' mir , ' tcx : ' mir > (
273273 ecx : & mut MiriEvalContext < ' mir , ' tcx > ,
274274 cond_op : OpTy < ' tcx , Tag > ,
275- clock_id : impl Into < ScalarMaybeUndef < Tag > > ,
275+ clock_id : impl Into < ScalarMaybeUninit < Tag > > ,
276276) -> InterpResult < ' tcx , ( ) > {
277277 set_at_offset ( ecx, cond_op, 8 , clock_id, ecx. machine . layouts . i32 , PTHREAD_COND_T_MIN_SIZE )
278278}
@@ -518,8 +518,8 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
518518 throw_ub_format ! ( "destroyed a locked mutex" ) ;
519519 }
520520
521- mutex_set_kind ( this, mutex_op, ScalarMaybeUndef :: Undef ) ?;
522- mutex_set_id ( this, mutex_op, ScalarMaybeUndef :: Undef ) ?;
521+ mutex_set_kind ( this, mutex_op, ScalarMaybeUninit :: Uninit ) ?;
522+ mutex_set_id ( this, mutex_op, ScalarMaybeUninit :: Uninit ) ?;
523523
524524 Ok ( 0 )
525525 }
@@ -643,7 +643,7 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
643643 throw_ub_format ! ( "destroyed a locked rwlock" ) ;
644644 }
645645
646- rwlock_set_id ( this, rwlock_op, ScalarMaybeUndef :: Undef ) ?;
646+ rwlock_set_id ( this, rwlock_op, ScalarMaybeUninit :: Uninit ) ?;
647647
648648 Ok ( 0 )
649649 }
@@ -696,7 +696,7 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
696696 fn pthread_condattr_destroy ( & mut self , attr_op : OpTy < ' tcx , Tag > ) -> InterpResult < ' tcx , i32 > {
697697 let this = self . eval_context_mut ( ) ;
698698
699- condattr_set_clock_id ( this, attr_op, ScalarMaybeUndef :: Undef ) ?;
699+ condattr_set_clock_id ( this, attr_op, ScalarMaybeUninit :: Uninit ) ?;
700700
701701 Ok ( 0 )
702702 }
@@ -835,8 +835,8 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
835835 if this. condvar_is_awaited ( id) {
836836 throw_ub_format ! ( "destroyed an awaited conditional variable" ) ;
837837 }
838- cond_set_id ( this, cond_op, ScalarMaybeUndef :: Undef ) ?;
839- cond_set_clock_id ( this, cond_op, ScalarMaybeUndef :: Undef ) ?;
838+ cond_set_id ( this, cond_op, ScalarMaybeUninit :: Uninit ) ?;
839+ cond_set_clock_id ( this, cond_op, ScalarMaybeUninit :: Uninit ) ?;
840840
841841 Ok ( 0 )
842842 }
0 commit comments