Update copyright year range in header of all files managed by GDB
[binutils-gdb.git] / sim / lm32 / sim-main.h
blobd7590e4fbd72c12d62d61cb8324bba2e5e692dde
1 /* Lattice Mico32 simulator support code
2 Contributed by Jon Beniston <jon@beniston.com>
4 Copyright (C) 2009-2023 Free Software Foundation, Inc.
6 This file is part of GDB.
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 3 of the License, or
11 (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>. */
21 /* Main header for the LM32 simulator. */
23 #ifndef SIM_MAIN_H
24 #define SIM_MAIN_H
26 #define WITH_SCACHE_PBB 1
28 #include "sim-basics.h"
29 #include "lm32-desc.h"
30 #include "lm32-opc.h"
31 #include "arch.h"
32 #include "sim-base.h"
33 #include "cgen-sim.h"
34 #include "lm32-sim.h"
36 struct lm32_sim_cpu
38 /* CPU specific parts go here.
39 Note that in files that don't need to access these pieces WANT_CPU_FOO
40 won't be defined and thus these parts won't appear. This is ok in the
41 sense that things work. It is a source of bugs though.
42 One has to of course be careful to not take the size of this
43 struct and no structure members accessed in non-cpu specific files can
44 go after here. Oh for a better language. */
45 #if defined (WANT_CPU_LM32BF)
46 LM32BF_CPU_DATA cpu_data;
47 #endif
49 #define LM32_SIM_CPU(cpu) ((struct lm32_sim_cpu *) CPU_ARCH_DATA (cpu))
51 /* Misc. */
53 /* Catch address exceptions. */
54 extern SIM_CORE_SIGNAL_FN lm32_core_signal;
55 #define SIM_CORE_SIGNAL(SD,CPU,CIA,MAP,NR_BYTES,ADDR,TRANSFER,ERROR) \
56 lm32_core_signal ((SD), (CPU), (CIA), (MAP), (NR_BYTES), (ADDR), \
57 (TRANSFER), (ERROR))
59 #endif /* SIM_MAIN_H */