diff options
| author | Folkert de Vries <folkert@folkertdev.nl> | 2025-08-21 11:28:10 +0200 |
|---|---|---|
| committer | Folkert de Vries <folkert@folkertdev.nl> | 2025-08-21 11:28:10 +0200 |
| commit | b32f4d5792ebff7c734114488184a5b72516a187 (patch) | |
| tree | e9b5d78479d634d18963a59a9737301b3f444879 | |
| parent | 922958cffe059e9c156835df19d199ccd861c36a (diff) | |
| download | rust-b32f4d5792ebff7c734114488184a5b72516a187.tar.gz rust-b32f4d5792ebff7c734114488184a5b72516a187.zip | |
remove an `as` cast in prefetch codegen
| -rw-r--r-- | compiler/rustc_codegen_llvm/src/intrinsic.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_llvm/src/intrinsic.rs b/compiler/rustc_codegen_llvm/src/intrinsic.rs index 06c3d8ed6bc..49d3dedbeab 100644 --- a/compiler/rustc_codegen_llvm/src/intrinsic.rs +++ b/compiler/rustc_codegen_llvm/src/intrinsic.rs @@ -330,7 +330,7 @@ impl<'ll, 'tcx> IntrinsicCallBuilderMethods<'tcx> for Builder<'_, 'll, 'tcx> { _ => bug!(), }; let ptr = args[0].immediate(); - let locality = fn_args.const_at(1).to_value().valtree.unwrap_leaf().to_u32() as i32; + let locality = fn_args.const_at(1).to_value().valtree.unwrap_leaf().to_i32(); self.call_intrinsic( "llvm.prefetch", &[self.val_ty(ptr)], |
