Skip to content

Commit 03fbcdb

Browse files
authored
Rollup merge of #145705 - folkertdev:prefetch-remove-as-cast, r=RalfJung
remove an `as` cast in prefetch codegen r? `@RalfJung`
2 parents 0fcf80c + b32f4d5 commit 03fbcdb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_codegen_llvm/src/intrinsic.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ impl<'ll, 'tcx> IntrinsicCallBuilderMethods<'tcx> for Builder<'_, 'll, 'tcx> {
330330
_ => bug!(),
331331
};
332332
let ptr = args[0].immediate();
333-
let locality = fn_args.const_at(1).to_value().valtree.unwrap_leaf().to_u32() as i32;
333+
let locality = fn_args.const_at(1).to_value().valtree.unwrap_leaf().to_i32();
334334
self.call_intrinsic(
335335
"llvm.prefetch",
336336
&[self.val_ty(ptr)],

0 commit comments

Comments
 (0)