Debian Codegraph @

flang/test/Integration/debug-allocatable-1.f90

raw
1 ! RUN: %flang_fc1 -emit-llvm -debug-info-kind=standalone %s -o - | FileCheck %s
2
3 subroutine ff(n, m)
4 integer n, m, i, j
5 integer, allocatable :: ar1(:, :)
6 real, allocatable :: sc
7
8 allocate(ar1(n, m))
9 allocate(sc)
10 sc = 3.14
11
12 print *, sc
13 print *, ar1
14 end subroutine ff
15
16
17 ! CHECK-DAG: !DILocalVariable(name: "ar1"{{.*}}type: ![[TY1:[0-9]+]])
18 ! CHECK-DAG: ![[TY1]] = !DICompositeType(tag: DW_TAG_array_type{{.*}}elements: ![[ELEMS2:[0-9]+]]{{.*}}dataLocation{{.*}}allocated: !DIExpression(DW_OP_push_object_address, DW_OP_deref, DW_OP_lit0, DW_OP_ne))
19 ! CHECK-DAG: ![[ELEMS2]] = !{![[ELEM1:[0-9]+]], ![[ELEM2:[0-9]+]]}
20 ! CHECK-DAG: ![[ELEM1]] = !DISubrange
21 ! CHECK-DAG: ![[ELEM2]] = !DISubrange
22 ! CHECK-DAG: !DILocalVariable(name: "sc"{{.*}}type: ![[TY2:[0-9]+]])
23 ! CHECK-DAG: ![[TY2]] = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: ![[TY3:[0-9]+]]{{.*}})
24 ! CHECK-DAG: ![[TY3]] = !DIBasicType(name: "real"{{.*}})