Skip to content

Commit 765274b

Browse files
committed
Fix provenance intrinsics
1 parent d14f440 commit 765274b

File tree

4 files changed

+13
-14
lines changed

4 files changed

+13
-14
lines changed

Cargo.lock

Lines changed: 2 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ master = ["gccjit/master"]
2222
default = ["master"]
2323

2424
[dependencies]
25-
gccjit = "2.0"
25+
#gccjit = "2.0"
26+
gccjit = { git = "https://github.com/rust-lang/gccjit.rs" }
2627

2728
# Local copy.
2829
#gccjit = { path = "../gccjit.rs" }

rust-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[toolchain]
2-
channel = "nightly-2024-03-10"
2+
channel = "nightly-2024-06-18"
33
components = ["rust-src", "rustc-dev", "llvm-tools-preview"]

src/intrinsic/simd.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -452,8 +452,8 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
452452
);
453453

454454
match *in_elem.kind() {
455-
ty::RawPtr(p) => {
456-
let metadata = p.ty.ptr_metadata_ty(bx.tcx, |ty| {
455+
ty::RawPtr(p_ty, _) => {
456+
let metadata = p_ty.ptr_metadata_ty(bx.tcx, |ty| {
457457
bx.tcx.normalize_erasing_regions(ty::ParamEnv::reveal_all(), ty)
458458
});
459459
require!(
@@ -466,8 +466,8 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
466466
}
467467
}
468468
match *out_elem.kind() {
469-
ty::RawPtr(p) => {
470-
let metadata = p.ty.ptr_metadata_ty(bx.tcx, |ty| {
469+
ty::RawPtr(p_ty, _) => {
470+
let metadata = p_ty.ptr_metadata_ty(bx.tcx, |ty| {
471471
bx.tcx.normalize_erasing_regions(ty::ParamEnv::reveal_all(), ty)
472472
});
473473
require!(
@@ -492,7 +492,7 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
492492
return Ok(bx.context.new_rvalue_from_vector(bx.location, llret_ty, &values));
493493
}
494494

495-
if name == sym::simd_expose_addr {
495+
if name == sym::simd_expose_provenance {
496496
require_simd!(ret_ty, InvalidMonomorphization::SimdReturn { span, name, ty: ret_ty });
497497
let (out_len, out_elem) = ret_ty.simd_size_and_type(bx.tcx());
498498

@@ -509,7 +509,7 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
509509
);
510510

511511
match *in_elem.kind() {
512-
ty::RawPtr(_) => {}
512+
ty::RawPtr(_, _) => {}
513513
_ => {
514514
return_error!(InvalidMonomorphization::ExpectedPointer { span, name, ty: in_elem })
515515
}
@@ -531,7 +531,7 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
531531
return Ok(bx.context.new_rvalue_from_vector(bx.location, llret_ty, &values));
532532
}
533533

534-
if name == sym::simd_from_exposed_addr {
534+
if name == sym::simd_with_exposed_provenance {
535535
require_simd!(ret_ty, InvalidMonomorphization::SimdReturn { span, name, ty: ret_ty });
536536
let (out_len, out_elem) = ret_ty.simd_size_and_type(bx.tcx());
537537

@@ -552,7 +552,7 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
552552
_ => return_error!(InvalidMonomorphization::ExpectedUsize { span, name, ty: in_elem }),
553553
}
554554
match *out_elem.kind() {
555-
ty::RawPtr(_) => {}
555+
ty::RawPtr(_, _) => {}
556556
_ => {
557557
return_error!(InvalidMonomorphization::ExpectedPointer { span, name, ty: out_elem })
558558
}

0 commit comments

Comments
 (0)