diff options
Diffstat (limited to 'src/test/codegen/intrinsics')
-rw-r--r-- | src/test/codegen/intrinsics/mask.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/test/codegen/intrinsics/mask.rs b/src/test/codegen/intrinsics/mask.rs new file mode 100644 index 000000000..2e984db1b --- /dev/null +++ b/src/test/codegen/intrinsics/mask.rs @@ -0,0 +1,11 @@ +#![crate_type = "lib"] +#![feature(core_intrinsics)] + +// CHECK-LABEL: @mask_ptr +// CHECK-SAME: [[WORD:i[0-9]+]] %mask +#[no_mangle] +pub fn mask_ptr(ptr: *const u16, mask: usize) -> *const u16 { + // CHECK: call + // CHECK-SAME: @llvm.ptrmask.{{p0|p0i8}}.[[WORD]]({{ptr|i8\*}} {{%ptr|%0}}, [[WORD]] %mask) + core::intrinsics::ptr_mask(ptr, mask) +} |