Debian Codegraph @

cmd/bpf2go/testdata/minimal.c

raw symbols SCIP
1 #include "../../../testdata/common.h"
2
3 char __license[] __section("license") = "MIT";
4
5 enum e { HOOPY, FROOD };
6
7 typedef long long int longint;
8
9 typedef struct {
10 longint bar;
11 _Bool baz;
12 enum e boo;
13 } barfoo;
14
15 typedef struct {
16 uint64_t a;
17 } baz;
18
19 struct bar {
20 uint64_t a;
21 uint32_t b;
22 };
23
24 union ubar {
25 uint32_t a;
26 uint64_t b;
27 };
28
29 struct {
30 __uint(type, BPF_MAP_TYPE_HASH);
31 __type(key, enum e);
32 __type(value, barfoo);
33 __uint(max_entries, 1);
34 } map1 __section(".maps");
35
36 volatile const int an_int;
37 volatile const enum e my_constant = FROOD;
38 volatile const int int_array[2];
39 volatile const barfoo struct_const;
40 volatile const baz struct_array[2];
41
42 volatile struct bar struct_var;
43 volatile union ubar union_var;
44
45 __section("socket") int filter() {
46 return my_constant + struct_const.bar;
47 }