Rollup merge of #145705 - folkertdev:prefetch-remove-as-cast, r=RalfJung
remove an `as` cast in prefetch codegen r? `@RalfJung`
This commit is contained in:
@@ -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)],
|
||||
|
||||
Reference in New Issue
Block a user