1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple arm64e-apple-darwin -verify-machineinstrs -global-isel=0 | FileCheck %s
3 ; RUN: llc < %s -mtriple arm64e-apple-darwin -verify-machineinstrs -global-isel=1 -global-isel-abort=1 | FileCheck %s
5 define i64 @test_sign_ia(i64 %arg, i64 %arg1) {
6 ; CHECK-LABEL: test_sign_ia:
8 ; CHECK-NEXT: pacia x0, x1
10 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 0, i64 %arg1)
14 define i64 @test_sign_ia_zero(i64 %arg) {
15 ; CHECK-LABEL: test_sign_ia_zero:
17 ; CHECK-NEXT: paciza x0
19 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 0, i64 0)
23 define i64 @test_sign_ib(i64 %arg, i64 %arg1) {
24 ; CHECK-LABEL: test_sign_ib:
26 ; CHECK-NEXT: pacib x0, x1
28 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 1, i64 %arg1)
32 define i64 @test_sign_ib_zero(i64 %arg) {
33 ; CHECK-LABEL: test_sign_ib_zero:
35 ; CHECK-NEXT: pacizb x0
37 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 1, i64 0)
41 define i64 @test_sign_da(i64 %arg, i64 %arg1) {
42 ; CHECK-LABEL: test_sign_da:
44 ; CHECK-NEXT: pacda x0, x1
46 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 2, i64 %arg1)
50 define i64 @test_sign_da_zero(i64 %arg) {
51 ; CHECK-LABEL: test_sign_da_zero:
53 ; CHECK-NEXT: pacdza x0
55 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 2, i64 0)
59 define i64 @test_sign_db(i64 %arg, i64 %arg1) {
60 ; CHECK-LABEL: test_sign_db:
62 ; CHECK-NEXT: pacdb x0, x1
64 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 3, i64 %arg1)
68 define i64 @test_sign_db_zero(i64 %arg) {
69 ; CHECK-LABEL: test_sign_db_zero:
71 ; CHECK-NEXT: pacdzb x0
73 %tmp = call i64 @llvm.ptrauth.sign(i64 %arg, i32 3, i64 0)
77 declare i64 @llvm.ptrauth.sign(i64, i32, i64)