aboutsummaryrefslogtreecommitdiff
path: root/sim/w65/interp.c
diff options
context:
space:
mode:
Diffstat (limited to 'sim/w65/interp.c')
-rw-r--r--sim/w65/interp.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/sim/w65/interp.c b/sim/w65/interp.c
index f2080de..6416b25 100644
--- a/sim/w65/interp.c
+++ b/sim/w65/interp.c
@@ -360,14 +360,18 @@ sim_load (prog, from_tty)
void
-sim_create_inferior (start_address, argv, env)
- SIM_ADDR start_address;
+sim_create_inferior (abfd, argv, env)
+ struct _bfd *abfd;
char **argv;
char **env;
{
- /* ??? We assume this is a 4 byte quantity. */
+ SIM_ADDR start_address;
int pc;
-
+ if (abfd != NULL)
+ start_address = bfd_get_start_address (abfd);
+ else
+ start_address = 0; /*??*/
+ /* ??? We assume this is a 4 byte quantity. */
pc = start_address;
sim_store_register (16, (unsigned char *) &pc);
}