Ensure that libbacktrace/allocfail.sh is not deleted when creating release tarballs.
[binutils-gdb.git] / sim / bpf / sim-main.h
blob6529b6eeda3bcdbf7753ac3fdf9d3f0db086ebcf
1 /* eBPF simulator main header
2 Copyright (C) 2020-2022 Free Software Foundation, Inc.
4 This file is part of GDB, the GNU debugger.
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 3 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program. If not, see <http://www.gnu.org/licenses/>. */
19 #ifndef SIM_MAIN_H
20 #define SIM_MAIN_H
22 #include "sim-basics.h"
23 #include "bpf-desc.h"
24 #include "bpf-opc.h"
25 #include "arch.h"
26 #include "sim-base.h"
27 #include "cgen-sim.h"
28 #include "bpf-sim.h"
29 #include "bpf-helpers.h"
31 struct bpf_sim_cpu
33 /* CPU-model specific parts go here.
34 Note that in files that don't need to access these pieces WANT_CPU_FOO
35 won't be defined and thus these parts won't appear. This is ok in the
36 sense that things work. It is a source of bugs though.
37 One has to of course be careful to not take the size of this
38 struct and no structure members accessed in non-cpu specific files can
39 go after here. */
40 #if defined (WANT_CPU_BPFBF)
41 BPFBF_CPU_DATA cpu_data;
42 #endif
44 #define BPF_SIM_CPU(cpu) ((struct bpf_sim_cpu *) CPU_ARCH_DATA (cpu))
46 #endif /* ! SIM_MAIN_H */