Add a baseline test for llvm.annotation IR upgrade

This will be overloaded in the next commit.
This commit is contained in:
Alex Richardson 2022-11-25 16:00:04 +00:00
parent 53445f5b1c
commit e114979dce
4 changed files with 17 additions and 0 deletions

View File

@ -0,0 +1,15 @@
; Test upgrade of llvm.annotation intrinsics.
;
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
; RUN: llvm-dis < %s.bc | FileCheck %s
; CHECK: define i32 @f(i32 [[ARG0:%.*]], i8* [[ARG1:%.*]], i8* [[ARG2:%.*]], i32 [[ARG3:%.*]])
define i32 @f(i32 %arg0, i8* %arg1, i8* %arg2, i32 %arg3) {
%result = call i32 @llvm.annotation.i32(i32 %arg0, i8* %arg1, i8* %arg2, i32 %arg3)
; CHECK: [[RESULT:%.*]] = call i32 @llvm.annotation.i32(i32 [[ARG0]], i8* [[ARG1]], i8* [[ARG2]], i32 [[ARG3]])
ret i32 %result
}
declare i32 @llvm.annotation.i32(i32, i8*, i8*, i32)
; CHECK: declare i32 @llvm.annotation.i32(i32, i8*, i8*, i32)

Binary file not shown.

View File

@ -1,5 +1,6 @@
; Test upgrade of ptr.annotation intrinsics.
;
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
; RUN: llvm-dis < %s.bc | FileCheck %s
; Unused return values

View File

@ -1,5 +1,6 @@
; Test upgrade of var.annotation intrinsics.
;
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
; RUN: llvm-dis < %s.bc | FileCheck %s