1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=aarch64-apple-darwin -fast-isel -fast-isel-abort=1 -verify-machineinstrs < %s | FileCheck %s
4 ; Test that we don't segfault.
5 define void @test(i64 %a, ptr %b) {
8 ; CHECK-NEXT: ldr x8, [x1]
9 ; CHECK-NEXT: and x9, x0, #0x7fffffffffffffff
10 ; CHECK-NEXT: str x8, [x9]
12 %1 = and i64 %a, 9223372036854775807
13 %2 = inttoptr i64 %1 to ptr
14 call void @llvm.memcpy.p0.p0.i64(ptr align 8 %2, ptr align 8 %b, i64 8, i1 false)
18 declare void @llvm.memcpy.p0.p0.i64(ptr, ptr, i64, i1)