| 1 |
// REQUIRES: x86-registered-target |
| 2 |
// RUN: %clang -target x86_64 -g -S -emit-llvm -o - %s | FileCheck %s |
| 3 |
|
| 4 |
#define __tag1 __attribute__((btf_decl_tag("tag1"))) |
| 5 |
#define __tag2 __attribute__((btf_decl_tag("tag2"))) |
| 6 |
|
| 7 |
struct t1 { |
| 8 |
int a; |
| 9 |
}; |
| 10 |
|
| 11 |
int foo(struct t1 __tag1 __tag2 *arg) { |
| 12 |
return arg->a; |
| 13 |
} |
| 14 |
|
| 15 |
// CHECK: !DILocalVariable(name: "arg", arg: 1, scope: ![[#]], file: ![[#]], line: [[#]], type: ![[#]], annotations: ![[ANNOT:[0-9]+]]) |
| 16 |
// CHECK: ![[ANNOT]] = !{![[TAG1:[0-9]+]], ![[TAG2:[0-9]+]]} |
| 17 |
// CHECK: ![[TAG1]] = !{!"btf_decl_tag", !"tag1"} |
| 18 |
// CHECK: ![[TAG2]] = !{!"btf_decl_tag", !"tag2"} |