16ca2c52aSchristos /* Moxie Simulator definition. 2*184b2d41Schristos Copyright (C) 2009-2020 Free Software Foundation, Inc. 36ca2c52aSchristos Contributed by Anthony Green <green@moxielogic.com> 46ca2c52aSchristos 56ca2c52aSchristos This file is part of GDB, the GNU debugger. 66ca2c52aSchristos 76ca2c52aSchristos This program is free software; you can redistribute it and/or modify 86ca2c52aSchristos it under the terms of the GNU General Public License as published by 96ca2c52aSchristos the Free Software Foundation; either version 3 of the License, or 106ca2c52aSchristos (at your option) any later version. 116ca2c52aSchristos 126ca2c52aSchristos This program is distributed in the hope that it will be useful, 136ca2c52aSchristos but WITHOUT ANY WARRANTY; without even the implied warranty of 146ca2c52aSchristos MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 156ca2c52aSchristos GNU General Public License for more details. 166ca2c52aSchristos 176ca2c52aSchristos You should have received a copy of the GNU General Public License 186ca2c52aSchristos along with this program. If not, see <http://www.gnu.org/licenses/>. */ 196ca2c52aSchristos 206ca2c52aSchristos #ifndef SIM_MAIN_H 216ca2c52aSchristos #define SIM_MAIN_H 226ca2c52aSchristos 236ca2c52aSchristos #include "sim-basics.h" 246ca2c52aSchristos #include "sim-base.h" 256ca2c52aSchristos #include "bfd.h" 266ca2c52aSchristos 276ca2c52aSchristos #define PCIDX 17 286ca2c52aSchristos 296ca2c52aSchristos struct _sim_cpu { 306ca2c52aSchristos 316ca2c52aSchristos /* The following are internal simulator state variables: */ 326ca2c52aSchristos 336ca2c52aSchristos /* To keep this default simulator simple, and fast, we use a direct 346ca2c52aSchristos vector of registers. The internal simulator engine then uses 356ca2c52aSchristos manifests to access the correct slot. */ 366ca2c52aSchristos 376ca2c52aSchristos unsigned_word registers[19]; 386ca2c52aSchristos 396ca2c52aSchristos sim_cpu_base base; 406ca2c52aSchristos }; 416ca2c52aSchristos 426ca2c52aSchristos struct sim_state { 436ca2c52aSchristos 446ca2c52aSchristos sim_cpu *cpu[MAX_NR_PROCESSORS]; 456ca2c52aSchristos 466ca2c52aSchristos sim_state_base base; 476ca2c52aSchristos }; 486ca2c52aSchristos 496ca2c52aSchristos #endif 50