forked from Imagelibrary/binutils-gdb
* Make-common.in (CGEN_INCLUDE_DEPS): Add cgen-defs.h, cgen-engine.h.
(CGEN_MAIN_SCM): Add rtx-funcs.scm.
(cgen-arch): Pass $(mach) to cgen.sh.
* cgen-engine.h (SEM_BRANCH_FINI): New arg pcvar, all uses updated.
(SEM_BRANCH_INIT_EXTRACT): New macro.
(SEM_BRANCH_INIT): Add taken_p.
(TARGET_SEM_BRANCH_FINI): Provide default definition.
(SEM_BRANCH_FINI): Use it.
(SEM_INSN): Update.
* cgen-run.c (sim_resume): Handle tracing of last insn.
* cgen-scache.h (WITH_SCACHE): Define as 0 if not defined.
* cgen-trace.c (current_abuf): New static global.
(trace_insn_init): Initialize it.
(trace_insn_fini): Use it.
(trace_insn): Set it.
* cgen.sh (arch case): Pass -m ${mach} to cgen.
* genmloop.sh (@cpu@_emit_before): Only define if WITH_SCACHE_PBB.
(@cpu@_emit_after): Ditto.
(simple @cpu@_engine_run_full): New local `pc'. Initialize semantic
labels if WITH_SEM_SWITCH_FULL.
* sim-model.c: Include bfd.h.
(sim_model_init): New function.
(sim_model_install): Record init fn.
* sim-model.h (MACH): New member bfd_name.
* sim-module.c (modules): Initialize model before scache.
This commit is contained in:
@@ -23,11 +23,9 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
#include "sim-options.h"
|
||||
#include "sim-assert.h"
|
||||
|
||||
/* start-sanitize-am30 */
|
||||
#if WITH_HW
|
||||
#include "sim-hw.h"
|
||||
#endif
|
||||
/* end-sanitize-am30 */
|
||||
|
||||
#include "libiberty.h"
|
||||
|
||||
@@ -52,20 +50,18 @@ static MODULE_INSTALL_FN * const modules[] = {
|
||||
#if WITH_WATCHPOINTS
|
||||
sim_watchpoint_install,
|
||||
#endif
|
||||
#if WITH_SCACHE
|
||||
scache_install,
|
||||
#endif
|
||||
#ifdef SIM_HAVE_MODEL
|
||||
sim_model_install,
|
||||
#endif
|
||||
#if WITH_SCACHE
|
||||
scache_install,
|
||||
#endif
|
||||
#ifdef SIM_HAVE_BREAKPOINTS
|
||||
sim_break_install,
|
||||
#endif
|
||||
/* start-sanitize-am30 */
|
||||
#if WITH_HW
|
||||
sim_hw_install,
|
||||
#endif
|
||||
/* end-sanitize-am30 */
|
||||
/* Configured in [simulator specific] additional modules. */
|
||||
#ifdef MODULE_LIST
|
||||
MODULE_LIST
|
||||
@@ -116,9 +112,6 @@ sim_post_argv_init (SIM_DESC sd)
|
||||
SIM_ASSERT (STATE_MAGIC (sd) == SIM_MAGIC_NUMBER);
|
||||
SIM_ASSERT (STATE_MODULES (sd) != NULL);
|
||||
|
||||
if (sim_module_init (sd) != SIM_RC_OK)
|
||||
return SIM_RC_FAIL;
|
||||
|
||||
/* Set the cpu->state backlinks for each cpu. */
|
||||
for (i = 0; i < MAX_NR_PROCESSORS; ++i)
|
||||
{
|
||||
@@ -126,6 +119,9 @@ sim_post_argv_init (SIM_DESC sd)
|
||||
CPU_INDEX (STATE_CPU (sd, i)) = i;
|
||||
}
|
||||
|
||||
if (sim_module_init (sd) != SIM_RC_OK)
|
||||
return SIM_RC_FAIL;
|
||||
|
||||
return SIM_RC_OK;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user