1 ; RUN: llc -mtriple=hexagon-- -mcpu=hexagonv5 -relocation-model=pic < %s | FileCheck %s
3 ; CHECK-DAG: r{{[0-9]+}} = add({{pc|PC}},##_GLOBAL_OFFSET_TABLE_@PCREL)
4 ; CHECK-DAG: r{{[0-9]+}} = add({{pc|PC}},##x@PCREL)
5 ; CHECK: r{{[0-9]+}} = memw(r{{[0-9]+}}+##bar@GOT)
7 @x = internal global i32 9, align 4
8 @bar = external global ptr
10 define i32 @foo(i32 %y) nounwind {
12 store ptr @x, ptr @bar, align 4, !tbaa !0
13 %0 = load i32, ptr @x, align 4, !tbaa !3
14 %add = add nsw i32 %0, %y
18 !0 = !{!"any pointer", !1}
19 !1 = !{!"omnipotent char", !2}
20 !2 = !{!"Simple C/C++ TBAA"}