1 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --function-signature --check-attributes --check-globals
2 ; RUN: opt -aa-pipeline=basic-aa -passes=attributor -attributor-manifest-internal -attributor-annotate-decl-cs -S < %s | FileCheck %s --check-prefixes=CHECK,TUNIT
3 ; RUN: opt -aa-pipeline=basic-aa -passes=attributor-cgscc -attributor-manifest-internal -attributor-annotate-decl-cs -S < %s | FileCheck %s --check-prefixes=CHECK,CGSCC
5 @_ZL6test1g = internal global i32 42, align 4
8 ; CHECK: @_ZL6test1g = internal global i32 42, align 4
10 define void @_Z7test1f1v() nounwind {
11 ; CHECK: Function Attrs: mustprogress nofree norecurse nosync nounwind willreturn memory(none)
12 ; CHECK-LABEL: define {{[^@]+}}@_Z7test1f1v
13 ; CHECK-SAME: () #[[ATTR0:[0-9]+]] {
15 ; CHECK-NEXT: br label [[IF_END:%.*]]
17 ; CHECK-NEXT: unreachable
19 ; CHECK-NEXT: ret void
22 %tmp = load i32, ptr @_ZL6test1g, align 4
23 %cmp = icmp eq i32 %tmp, 0
24 br i1 %cmp, label %if.then, label %if.end
26 if.then: ; preds = %entry
27 store i32 0, ptr @_ZL6test1g, align 4
30 if.end: ; preds = %if.then, %entry
34 define i32 @_Z7test1f2v() nounwind {
35 ; CHECK: Function Attrs: mustprogress nofree norecurse nosync nounwind willreturn memory(none)
36 ; CHECK-LABEL: define {{[^@]+}}@_Z7test1f2v
37 ; CHECK-SAME: () #[[ATTR0]] {
39 ; CHECK-NEXT: ret i32 42
42 %tmp = load i32, ptr @_ZL6test1g, align 4
46 ; CHECK: attributes #[[ATTR0]] = { mustprogress nofree norecurse nosync nounwind willreturn memory(none) }
48 ;; NOTE: These prefixes are unused and the list is autogenerated. Do not add tests below this line: