]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - sim/m32r/ChangeLog
* cpu.h,model.c,sem-switch.c,sem.c: Regenerate.
[thirdparty/binutils-gdb.git] / sim / m32r / ChangeLog
1 Wed Mar 4 12:10:43 1998 Doug Evans <devans@canuck.cygnus.com>
2
3 * cpu.h,model.c,sem-switch.c,sem.c: Regenerate.
4 start-sanitize-m32rx
5 * cpux.h,decodex.[ch],modelx.c,readx.c,semx.c: Regenerate.
6 end-sanitize-m32rx
7
8 Thu Feb 26 18:38:35 1998 Andrew Cagney <cagney@b1.cygnus.com>
9
10 * sim-if.c (sim_open): Initialize PROFILE_INFO_CPU_CALLBACK.
11
12 * sim-if.c (sim_info): Delete.
13
14 start-sanitize-m32rx
15 Fri Feb 27 10:14:29 1998 Doug Evans <devans@canuck.cygnus.com>
16
17 * mloopx.in: Fix handling of branch in parallel with another insn.
18 * semx.c: Regenerate.
19
20 end-sanitize-m32rx
21 Mon Feb 23 13:30:46 1998 Doug Evans <devans@seba.cygnus.com>
22
23 * sim-main.h: #include symcat.h.
24 * m32r-sim.h (BRANCH_NEW_PC): Delete current_cpu arg.
25 (NEW_PC_{BASE,SKIP,2,4,BRANCH_P}): New macros.
26 * cpu.[ch],decode.[ch],extract.c,model.c: Regenerate.
27 * sem.c,sem-switch.c: Regenerate.
28 start-sanitize-m32rx
29 * m32r-sim.h (SEM_NEXT_PC): Modify to handle parallel exec.
30 * mloopx.in: Rewrite.
31 * cpux.[ch],decodex.[ch],readx.c,semx.c: Regenerate.
32 end-sanitize-m32rx
33
34 Mon Feb 23 12:27:52 1998 Nick Clifton <nickc@cygnus.com>
35
36 * m32r.c (m32r_h_cr_set, m32r_h_cr_get): Shadow control register 6
37 in the backup PC register.
38 start-sanitize-m32rx
39 * m32rx.c (m32r_h_cr_set, m32r_h_cr_get): Shadow control register 6
40 in the backup PC register.
41 end-sanitize-m32rx
42
43 Thu Feb 19 16:39:35 1998 Doug Evans <devans@canuck.cygnus.com>
44
45 * m32r.c (do_lock,do_unlock): Delete.
46 * cpu.[ch],decode.[ch],extract.c,model.c: Regenerate.
47 * sem.c,sem-switch.c: Regenerate.
48 start-sanitize-m32rx
49 * cpux.[ch],decodex.[ch],readx.c,semx.c: Regenerate.
50 end-sanitize-m32rx
51
52 Tue Feb 17 18:18:10 1998 Doug Evans <devans@seba.cygnus.com>
53
54 * Makefile.in (M32R_OBJS): Add cpu.o.
55 (cpu.o): Add rule for.
56 (NL_TARGET): Define.
57 * configure.in: Add AC_CHECK_PROG(SCHEME).
58 * cpu.c: New file.
59 * cpuall.h,cpu.h,decode.c,decode.h,extract.c,model.c: Regenerate.
60 * sem-switch.c,sem.c: Regenerate.
61 * mloop.in (execute): Update call to semantic fn.
62 start-sanitize-m32rx
63 (M32RX_OBJS): Add cpux.o.
64 (cpux.o): Add rule for.
65 cpux.c: New file.
66 * cpux.h,decodex.c,decodex.h,modelx.c,readx.c,semx.c: Regenerate.
67 * m32rx.c (m32rx_h_accums_{get,set}): Rewrite.
68 (m32rx_h_cr_{get,set}): New functions.
69 (m32rx_h_accums_{get,set}): New functions.
70 * mloopx.in: Rewrite main loop.
71 end-sanitize-m32rx
72
73 * m32r.c (do_trap): Move from here.
74 * sim-if.c (do_trap): To here, and rewrite to use CB_SYSCALL support.
75 (sim_create_inferior): Use h_pc_set.
76 (h_pc_{get,set}): New functions.
77 (h_gr_{get,set}): New functions.
78 (syscall_{read,write}_mem): New functions.
79 * sim-main.h (h_{gr,pc}_{get,set}): Declare.
80
81 Tue Feb 17 12:44:38 1998 Andrew Cagney <cagney@b1.cygnus.com>
82
83 * sim-if.c (sim_store_register, sim_fetch_register): Pass in
84 length parameter. Return -1.
85 (sim_create_inferior): Pass 4 sim_store_register.
86
87 Wed Feb 11 19:53:48 1998 Doug Evans <devans@canuck.cygnus.com>
88
89 * sim-main.h (CIA_GET,CIA_SET): Provide dummy definitions for now.
90
91 * decode.c, decode.h, sem.c, sem-switch.c, model.c: Regenerate.
92 start-sanitize-m32rx
93 * cpux.c, decodex.c, decodex.h, readx.c, semx.c, modelx.c: Regenerate.
94 end-sanitize-m32rx
95
96 Mon Feb 9 19:41:54 1998 Doug Evans <devans@canuck.cygnus.com>
97
98 * decode.c, sem.c: Regenerate.
99 start-sanitize-m32rx
100 * cpux.h, decodex.c, readx.c, semx.c: Regenerate.
101 * m32rx.c (m32rx_h_accums_set): New function.
102 (m32rx_model_mark_[gs]et_h_gr): New function.
103 * mloopx.in: Rewrite.
104 * Makefile.in (mloopx.o): Build with -parallel.
105 * sim-main.h (_sim_cpu): Delete member `par_exec'.
106 * tconfig.in (WITH_SEM_SWITCH_FULL): Define as 0 for m32rx.
107 end-sanitize-m32rx
108
109 Thu Feb 5 12:44:31 1998 Doug Evans <devans@seba.cygnus.com>
110
111 * Makefile.in (m32r.o): Depend on cpu.h
112 (extract.o): Pass -DSCACHE_P.
113 * mloop.in (extract{16,32}): Update call to m32r_decode.
114 * arch.h,cpu.h,cpuall.h,decode.[ch]: Regenerate.
115 * extract.c,model.c,sem-switch.c,sem.c: Regenerate.
116 * sim-main.h: #include "ansidecl.h".
117 Don't include cpu-opc.h, done by arch.h.
118 start-sanitize-m32rx
119 * Makefile.in (M32RX_OBJS): Build m32rx support now.
120 (m32rx.o): New rule.
121 * m32r-sim.h (m32rx_h_cr_[gs]et): Define.
122 * m32rx.c (m32rx_{fetch,store}_register): Update {get,set} of PC.
123 (m32rx_h_accums_get): New function.
124 * mloopx.in: Update call to m32rx_decode. Rewrite exec loop.
125 * cpux.h,decodex.[ch],modelx.c,readx.c,semx.c: Regenerate.
126 end-sanitize-m32rx
127
128 Sun Feb 1 16:47:51 1998 Andrew Cagney <cagney@b1.cygnus.com>
129
130 * configure: Regenerated to track ../common/aclocal.m4 changes.
131
132 Sat Jan 31 18:15:41 1998 Andrew Cagney <cagney@b1.cygnus.com>
133
134 * configure: Regenerated to track ../common/aclocal.m4 changes.
135
136 start-sanitize-m32rx
137 Thu Jan 29 11:22:00 1998 Doug Evans <devans@canuck.cygnus.com>
138
139 * Makefile.in (M32RX_OBJS): Comment out until m32rx port working.
140 * arch.h (HAVE_CPU_M32R{,X}): Delete, moved to m32r-opc.h.
141 * arch.c (machs): Check ifdef HAVE_CPU_FOO for each entry.
142
143 end-sanitize-m32rx
144 Tue Jan 20 14:16:02 1998 Nick Clifton <nickc@cygnus.com>
145
146 * cpux.h: Fix duplicate definition of h_accums field for
147 fmt_53_sadd structure.
148
149 start-sanitize-m32rx
150 Tue Jan 20 01:42:17 1998 Doug Evans <devans@seba.cygnus.com>
151
152 * Makefile.in: Add m32rx objs, and rules to build them.
153 * cpux.h, decodex.h, decodex.c, readx.c, semx.c, modelx.c: New files.
154 * m32rx.c, mloopx.in: New files.
155
156 end-sanitize-m32rx
157 Mon Jan 19 22:26:29 1998 Doug Evans <devans@seba>
158
159 * configure: Regenerated to track ../common/aclocal.m4 changes.
160
161 Mon Jan 19 14:13:40 1998 Doug Evans <devans@seba.cygnus.com>
162
163 * arch.c, arch.h, cpuall.h: New files.
164 * arch-defs.h: Deleted.
165 * mloop.in: Renamed from mainloop.in.
166 * Makefile.in: Update.
167 * sem-ops.h: Deleted.
168 * mem-ops.h: Deleted.
169 start-sanitize-cygnus
170 Add cgen support for generating files.
171 end-sanitize-cygnus
172 (arch): Renamed from CPU.
173 * cpu.h: New file.
174 * decode.c: Redone.
175 * decode.h: Redone.
176 * extract.c: Redone.
177 * model.c: Redone.
178 * sem-switch.c: Redone.
179 * sem.c: Renamed from semantics.c, and redone.
180 * m32r-sim.h (PROFILE_COUNT_FILLNOPS): Update.
181 (GETTWI,SETTWI,BRANCH_NEW_PC): Define.
182 * m32r.c (WANT_CPU,WANT_CPU_M32R): Define.
183 (m32r_{fetch,store}_register): New functions.
184 (model_mark_{get,set}_h_gr): Prefix with m32r_.
185 (m32r_model_mark_{busy,unbusy}_reg): Prefix with m32r_.
186 (h_cr_{get,set}): Prefix with m32r_.
187 (do_trap): Fetch state from current_cpu, not current_state.
188 Call sim_engine_halt instead of engine_halt.
189 * sim-if.c (alloc_cpu): New function.
190 (free_state): New function.
191 (sim_open): Call sim_state_alloc, and malloc space for selected cpu
192 type. Call sim_analyze_program.
193 (sim_create_inferior): Handle selected cpu type when setting PC.
194 start-sanitize-m32rx
195 (sim_resume): Handle m32rx.
196 end-sanitize-m32rx
197 (sim_stop_reason): Deleted.
198 (print_m32r_misc_cpu): Update.
199 start-sanitize-m32rx
200 (sim_{fetch,store}_register): Handle m32rx.
201 end-sanitize-m32rx
202 (sim_{read,write}): Deleted.
203 (sim_engine_illegal_insn): New function.
204 * sim-main.h: Don't include arch-defs.h,sim-core.h,sim-events.h.
205 Include arch.h,cpuall.h. Include cpu.h,decode.h if m32r.
206 start-sanitize-m32rx
207 Include cpux.h,decodex.h if m32rx.
208 end-sanitize-m32rx
209 (_sim_cpu): Include member appropriate cpu_data member for the cpu.
210 (M32R_MISC_PROFILE): Renamed from M32R_PROFILE.
211 (sim_state): Delete members core,events,halt_jmp_buf.
212 Change `cpu' member to be a pointer to the cpu's struct, rather than
213 record inside the state struct.
214 * tconfig.in (WITH_DEVICES): Define here.
215 (WITH_FAST,WITH_SEM_SWITCH_{FULL,FAST}): Define for the cpu.
216
217 Fri Jan 16 12:16:56 1998 Nick Clifton <nickc@cygnus.com>
218
219 * arch-defs.h (INSN_NAME): Fix typo.
220
221 Mon Dec 15 23:17:11 1997 Andrew Cagney <cagney@b1.cygnus.com>
222
223 * configure: Regenerated to track ../common/aclocal.m4 changes.
224 * config.in: Ditto.
225
226 Thu Dec 4 09:21:05 1997 Doug Evans <devans@canuck.cygnus.com>
227
228 * m32r-sim.h (MSPR_ADDR): New macro.
229 (m32r_mspr_device): Declare.
230 (struct _device): Define.
231 * m32r.c (m32r_mspr_device): New global.
232 (device_{io_{read,write}_buffer,error}): New functions.
233 * mem-ops.h (SETMEM*): Use sim_core_write_map, not read map.
234 * sim-if.c: Delete redundant inclusion of cpu-sim.h.
235 (sim_open): Attach device to handle MSPR register.
236 * sim-main.h (WITH_DEVICES): Define as 1.
237 Include cpu-sim.h.
238
239 * configure: Regenerated to track ../common/aclocal.m4 changes.
240
241 Wed Dec 3 18:08:44 1997 Doug Evans <devans@canuck.cygnus.com>
242
243 * configure.in (SIM_AC_OPTION_ENVIRONMENT): Call.
244 * configure: Regenerated.
245
246 Wed Nov 19 12:17:08 1997 Doug Evans <devans@canuck.cygnus.com>
247
248 * mem-ops.h: Rename SIM_SIG{ACCESS,ALIGN} to SIM_SIG{SEGV,BUS}.
249 * sim-if.c (sim_open): Call sim_config.
250 (sim_stop_reason): Update call to sim_signal_to_host.
251
252 Tue Nov 18 15:33:48 1997 Doug Evans <devans@canuck.cygnus.com>
253
254 * Makefile.in (SIM_OBJS): Use $(SIM_NEW_COMMON_OBJS).
255
256 Fri Oct 31 18:46:46 1997 Andrew Cagney <cagney@b1.cygnus.com>
257
258 * sim-if.c (sim_open): Delete dead call to sim_core_attach.
259
260 Mon Oct 27 12:43:54 1997 Doug Evans <devans@canuck.cygnus.com>
261
262 * sem-ops.h (U{DIV,MOD}[BHSD]I): Use unsigned division.
263
264 Fri Oct 3 09:28:00 1997 Andrew Cagney <cagney@b1.cygnus.com>
265
266 * configure: Regenerated to track ../common/aclocal.m4 changes.
267
268 Wed Sep 24 17:38:57 1997 Andrew Cagney <cagney@b1.cygnus.com>
269
270 * configure: Regenerated to track ../common/aclocal.m4 changes.
271
272 Tue Sep 23 11:04:38 1997 Andrew Cagney <cagney@b1.cygnus.com>
273
274 * configure: Regenerated to track ../common/aclocal.m4 changes.
275
276 Tue Sep 23 10:19:51 1997 Andrew Cagney <cagney@b1.cygnus.com>
277
278 * Makefile.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_SCACHE,
279 SIM_DEFAULT_MODEL): Delete, moved to common.
280 (SIM_EXTRA_CFLAGS): Update.
281
282 Mon Sep 22 11:46:20 1997 Andrew Cagney <cagney@b1.cygnus.com>
283
284 * configure.in (sim_link_links): Configure non-strict memory
285 alignment.
286
287 * configure: Regenerated to track ../common/aclocal.m4 changes.
288
289 Fri Sep 19 17:45:25 1997 Andrew Cagney <cagney@b1.cygnus.com>
290
291 * configure: Regenerated to track ../common/aclocal.m4 changes.
292
293 Wed Sep 17 17:44:40 1997 Andrew Cagney <cagney@b1.cygnus.com>
294
295 * sim-if.c (sim_open): Allocate memory under sim-memopt module
296 using sim_do_commandf.
297 (sim_open): Set magic-number at the start.
298 (sim_do_command): Implement.
299
300 * sim-main.h (sim_engine_halt): Map onto engine_halt.
301
302 Mon Sep 15 17:36:15 1997 Andrew Cagney <cagney@b1.cygnus.com>
303
304 * configure: Regenerated to track ../common/aclocal.m4 changes.
305
306 Thu Sep 4 17:21:23 1997 Doug Evans <dje@seba>
307
308 * configure: Regenerated to track ../common/aclocal.m4 changes.
309
310 Fri Sep 5 10:21:48 1997 Andrew Cagney <cagney@b1.cygnus.com>
311
312 * Makefile.in (SIM_OBJS): Add sim-memopt.o module.
313
314 Thu Sep 4 10:30:02 1997 Andrew Cagney <cagney@b1.cygnus.com>
315
316 * sim-if.c (sim_open): Pass zero modulo arg to sim_core_attach.
317
318 Wed Aug 27 18:13:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
319
320 * configure: Regenerated to track ../common/aclocal.m4 changes.
321 * config.in: Ditto.
322
323 Tue Aug 26 10:39:42 1997 Andrew Cagney <cagney@b1.cygnus.com>
324
325 * sim-if.c (sim_kill): Delete.
326 (sim_create_inferior): Add ABFD argument.
327 (sim_load): Move setting of PC from here.
328 (sim_create_inferior): To here.
329 (sim_load): Delete, use sim-hload.c instead.
330
331 * Makefile.in (SIM_OBJS): Add sim-hload.o module.
332
333 Mon Aug 25 17:50:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
334
335 * configure: Regenerated to track ../common/aclocal.m4 changes.
336 * config.in: Ditto.
337
338 Mon Aug 25 15:54:08 1997 Andrew Cagney <cagney@b1.cygnus.com>
339
340 * sim-if.c (sim_open): Add ABFD argument.
341
342 Tue Jul 22 10:16:16 1997 Doug Evans <dje@canuck.cygnus.com>
343
344 * sim-main.h (M32R_DEFAULT_MEM_SIZE): New macro.
345 * sim-if.c (sim_open): Use it.
346
347 Wed Jun 4 12:48:12 1997 Andrew Cagney <cagney@b1.cygnus.com>
348
349 * sim-main.h (WITH_ENGINE): Disable the common engine for now.
350
351 Tue May 27 14:15:44 1997 Andrew Cagney <cagney@b1.cygnus.com>
352
353 * sim-if.c (sim_read): Pass NULL cpu to sim_core_read_buffer.
354 (sim_write): Ditto for write.
355
356 * m32r.c (do_trap): Ditto for read/write.
357
358 Tue May 20 10:18:25 1997 Andrew Cagney <cagney@b1.cygnus.com>
359
360 * sim-if.c (sim_open): Add callback argument.
361 (sim_set_callbacks, sim_callback): Delete.
362 (sim_load): Set STATE_LOADED_P.
363
364 Mon May 19 12:55:42 1997 Andrew Cagney <cagney@b1.cygnus.com>
365
366 * Makefile.in (SIM_OBJS): Link in sim-abort.o as a stub for
367 sim_engine_abort.
368
369 Mon May 5 12:45:28 1997 Andrew Cagney <cagney@b1.cygnus.com>
370
371 * sim-if.c (sim_open): Update to reflect changes to core in
372 ../common/.
373 * mem-ops.h (GETMEMQI, GETMEMHI, GETMEMSI, GETMEMDI, GETMEMUQI,
374 GETMEMUHI, GETMEMUSI, GETMEMUDI, SETMEMQI, SETMEMHI, SETMEMSI,
375 SETMEMDI, SETMEMUQI, SETMEMUHI, SETMEMUSI, SETMEMUDI): Ditto.
376
377 Sat May 3 08:38:55 1997 Doug Evans <dje@seba.cygnus.com>
378
379 * decode.c (decode): Add computed goto support.
380
381 Fri May 2 16:30:26 1997 Andrew Cagney <cagney@b1.cygnus.com>
382
383 * mem-ops.h: Stub additional core read/write arguments.
384
385 * sim-main.h: Declare sim_cia - type SI.
386 (struct _sim_cpu): Move base type to end per common.
387 (struct _sim_state): Ditto.
388
389 Thu May 1 11:15:34 1997 Doug Evans <dje@canuck.cygnus.com>
390
391 Merge from branch into devo. CGEN generic files moved to common
392 directory. K&R C support is no longer provided.
393
394 Thu Apr 24 00:39:51 1997 Doug Evans <dje@canuck.cygnus.com>
395
396 * configure: Regenerated to track ../common/aclocal.m4 changes.
397
398 Sat Apr 12 12:57:33 1997 Felix Lee <flee@yin.cygnus.com>
399
400 * Makefile.in, seman-cache.c: new file, for wingdb build.
401 * sim-alloca.h: fixed for wingdb.
402
403 Mon Apr 7 13:33:29 1997 Doug Evans <dje@seba.cygnus.com>
404
405 * decode.c (*): m32r_cgen_insn_table renamed to ..._entries.
406 * mainloop.in: Use CGEN_INSN_INDEX instead of CGEN_INSN_TYPE.
407 * simdefs.h (INSN_NAME): m32r_cgen_insn_table renamed to ..._entries.
408
409 Fri Apr 4 19:23:12 1997 Doug Evans <dje@canuck.cygnus.com>
410
411 * cgen-utils.in (ex_illegal): Fill in abuf->length, abuf->addr.
412 (exc_illegal): Likewise.
413 * decode.c (decode_vars): Add decode_illegal.
414 * genmloop.sh: #include "cpu-opc.h".
415 * sem-switch.c (case_INSN_ILLEGAL): Declare.
416 (labels): Add case_INSN_ILLEGAL.
417 (SWITCH): Add INSN_ILLEGAL case.
418
419 Wed Mar 26 12:34:00 1997 Doug Evans <dje@canuck.cygnus.com>
420
421 * model.c (model_module): Use 0 not NULL.
422
423 * genmloop.sh (sim_main_loop): Handle k&r c.
424
425 * sem-switch.c: Regenerate to get k&r c support.
426 * semantics.c: Likewise.
427
428 * m32r.c (ADD_{OV,CA}_SI,SUB_{OV,CA}_SI): Renamed to {ADD,SUB}[OC]FSI.
429 (ADDCSI,SUBCSI): New functions.
430 * sem-switch.c (addv,addv3,addx,subv,subx): Fix carry bit handling.
431 * semantics.c (addv,addv3,addx,subv,subx): Fix carry bit handling.
432
433 * simcache.c (simcache_{install,init,uninstall}): Use
434 DECLARE_MODULE_INSTALL_HANDLER.
435 (simcache_option_handler): Use DECLARE_OPTION_HANDLER.
436
437 * utils.c: #include "semops.h".
438
439 Tue Mar 11 14:30:26 1997 Doug Evans <dje@seba.cygnus.com>
440
441 * profile.c (profile_print_simcache): Fix thinko in printf text.
442
443 * simdefs.h (struct argbuf): Add member to fmt_20 so it's not empty.
444
445 Mon Mar 10 11:06:29 1997 Doug Evans <dje@seba.cygnus.com>
446
447 * m32r.c (h_cr_get): Rewrite.
448 (h_cr_set): Rewrite.
449 * sem-switch.c (rte): bcarry renamed to bcond.
450 * semantics.c (rte): Likewise.
451 * simdefs.h (CPU_STATE): Likewise.
452
453 * config.in (HAVE_SYS_TIME_H): Add.
454 * configure.in: Check for sys/time.h.
455 * configure: Regenerated.
456 * utils.c: Include sys/time.h if present.
457
458 * common.c (sim_parse_args): Account for NULL terminating entry
459 in long_options table.
460
461 * genmloop.sh (RUN_FAST_P): Don't run fast if tracing.
462 Always use cache if configured in.
463 * mainloop.in (do_extract_insn{16,32}): New functions.
464 (normal,fast): Call them. Handle starting in left slot.
465 * simcache.c (simcache_option_handler): Disallow -c0.
466 * sem-switch.c (TRACE_RESULT): Redefine so no tracing.
467
468 * profile.c (profile_print_simcache): Fix percentage calc.
469
470 * Makefile.in (INCLUDE_DEPS): Delete simcommon.h.
471
472 Sun Mar 9 20:42:17 1997 Doug Evans <dje@seba.cygnus.com>
473
474 * Makefile.in (COMMON_{PRE,POST}_CONFIG_FRAG): Add delimiters for.
475 (M32R_INCLUDE_DEPS): Use cpu-sim.h instead of m32r-sim.h.
476 Add mod-list.h.
477 (mrun.o): Don't depend on M32R_INCLUDE_DEPS.
478 (sim-if.o,m32r.o,utils.o): Likewise.
479 (common.o): Don't explicitly depend on mod-list.h.
480 (mainloop.c): Pass CPU to genmloop.sh.
481 (stamp-modules): Depend on configure.
482 (decode.o): Depend on decode,h, memops.h, semops.h, cpu-opc.h.
483 (extract.o): Depend on decode.h, memops.h, semops.h.
484 (semantics.o,seman-cache.o): Likewise.
485 (model.o,ops.o): Depend on memops.h.
486 (extr-cache.o): Disable building for the moment.
487
488 * simcommon.h: Delete, move contents into cgen-sim.h.
489 * cgen-sim.h: Don't include ansidecl.h,bfd.h,simfns.h.
490 (UINT,CGEN_CAT3): Define.
491 ({extract,semantic}_fn_t): Renamed to {EXTRACT,SEMANTIC}_FN.
492 (decode_t): Renamed to DECODE.
493
494 * simfns.h: Delete, contents moved to memops.h,semops.h.
495 * memops.h: New file.
496 * semops.h: New file.
497 * decode.h: Renamed from semantics.h.
498
499 * sim-argv.h: New file.
500 * Makefile.in (memory.o,trace.o,profile.o,simcache.o,common): Add
501 dependency of sim-argv.h.
502
503 * sim-alloca.h: New file.
504 * common.c: Include it.
505 * Makefile.in (common.o): Add dependency.
506
507 * config.in (HAVE_TIME_H,HAVE_SYS_RESOURCE_H): Add.
508 (HAVE_GETRUSAGE,HAVE_TIME): Add.
509 * configure.in: sinclude ../common/aclocal.m4.
510 Check for headers time.h, sys/resource.h.
511 Check for functions time, getrusage.
512 (sim_link_{files,links}): Add link cpu-opc.h.
513 (sim_profile): Add simcache.
514 (SIM_AC_PROFILE): Add simcache, profile.o.
515 (simcache module): Delete extr-cache.o for now.
516 (--enable-sim-cache): Allow specification of default cache size.
517 * configure: Regenerated.
518
519 * decode.c: #include cgen-sim.h,memops.h,semops.h,decode.h,
520 cpu-sim.h,cpu-opc.h. Don't include m32r-sim.h.
521 Regenerate.
522
523 * extract.c: #include cgen-sim.h,decode.h,cpu-sim.h.
524 Don't include m32r-sim.h.
525 (*): Define/Undef FLD macro. Use it to reference ARGBUF.
526 Simplify profiling test with PROFILE_MODEL_P.
527 (mvfc,mvtc): Fix access of control registers.
528 * semantic.c: #include cgen-sim.h,memops.h,semops.h,decode.h,cpu-sim.h.
529 Don't include m32r-sim.h.
530 (*): Define/Undef FLD macro. Use it to reference ARGBUF.
531 Simplify profiling test with PROFILE_MODEL_P.
532 (mvfc,mvtc): Fix access of control registers.
533
534 * sem-switch.c: New file, for GCC computed goto support.
535
536 * genmloop.sh: Add #include's of bfd.h,callback.h,cgen-sim.h,
537 memops.h,semops.h,trace.h,cpu-sim.h.
538 (RUN_FAST_P): Change default to run fast if cache size > 0
539 and not profiling.
540 (sim_main_loop): Record execution time.
541 Record instruction count even in fast mode.
542 (init): Allow cpu to provide init code in mainloop.in.
543 (FAST): Define as 0 or 1 depending on fast mode.
544 * mainloop.in (normal): Combine with fast case.
545 Add support for GCC computed gotos. Count simcache hits/misses.
546 (init): Initialize "switch" labels if GNUC.
547
548 * cgen-utils.in: Don't include opcode/cgen.h.
549 Include cgen-sim.h, cpu-opc.h.
550 * common.c: Don't include simcommon.h,mod-list.h. Include cgen-sim.h.
551 * m32r-sim.h: Don't include mod-list.h
552 (RUN_FAST_P): Delete.
553 * m32r.c: Don't include profile.h. #include ansidecl.h,cgen-sim.h,
554 semops.h,memory.h,trace.h
555 (h_cr_get,h_cr_set): New functions.
556 * memory.c: #include cgen-sim.h,callback.h.
557 * ops.c: Don't include profile.h,m32r-sim.h.
558 Include cgen-sim.h,memops.h,cpu-sim.h.
559 (MEMOPS_DEFINE_INLINE): Renamed from SIMFNS_DEFINE_INLINE.
560 * trace.c: Include cgen-sim.h,cpu-opc.h.
561 * trace.h (trace_insn_{init,fini}): Declare.
562
563 * model.c: Don't include signal.h,stdlib.h,m32r-sim.h.
564 Include cgen-sim.h,cpu-sim.h,cpu-opc.h.
565 Regenerate to get new insn aliases.
566
567 * mrun.c: #include "ansidecl.h".
568 (STATE): Use struct sim_state instead.
569
570 * profile.c: Surround #include <stdlib.h> with HAVE_STDLIB_H.
571 Don't include simcommon.h. Include cgen-sim.h,cpu-opc.h.
572 (PROFILE_{READ,WRITE}_MASK): Replace with PROFILE_MEMORY_MASK.
573 (profile_print_simcache): New function.
574 (profile_print): Call it. Print simulator speed stats.
575 * profile.h (PROFILE_{READ,WRITE}_MASK): Replace with
576 PROFILE_MEMORY_MASK.
577 (MODULE_PROFILE_SIMCACHE_P): Define.
578 (PROFILE_SIMCACHE_MASK): Define.
579 (PROFILE_COUNT): New members total_insn_count,exec_time.
580 New members simcache_hits,simcache_misses.
581 (PROFILE_SIMCACHE_{HITS,MISSES}): Define.
582 (PROFILE_MODEL_P): New macro.
583 (PROFILE_COUNT_SIMCACHE_{HIT,MISS}): New macros.
584
585 * sim-if.c: Surround #include <stdlib.h> with HAVE_STDLIB_H.
586 Don't include simcommon.h,m32r-sim.h. Include cgen-sim.h,cpu-sim.h.
587 (sim_resume): Use USING_SIMCACHE_P instead of RUN_FAST_P.
588 (sim_info): Pass verbose to profile_print.
589
590 * simcache.c: Include cgen-sim.h,callback.h.
591 (USING_SIMCACHE_P): Replace with SIMCACHE_P.
592 (simcache_option_handler): Ensure cache size at least 2.
593 Allow config time specification of default cache size.
594 * simcache.h (struct simcache): Support GCC computed gotos.
595 (SIMCACHE_DEFAULT_CACHE_SIZE): USe CONFIG_SIM_CACHE_SIZE if defined.
596 (USING_SIMCACHE_P): New macro.
597
598 * simdefs.h: Don't include m32r-opc.h.
599 (CGEN_MAX_SIM_INSNS): Define.
600 (CPU_STATE): Regenerate.
601 (ARGBUF): Regenerate.
602 (extract,semantic handler decls): Delete, moved to decode.h.
603
604 * tconfig.in: Don't include cgen-sim.h,m32r-sim.h.
605 (USE_SEM_SWITCH): Define.
606
607 * utils.c: Include bfd.h,time.h,sys/resource.h.
608 (sim_time_get,sim_time_elapsed): New functions.
609 * cgen-sim.h (SIM_TIME,sim_time_get,sim_time_elapsed): Declare.
610
611 Fri Jan 31 20:25:06 1997 Doug Evans <dje@canuck.cygnus.com>
612
613 * configure.in (AC_CHECK_HEADERS): Handle i386-windows.
614 * configure: Regenerated.
615 * model.c: #include <stdlib.h>.
616 * simcache.c: #include "libiberty.h".
617 * simcommon.h (alloca): Handle i386-windows.
618
619 * common.c: #include libiberty.h.
620 (sim_signal_to_host): Return 5 if wingdb.
621
622 Mon Jan 27 15:22:49 1997 Doug Evans <dje@seba.cygnus.com>
623
624 * configure.in (sim_cache): Enabled by default now, pass default
625 cache size to --enable-sim-cache.
626 * simcache.c (simcache_option_handler): Allow -c 0.
627
628 * simdefs.h,simfns.h: Regenerate
629 * decode.c,extract.c,model.c,ops.c,semantics.c: Regenerate.
630
631 Tue Jan 21 16:21:01 1997 Doug Evans <dje@seba.cygnus.com>
632
633 Add model profiling support.
634 * configure.in: Handle --enable-sim-model.
635 (sim_profile): Add model.
636 * Makefile.in (model.o): Add rule.
637 * cgen-sim.h (UNIT,INSN_TIMING,MACH,MODEL): New types.
638 * extract.c (*): Add model profiling support.
639 * m32r.c (model_mark_{get,set}_h_gr): New functions.
640 (model_mark_{busy,unbusy}_reg): New functions.
641 * profile.c (profile_option_handler): Recognize --profile model.
642 (profile_print_model): New function.
643 (profile_print): Call it.
644 * profile.h (MODULE_profile_model,MODULE_PROFILE_MODEL_P): Define.
645 (PROFILE_MODEL_MASK,PROFILE_LABEL_WIDTH): Define.
646 (PROFILE_COUNT): New members cycle_count,cti_stall_count,
647 load_stall_count,taken_count,untaken_count.
648 * semantics.c (*): Add model profiling support.
649 * simcommon.h (struct sim_state): New members mach,model.
650 * simdefs.h (CPU_PROFILE,MODEL_TYPE,UNIT_TYPE): New type.
651 (MAX_MODELS,MAX_UNITS): Define.
652 * tconfig.in (STATE_EXTRA_MEMBERS): Add cpu_profile.
653
654 * Makefile.in (INCLUDE_DEPS): Add $(SIM_MODULES_HDRS).
655 (stamp-modules): Depend on genmodlist.sh.
656 * common.c (standard_options): Add --max-insns.
657 (copy_argv): New function.
658 * tconfig.in (SIM_HAVE_MAX_INSNS): Define.
659 * genmloop.sh: Allow mainloop.in to contain support code.
660 * mainloop.in: Move do_insn16,do_insn32 here.
661 * m32r.c (do_trap): Handle SYS_argvlen,SYS_argv,SYS_read.
662 * sim-if.c (sim_open): Don't set max insn count.
663 (sim_create_inferior): Save argv,envp.
664 * simcommon.h (struct sim_state): New members argv,envp.
665 * simdefs.h ([GS]ETTWI,[GS]ETTUWI,[GS]ETTAI): Define.
666 ([GS]ETMEMWI,[GS]ETMEMUWI,[GS]ETMEMAI): Define.
667 (ARGBUF): New members h_gr_get, h_gr_set.
668 * trace.c (trace_insn_init,trace_insn_fini): New functions.
669 (trace_printf): Print to buffer, output later by trace_insn_fini.
670 * trace.h (TRACE_INSN_{INIT,FINI}): Define.
671
672 Thu Dec 19 16:01:59 1996 Doug Evans <dje@canuck.cygnus.com>
673
674 * configure.in (AC_FUNC_ALLOCA): Call.
675 * configure: Regenerate.
676 * config.h (HAVE_ALLOCA_H): Add.
677 * simcommon.h: Add alloca support.
678 (DECLARE_MODULE_INSTALL_HANDLER): Define.
679 (DECLARE_OPTION_HANDLER): Define.
680 (MEM_FN): Declare using PARAMS.
681 (DECLARE_MEM_FN): Define.
682 * trace.c (trace_result): Tweak for !STDC.
683 * cgen-sim.h (UDI_FN_SUPPORT): Define if ! HAVE_LONGLONG.
684 * cgen-utils.in (disasm_sprintf): Fix va_arg call in !STDC case.
685 * common.c (sim_print_help_fn): Use PARAMS.
686 (standard_option_handler): Fix decl for !STDC systems.
687 * memory.c: #include <stdio.h>
688 (mem_flat_{install,init,uninstall}): Fix decl for !STDC systems.
689 (mem_flat_{read,write},mem_flat_option_handler): Likewise.
690 * profile.c (profile_install): Likewise.
691 (profile_option_handler): Likewise.
692
693 Thu Dec 19 11:06:19 1996 Doug Evans <dje@seba.cygnus.com>
694
695 * semantics.c (*): Don't suffix big unsigned numbers with "U".
696 Prefix them with 0x instead.
697
698 * cgen-sim.h (DI_FN_SUPPORT): Define if ! HAVE_LONGLONG.
699 (SLADI,SRADI,CONVSIDI,CONVDISI): Delete, moved to simfns.h.
700 * semantics.c (machi,maclo,macwhi,macwlo,mulhi,mullo): Implement.
701 (mulwhi,mulwlo,mvtachi,mvtaclo,rac,rach): Implement.
702 * simfns.h: Add decls for functional DI,UDI,SF,DF,XF,TF support.
703 Add support for boolean and/or.
704 * utils.c: Redo naming of DI functional support.
705 (ANDDI,ORDI,ADDDI,MULDI,GEDI,LEDI,CONVHIDI): New functions.
706
707 Tue Dec 17 12:57:48 1996 Doug Evans <dje@seba.cygnus.com>
708
709 * Directory created.