@@ -175,7 +175,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
175175 | MemorySemantics :: SEQUENTIALLY_CONSISTENT
176176 }
177177 } ;
178- let semantics = self . constant_bit32 ( self . span ( ) , semantics. bits ( ) ) ;
178+ let semantics = self . constant_u32 ( self . span ( ) , semantics. bits ( ) ) ;
179179 if invalid_seq_cst {
180180 self . zombie (
181181 semantics. def ( self ) ,
@@ -196,10 +196,10 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
196196 . constant_u16 ( self . span ( ) , memset_fill_u16 ( fill_byte) )
197197 . def ( self ) ,
198198 32 => self
199- . constant_bit32 ( self . span ( ) , memset_fill_u32 ( fill_byte) )
199+ . constant_u32 ( self . span ( ) , memset_fill_u32 ( fill_byte) )
200200 . def ( self ) ,
201201 64 => self
202- . constant_bit64 ( self . span ( ) , memset_fill_u64 ( fill_byte) )
202+ . constant_u64 ( self . span ( ) , memset_fill_u64 ( fill_byte) )
203203 . def ( self ) ,
204204 _ => self . fatal ( format ! (
205205 "memset on integer width {width} not implemented yet"
@@ -314,7 +314,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
314314 self . store ( pat, ptr, Align :: from_bytes ( 0 ) . unwrap ( ) ) ;
315315 } else {
316316 for index in 0 ..count {
317- let const_index = self . constant_bit32 ( self . span ( ) , index as u32 ) ;
317+ let const_index = self . constant_u32 ( self . span ( ) , index as u32 ) ;
318318 let gep_ptr = self . gep ( pat. ty , ptr, & [ const_index] ) ;
319319 self . store ( pat, gep_ptr, Align :: from_bytes ( 0 ) . unwrap ( ) ) ;
320320 }
@@ -431,7 +431,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
431431 } else {
432432 let indices = indices
433433 . into_iter ( )
434- . map ( |idx| self . constant_bit32 ( self . span ( ) , idx) . def ( self ) )
434+ . map ( |idx| self . constant_u32 ( self . span ( ) , idx) . def ( self ) )
435435 . collect :: < Vec < _ > > ( ) ;
436436 self . emit ( )
437437 . in_bounds_access_chain ( leaf_ptr_ty, None , ptr. def ( self ) , indices)
@@ -614,7 +614,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
614614 } ;
615615 let indices = base_indices
616616 . into_iter ( )
617- . map ( |idx| self . constant_bit32 ( self . span ( ) , idx) . def ( self ) )
617+ . map ( |idx| self . constant_u32 ( self . span ( ) , idx) . def ( self ) )
618618 . chain ( indices)
619619 . collect ( ) ;
620620 return self . emit_access_chain (
@@ -1478,7 +1478,7 @@ impl<'a, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'tcx> {
14781478 let ( ptr, access_ty) = self . adjust_pointer_for_typed_access ( ptr, ty) ;
14791479
14801480 // TODO: Default to device scope
1481- let memory = self . constant_bit32 ( self . span ( ) , Scope :: Device as u32 ) ;
1481+ let memory = self . constant_u32 ( self . span ( ) , Scope :: Device as u32 ) ;
14821482 let semantics = self . ordering_to_semantics_def ( order) ;
14831483 let result = self
14841484 . emit ( )
@@ -1611,7 +1611,7 @@ impl<'a, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'tcx> {
16111611 let val = self . bitcast ( val, access_ty) ;
16121612
16131613 // TODO: Default to device scope
1614- let memory = self . constant_bit32 ( self . span ( ) , Scope :: Device as u32 ) ;
1614+ let memory = self . constant_u32 ( self . span ( ) , Scope :: Device as u32 ) ;
16151615 let semantics = self . ordering_to_semantics_def ( order) ;
16161616 self . validate_atomic ( val. ty , ptr. def ( self ) ) ;
16171617 self . emit ( )
@@ -1944,7 +1944,7 @@ impl<'a, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'tcx> {
19441944 ) {
19451945 let indices = indices
19461946 . into_iter ( )
1947- . map ( |idx| self . constant_bit32 ( self . span ( ) , idx) . def ( self ) )
1947+ . map ( |idx| self . constant_u32 ( self . span ( ) , idx) . def ( self ) )
19481948 . collect :: < Vec < _ > > ( ) ;
19491949 self . emit ( )
19501950 . in_bounds_access_chain ( dest_ty, None , ptr. def ( self ) , indices)
@@ -2495,7 +2495,7 @@ impl<'a, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'tcx> {
24952495
24962496 self . validate_atomic ( access_ty, dst. def ( self ) ) ;
24972497 // TODO: Default to device scope
2498- let memory = self . constant_bit32 ( self . span ( ) , Scope :: Device as u32 ) ;
2498+ let memory = self . constant_u32 ( self . span ( ) , Scope :: Device as u32 ) ;
24992499 let semantics_equal = self . ordering_to_semantics_def ( order) ;
25002500 let semantics_unequal = self . ordering_to_semantics_def ( failure_order) ;
25012501 // Note: OpAtomicCompareExchangeWeak is deprecated, and has the same semantics
@@ -2535,7 +2535,7 @@ impl<'a, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'tcx> {
25352535 self . validate_atomic ( access_ty, dst. def ( self ) ) ;
25362536 // TODO: Default to device scope
25372537 let memory = self
2538- . constant_bit32 ( self . span ( ) , Scope :: Device as u32 )
2538+ . constant_u32 ( self . span ( ) , Scope :: Device as u32 )
25392539 . def ( self ) ;
25402540 let semantics = self . ordering_to_semantics_def ( order) . def ( self ) ;
25412541 use AtomicRmwBinOp :: * ;
@@ -2631,7 +2631,7 @@ impl<'a, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'tcx> {
26312631 // Ignore sync scope (it only has "single thread" and "cross thread")
26322632 // TODO: Default to device scope
26332633 let memory = self
2634- . constant_bit32 ( self . span ( ) , Scope :: Device as u32 )
2634+ . constant_u32 ( self . span ( ) , Scope :: Device as u32 )
26352635 . def ( self ) ;
26362636 let semantics = self . ordering_to_semantics_def ( order) . def ( self ) ;
26372637 self . emit ( ) . memory_barrier ( memory, semantics) . unwrap ( ) ;
0 commit comments