Skip to content

Commit

Permalink
Ensure AUTH_CALL is not emitted when ptrauth subtarget feature is mis…
Browse files Browse the repository at this point in the history
…sing
  • Loading branch information
kovdan01 committed Dec 7, 2023
1 parent 81cb742 commit 3821445
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions llvm/test/CodeGen/AArch64/GlobalISel/ptrauth-lowering-err.ll
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,17 @@ define i32 @foo() {
}

attributes #0 = { "ptrauth-returns" "target-cpu"="generic" }

;--- auth-call.ll

; RUN: not --crash llc -mtriple aarch64-elf auth-call.ll 2>&1 | \
; RUN: FileCheck auth-call.ll

; CHECK: LLVM ERROR: Cannot select:{{.*}}AArch64ISD::AUTH_CALL

define void @bar(ptr %foo) #0 {
call void %foo() [ "ptrauth"(i32 0, i64 0) ]
ret void
}

attributes #0 = { "ptrauth-calls" "target-cpu"="generic" }

0 comments on commit 3821445

Please sign in to comment.