Line 1... |
Line 1... |
/* abstract.c -- Abstract entities
|
/* abstract.c -- Abstract entities
|
|
|
Copyright (C) 1999 Damjan Lampret, lampret@opencores.org
|
Copyright (C) 1999 Damjan Lampret, lampret@opencores.org
|
Copyright (C) 2005 György `nog' Jeney, nog@sdf.lonestar.org
|
Copyright (C) 2005 György `nog' Jeney, nog@sdf.lonestar.org
|
|
Copyright (C) 2008 Embecosm Limited
|
|
|
|
Contributor Jeremy Bennett <jeremy.bennett@embecosm.com>
|
|
|
This file is part of OpenRISC 1000 Architectural Simulator.
|
This file is part of OpenRISC 1000 Architectural Simulator.
|
|
|
This program is free software; you can redistribute it and/or modify
|
This program is free software; you can redistribute it and/or modify it
|
it under the terms of the GNU General Public License as published by
|
under the terms of the GNU General Public License as published by the Free
|
the Free Software Foundation; either version 2 of the License, or
|
Software Foundation; either version 3 of the License, or (at your option)
|
(at your option) any later version.
|
any later version.
|
|
|
This program is distributed in the hope that it will be useful,
|
This program is distributed in the hope that it will be useful, but WITHOUT
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
GNU General Public License for more details.
|
more details.
|
|
|
You should have received a copy of the GNU General Public License
|
You should have received a copy of the GNU General Public License along
|
along with this program; if not, write to the Free Software
|
with this program. If not, see <http://www.gnu.org/licenses/>. */
|
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
|
|
|
/* Abstract memory and routines that go with this. I need to add all sorts of
|
/* Abstract memory and routines that go with this. I need to
|
other abstract entities. Currently we have only memory. */
|
add all sorts of other abstract entities. Currently we have
|
|
only memory. */
|
|
|
|
#include <stdlib.h>
|
#include <stdlib.h>
|
#include <stdio.h>
|
#include <stdio.h>
|
#include <ctype.h>
|
#include <ctype.h>
|
#include <string.h>
|
#include <string.h>
|
Line 490... |
Line 492... |
if (except_pending)
|
if (except_pending)
|
return 0;
|
return 0;
|
#endif
|
#endif
|
|
|
if (config.debug.enabled)
|
if (config.debug.enabled)
|
*breakpoint += CheckDebugUnit(DebugLoadAddress,memaddr);
|
*breakpoint += CheckDebugUnit(DebugInstructionFetch,memaddr);
|
|
|
if(ic_state->enabled)
|
if(ic_state->enabled)
|
temp = ic_simulate_fetch(phys_memaddr, memaddr);
|
temp = ic_simulate_fetch(phys_memaddr, memaddr);
|
else
|
else
|
temp = evalsim_mem32(phys_memaddr, memaddr);
|
temp = evalsim_mem32(phys_memaddr, memaddr);
|