aboutsummaryrefslogtreecommitdiff
path: root/sim/erc32/interf.c
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@oarcorp.com>2010-05-11 14:18:20 +0000
committerJoel Sherrill <joel.sherrill@oarcorp.com>2010-05-11 14:18:20 +0000
commit941100245a42cb730b23ff0f6889265e2e5f9e2f (patch)
treeb86032d14d811fd2fad3ad74257ea4cd71b14350 /sim/erc32/interf.c
parent3390ce3004b151603ed765692601af7050fa53fd (diff)
downloadfsf-binutils-gdb-941100245a42cb730b23ff0f6889265e2e5f9e2f.zip
fsf-binutils-gdb-941100245a42cb730b23ff0f6889265e2e5f9e2f.tar.gz
fsf-binutils-gdb-941100245a42cb730b23ff0f6889265e2e5f9e2f.tar.bz2
2010-04-20 Tiemen Schut <T.Schut@sron.nl>
* erc32.c (sis_memory_write): Change prototype to const unsigned char *. * func.c (exec_cmd, event, advance_time, wait_for_irq): Use uint64 for counts. * interf.c (run_sim): Change icount to uint64_t. Use strtol directly. (sim_resume): Specify maximum run time as uint64. * sis.c (run_sim): Change icount to uint64_t. * sis.h: Define uint64 as uint64_t. Change various fields and prototypes to uint64 to support longer simulations.
Diffstat (limited to 'sim/erc32/interf.c')
-rw-r--r--sim/erc32/interf.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sim/erc32/interf.c b/sim/erc32/interf.c
index c7ffa99..edba534 100644
--- a/sim/erc32/interf.c
+++ b/sim/erc32/interf.c
@@ -37,8 +37,6 @@
#define PSR_CWP 0x7
-#define VAL(x) strtol(x,(char **)NULL,0)
-
extern struct disassemble_info dinfo;
extern struct pstate sregs;
extern struct estate ebase;
@@ -69,7 +67,7 @@ host_callback *sim_callback;
int
run_sim(sregs, icount, dis)
struct pstate *sregs;
- unsigned int icount;
+ uint64 icount;
int dis;
{
int mexc, irq;
@@ -234,7 +232,7 @@ sim_open (kind, callback, abfd, argv)
} else
if (strcmp(argv[stat], "-freq") == 0) {
if ((stat + 1) < argc) {
- freq = VAL(argv[++stat]);
+ freq = strtol(argv[++stat], (char **)NULL, 0);
}
} else {
(*sim_callback->printf_filtered) (sim_callback,
@@ -461,7 +459,7 @@ flush_windows ()
void
sim_resume(SIM_DESC sd, int step, int siggnal)
{
- simstat = run_sim(&sregs, -1, 0);
+ simstat = run_sim(&sregs, UINT64_MAX, 0);
if (sis_gdb_break) flush_windows ();
}