X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=sim%2Favr%2Fsim-main.h;h=c82b592400d6a645293892c4cbc11eda5ecfcdb7;hb=87f83f20023bf366c14ec4e0fd307948d96caaee;hp=02c76d3e10c6870d3aa39ac059cb7f8ccea348d9;hpb=9943d3185abb9aa3e7269ece80d00e9020187ec6;p=deliverable%2Fbinutils-gdb.git diff --git a/sim/avr/sim-main.h b/sim/avr/sim-main.h index 02c76d3e10..c82b592400 100644 --- a/sim/avr/sim-main.h +++ b/sim/avr/sim-main.h @@ -1,5 +1,5 @@ /* Moxie Simulator definition. - Copyright (C) 2009-2015 Free Software Foundation, Inc. + Copyright (C) 2009-2020 Free Software Foundation, Inc. This file is part of GDB, the GNU debugger. @@ -19,33 +19,25 @@ along with this program. If not, see . */ #ifndef SIM_MAIN_H #define SIM_MAIN_H -#define SIM_HAVE_BIENDIAN - #include "sim-basics.h" -typedef address_word sim_cia; -extern unsigned int pc; - -#define CIA_GET(cpu) pc -#define CIA_SET(cpu,val) (pc) = (val) - -typedef struct _sim_cpu SIM_CPU; - #include "sim-base.h" struct _sim_cpu { + /* The only real register. */ + uint32_t pc; + + /* We update a cycle counter. */ + uint32_t cycles; sim_cpu_base base; }; struct sim_state { - sim_cpu *cpu[MAX_NR_PROCESSORS]; -#if (WITH_SMP) -#define STATE_CPU(sd,n) ((sd)->cpu[n]) -#else -#define STATE_CPU(sd,n) ((sd)->cpu[0]) -#endif + + /* If true, the pc needs more than 2 bytes. */ + int avr_pc22; sim_state_base base; };