GNU Binutils with patches for OS216
修訂 | d320201dbe5a3677e96008738cb6cc754147e3bd (tree) |
---|---|
時間 | 2015-11-22 14:53:23 |
作者 | Mike Frysinger <vapier@gent...> |
Commiter | Mike Frysinger |
sim: mn10300: drop global callback handle
It's used in one place and can easily be replaced by using the sim state.
@@ -1,3 +1,10 @@ | ||
1 | +2015-11-21 Mike Frysinger <vapier@gentoo.org> | |
2 | + | |
3 | + * interp.c (mn10300_callback): Delete. | |
4 | + (sim_open): Delete mn10300_callback assignment. | |
5 | + (program_interrupt): Call sim_io_printf. | |
6 | + * mn10300_sim.h (mn10300_callback): Delete. | |
7 | + | |
1 | 8 | 2015-11-17 Mike Frysinger <vapier@gentoo.org> |
2 | 9 | |
3 | 10 | * sim-main.h (WITH_CORE): Delete. |
@@ -24,7 +24,6 @@ | ||
24 | 24 | #include "bfd.h" |
25 | 25 | |
26 | 26 | |
27 | -host_callback *mn10300_callback; | |
28 | 27 | struct _state State; |
29 | 28 | |
30 | 29 |
@@ -97,7 +96,6 @@ sim_open (SIM_OPEN_KIND kind, | ||
97 | 96 | { |
98 | 97 | int i; |
99 | 98 | SIM_DESC sd = sim_state_alloc (kind, cb); |
100 | - mn10300_callback = cb; | |
101 | 99 | |
102 | 100 | SIM_ASSERT (STATE_MAGIC (sd) == SIM_MAGIC_NUMBER); |
103 | 101 |
@@ -418,10 +416,7 @@ program_interrupt (SIM_DESC sd, | ||
418 | 416 | |
419 | 417 | /* avoid infinite recursion */ |
420 | 418 | if (in_interrupt) |
421 | - { | |
422 | - (*mn10300_callback->printf_filtered) (mn10300_callback, | |
423 | - "ERROR: recursion in program_interrupt during software exception dispatch."); | |
424 | - } | |
419 | + sim_io_printf (sd, "ERROR: recursion in program_interrupt during software exception dispatch."); | |
425 | 420 | else |
426 | 421 | { |
427 | 422 | in_interrupt = 1; |
@@ -8,7 +8,6 @@ | ||
8 | 8 | #include "bfd.h" |
9 | 9 | #include "sim-fpu.h" |
10 | 10 | |
11 | -extern host_callback *mn10300_callback; | |
12 | 11 | extern SIM_DESC simulator; |
13 | 12 | |
14 | 13 | typedef unsigned8 uint8; |