sim: mcore: switch to common syscall handling
[external/binutils.git] / sim / common / ChangeLog
1 2015-04-21  Mike Frysinger  <vapier@gentoo.org>
2
3         * gennltvals.sh: Add mcore support.
4         * nltvals.def: Regenerate.
5
6 2015-04-21  Mike Frysinger  <vapier@gentoo.org>
7
8         * cgen.sh: Add +x permissions.
9         * genmloop.sh: Likewise.
10         * gentvals.sh: Likewise.
11         * gennltvals.sh (newlibroot): New variable to hold the path to newlib.
12         Change all uses of srcroot for newlib to newlibroot.
13
14 2015-04-18  Mike Frysinger  <vapier@gentoo.org>
15
16         * sim-base.h (SIM_CPU): New typedef.
17
18 2015-04-18  Mike Frysinger  <vapier@gentoo.org>
19
20         * cgen-engine.h (CIA_ADDR): Delete.
21         * sim-base.h: Update sim_cia example.
22         [!CIA_ADDR] (sim_cia): New typedef.
23
24 2015-04-17  Mike Frysinger  <vapier@gentoo.org>
25
26         * cgen-utils.c (cgen_rtx_error): Change CIA_GET to CPU_PC_GET.
27         * sim-core.c (sim_core_read_buffer, sim_core_write_buffer): Likewise.
28         * sim-engine.h (SIM_ENGINE_HALT_HOOK): Change CIA_SET to CPU_PC_SET.
29         * sim-run.c (sim_engine_run): Change CIA_GET to CPU_PC_GET and
30         CIA_SET to CPU_PC_SET.
31
32 2015-04-15  Mike Frysinger  <vapier@gentoo.org>
33
34         * Makefile.in (SIM_NEW_COMMON_OBJS): Add sim-cpu.o.
35         * sim-main.h (STATE_CPU): Remove from comment and define.
36
37 2015-04-13  Mike Frysinger  <vapier@gentoo.org>
38
39         * acinclude.m4 (ACX_PKGVERSION): Change GDB to SIM.
40         * configure: Regenerate.
41
42 2015-04-13  Mike Frysinger  <vapier@gentoo.org>
43
44         * sim-options.c: Include version.h.
45         (OPTIONS_VERSION): New enum.
46         (standard_options): Add "version".
47         (standard_option_handler): Handle OPTIONS_VERSION.
48
49 2015-04-13  Mike Frysinger  <vapier@gentoo.org>
50
51         * Makefile.in (version.o): Change to using create-version.sh from gdb.
52         (create-version.sh): Delete.
53
54 2015-04-06  Mike Frysinger  <vapier@gentoo.org>
55
56         * Make-common.in (SIM_NEW_COMMON_OBJS): Add sim-engine.o and sim-hrw.o.
57
58 2015-04-01  Mike Frysinger  <vapier@gentoo.org>
59
60         * run-sim.h, run.c: Delete.
61         * tconfig.h (SIM_HAVE_PROFILE, SIM_HAVE_BIENDIAN): Delete.
62
63 2015-03-31  Mike Frysinger  <vapier@gentoo.org>
64
65         * config.in, configure: Regenerate.
66         * Make-common.in (CSEARCH): Add $(ZLIBINC).
67         (ZLIB, ZLIBINC): Define.
68         (BFD_LIB): Add $(ZLIB).
69
70 2015-03-31  Mike Frysinger  <vapier@gentoo.org>
71
72         * cgen-mem.h (MEMOPS_INLINE): Change to EXTERN_INLINE.
73         * cgen-ops.h (SEMOPS_INLINE): Likewise.
74
75 2015-03-29  Mike Frysinger  <vapier@gentoo.org>
76
77         * sim-arange.h (SIM_ARANGE_INLINE): Move above sim_addr_range_hit_p.
78         (sim_addr_range_hit_p): Change INLINE to SIM_ARANGE_INLINE.
79         * sim-inline.h (INLINE2): Define to gnu_inline when available.
80
81 2015-03-24  Mike Frysinger  <vapier@gentoo.org>
82
83         * sim-profile.c (profile_pc_event): Get pc via sim_pc_get.  Delete
84         usage of STATE_WATCHPOINTS.
85         (profile_pc_init): Delete STATE_WATCHPOINTS (sd)->pc check.  Change
86         STATE_WATCHPOINTS (sd)->sizeof_pc to sizeof (sim_cia).
87
88 2015-03-24  Mike Frysinger  <vapier@gentoo.org>
89
90         * tconfig.h: Note SIM_HAVE_PROFILE is deprecated.
91
92 2015-03-24  Mike Frysinger  <vapier@gentoo.org>
93
94         * tconfig.h: Note SIM_HAVE_BIENDIAN is deprecated.
95
96 2015-03-24  Mike Frysinger  <vapier@gentoo.org>
97
98         * acinclude.m4 (SIM_AC_OPTION_HARDWARE): Move default option setting
99         of enable_sim_hardware to AC_ARG_ENABLE.
100
101 2015-03-23  Mike Frysinger  <vapier@gentoo.org>
102
103         * acinclude.m4 (SIM_AC_OPTION_HARDWARE): Delete SIM_DV_SOCKSER_O.
104         Add dv-sockser.o to sim_hw_objs.
105
106 2015-03-23  Mike Frysinger  <vapier@gentoo.org>
107
108         * dv-sockser.c: Include config.h.
109         * dv-sockser.h: Include sim-inline.h.
110         [HAVE_DV_SOCKSER]: Move all prototypes here.
111         [!HAVE_DV_SOCKSER] (dv_sockser_status, dv_sockser_write,
112         dv_sockser_write_buffer, dv_sockser_read): New stub functions.
113
114 2015-03-16  Mike Frysinger  <vapier@gentoo.org>
115
116         * gentmap.c, run.c: Convert old style prototypes.
117
118 2015-03-16  Mike Frysinger  <vapier@gentoo.org>
119
120         * acinclude.m4 (SIM_AC_COMMON): Call AH_BOTTOM.  Delete logic for
121         symlinking tconfig.h to tconfig.in.
122         * config.in, configure: Regenerate.
123         * nrun.c, run.c, sim-basics.h: Delete tconfig.h include.
124         * tconfig.in: Rename file ...
125         * tconfig.h: ... here.
126
127 2015-03-15  Mike Frysinger  <vapier@gentoo.org>
128
129         * dv-socker.h (dv_sockser_install): Declare.
130         * sim-module.c: Include config.h.
131         [HAVE_DV_SOCKSER]: Include dv-sockser.h.
132         (modules) [HAVE_DV_SOCKSER]: Add dv_sockser_install.
133         * sim-module.h: Include gdb/remote-sim.h.
134
135 2015-03-14  Mike Frysinger  <vapier@gentoo.org>
136
137         * Make-common.in (BUILT_SRC_FROM_COMMON): Delete.
138         (sim-inline.c): Delete rule.
139
140 2015-03-14  Mike Frysinger  <vapier@gentoo.org>
141
142         * Make-common.in (SIM_RUN_OBJS): Change to nrun.o.
143         * run.c [SIM_USE_DEPRECATED_RUN_FRONTEND]: Issue a warning.
144         [!SIM_USE_DEPRECATED_RUN_FRONTEND]: Throw an error.
145
146 2015-03-14  Mike Frysinger  <vapier@gentoo.org>
147
148         * sim-assert.h [!SIM_ASSERT, WITH_ASSERT]: Include sim-io.h.
149         [!ASSERT, WITH_ASSERT]: Likewise.
150         * sim-endian.c: Delete sim-io.h include.
151
152 2015-02-19  Mike Frysinger  <vapier@gentoo.org>
153
154         * run-sim.h (sim_kill): Delete unused prototype.
155
156 2015-02-13  Chen Gang  <gang.chen.5i5j@gmail.com>
157
158         * gentmap.c: Include "string.h".
159
160 2015-02-02  Chen Gang  <gang.chen.5i5j@gmail.com>
161
162         * sim-options.c (sim_args_command): Call freeargv() when failure
163         occurs.
164
165 2015-01-07  Joel Brobecker  <brobecker@adacore.com>
166
167         * aclocal.m4, configure: Regenerate using automake 1.11.1.
168
169 2014-12-03  Joel Brobecker  <brobecker@adacore.com>
170
171         * sim-io.c (sim_io_stat, sim_io_fstat): Adjust calls to "stat"
172         and "fstat" callbacks by calls to "to_stat" and "to_fstat" (resp)
173         callbacks following renaming in callback.h.
174         * syscall.c (cb_syscall): Likewise.  Adjust calls to "lstat"
175         callback by call to "to_lstat" callback
176
177 2014-08-28  Gary Benson  <gbenson@redhat.com>
178
179         * sim-trace.h (debug_printf): New define.
180
181 2014-08-19  Alan Modra  <amodra@gmail.com>
182
183         * configure: Regenerate.
184
185 2014-08-15  Roland McGrath  <mcgrathr@google.com>
186
187         * configure: Regenerate.
188         * config.in: Regenerate.
189
190 2014-03-10  Mike Frysinger  <vapier@gentoo.org>
191
192         * sim-command.c (sim_do_command): Add const to cmd.
193         * sim-options.c (sim_args_command): Add const to cmd.
194         * sim-options.h (sim_args_command): Add const to cmd.
195
196 2014-03-05  Mike Frysinger  <vapier@gentoo.org>
197
198         * sim-hload.c (sim_load): Add const to prog.
199         * sim-load.c (sim_load_file): Likewise.
200         * sim-utils.c (sim_analyze_program): Likewise.
201         * sim-utils.h (sim_analyze_program): Likewise.
202         (sim_load_file): Likewise.
203
204 2014-03-04  Mike Frysinger  <vapier@gentoo.org>
205
206         * acinclude.m4 (build_warnings): Copy from gdb/configure.ac.
207         * callback.c (system): Delete unused prototype.
208         (os_init): Likewise.
209         (os_shutdown): Likewise.
210         (os_unlink): Likewise.
211         (os_time): Likewise.
212         (os_system): Likewise.
213         (os_rename): Likewise.
214         (os_write_stdout): Likewise.
215         (os_flush_stdout): Likewise.
216         (os_write_stderr): Likewise.
217         (os_flush_stderr): Likewise.
218         (os_write): Likewise.
219         (os_read_stdin): Likewise.
220         (os_read): Likewise.
221         (os_open): Likewise.
222         (os_lseek): Likewise.
223         (os_isatty): Likewise.
224         (os_get_errno): Likewise.
225         (os_close): Likewise.
226         (os_vprintf_filtered): Likewise.
227         (os_evprintf_filtered): Likewise.
228         (os_error): Likewise.
229         (fdmap): Likewise.
230         (fdbad): Likewise.
231         (wrap): Likewise.
232         (wrap): Change to new style prototype.
233         (fdbad): Likewise.
234         (fdmap): Likewise.
235         (os_close): Likewise.
236         (os_poll_quit): Likewise.
237         (os_get_errno): Likewise.
238         (os_isatty): Likewise.
239         (os_lseek): Likewise.
240         (os_open): Likewise.
241         (os_read): Likewise.
242         (os_read_stdin): Likewise.
243         (os_write): Likewise.
244         (os_write_stdout): Likewise.
245         (os_flush_stdout): Likewise.
246         (os_write_stderr): Likewise.
247         (os_flush_stderr): Likewise.
248         (os_rename): Likewise.
249         (os_system): Likewise.
250         (os_time): Likewise.
251         (os_unlink): Likewise.
252         (os_stat): Likewise.
253         (os_fstat): Likewise.
254         (os_lstat): Likewise.
255         (os_ftruncate): Likewise.
256         (os_truncate): Likewise.
257         (os_pipe): Likewise.
258         (os_pipe_empty): Likewise.
259         (os_pipe_nonempty): Likewise.
260         (os_shutdown): Likewise.
261         (os_init): Likewise.
262         (cb_read_target_syscall_maps): Likewise.
263         (cb_target_to_host_syscall): Likewise.
264         (cb_host_to_target_errno): Likewise.
265         (cb_target_to_host_open): Likewise.
266         (cb_store_target_endian): Likewise.
267         (cb_host_to_target_stat): Likewise.
268         * sim-hload.c (sim_load): Change to new style prototype.
269         * sim-load.c (sim_load_file): Change to new style prototype.
270         (report_transfer_performance): Likewise.
271         (xprintf_bfd_vma): Likewise.
272         * syscall.c (cb_get_string): Change to new style prototype.
273         (get_path): Likewise.
274         (cb_syscall): Likewise.
275
276 2013-10-15  Hans-Peter Nilsson  <hp@axis.com>
277
278         * create-version.sh: Align parameters to match those of
279         ../../gdb/common/create-version.sh.
280         * Make-common.in (srcsim): New variable.
281         (version.c): Adjust call to create-version.sh as per above.
282
283 2013-09-23  Alan Modra  <amodra@gmail.com>
284
285         * configure: Regenerate.
286
287 2013-09-03  Mike Stump  <mikestump@comcast.net>
288
289         * sim-options.c (complete_option_list): Mark text and word const.
290
291 2013-06-28  Tom Tromey  <tromey@redhat.com>
292
293         * Make-common.in (version.c): Use version.in, not
294         common/version.in.
295         * create-version.sh: Likewise.
296
297 2013-06-24  Joel Brobecker  <brobecker@adacore.com>
298
299         * create-version.sh: New script. Adapted from
300         gdb/commong/create-version.sh.
301         * Make-common.in (version.c): Update rule dependencies,
302         and re-implement using create-version.sh.
303
304 2013-06-21  Nick Clifton  <nickc@redhat.com>
305
306         * gennltvals.sh: Add msp430 support.
307         * nltvals.def: Regenerate.
308
309 2013-06-03  Mike Frysinger  <vapier@gentoo.org>
310
311         * acinclude.m4: Replace maintainer-mode code with AM_MAINTAINER_MODE.
312         * aclocal.m4, configure: Regenerate.
313
314 2013-05-10  Freddie Chopin  <freddie_chopin@op.pl>
315
316         PR build/15414:
317         * acinclude.m4 (SIM_AC_OPTION_WARNINGS): Do not use
318         -Wformat-nonliteral with -Wno-format.
319
320 2013-03-26  Mike Frysinger  <vapier@gentoo.org>
321
322         * acinclude.m4: Regenerate.
323
324 2013-03-23  Joel Sherrill  <joel.sherrill@oarcorp.com>
325
326         * acinclude.m4: Add SIM_DV_SOCKSER_O which is empty  on hosts
327         which do not support dv-sockser.o.  Add always as option to
328         first argument to SIM_AC_OPTION_HARDWARE. Fail if hardware
329         is always required to be enabled by simulator.
330
331 2012-08-28  Kaushik Phatak  <kaushik.phatak@kpitcummins.com>
332
333         * gennltvals.sh: Use libgloss/syscall.h for cr16.
334         * nltvals.def: Regenerate.
335
336 2012-06-16  Joel Brobecker  <brobecker@adacore.com>
337
338         * acinclude.m4 (SIM_AC_COMMON): Define PACKAGE.
339         * config.in, configure: Regenerate.
340
341 2012-05-24  Pedro Alves  <palves@redhat.com>
342
343         * sim-signal.h (sim_signal_to_target): Rename to ...
344         (sim_signal_to_gdb_signal): ... this.
345         * sim-signal.c (sim_signal_to_target): Rename to ...
346         (sim_signal_to_gdb_signal): ... this.
347         * sim-reason.c (sim_stop_reason): Adjust to rename.
348
349 2012-05-24  Pedro Alves  <palves@redhat.com>
350
351         PR gdb/7205
352
353         Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
354
355 2012-05-24  Pedro Alves  <palves@redhat.com>
356
357         PR gdb/7205
358
359         Replace target_signal with gdb_signal throughout.
360
361 2012-05-18  Nick Clifton  <nickc@redhat.com>
362
363         PR 14072
364         * callback.c: Include config.h before system header files.
365         * cgen-trace.c: Likewise.
366         * cgen-utils.c: Likewise.
367         * gentmap.c: Likewise.
368
369 2012-04-02  Mike Frysinger  <vapier@gentoo.org>
370
371         * hw-ports.c (hw_port_decode): Change "Unreconized" to "Unrecognized".
372
373 2012-03-28  Rathish C  <rathish.c@kpitcummins.com>
374
375         * sim-trace.c: Update the function prototype of save_data_size.
376         Move the enum data_fmt from here...
377         * sim-trace.h: ...to here.
378         Add function prototype of save_data.
379
380 2012-03-25  Mike Frysinger  <vapier@gentoo.org>
381
382         * sim-core.h (sim_core_trans_addr): Add prototype.
383
384 2012-03-24  Hans-Peter Nilsson  <hp@axis.com>
385
386         * nrun.c: Add #ifdef HAVE_CONFIG_H and associated includes stanza
387         missing in last change.
388
389 2012-03-24  Mike Frysinger  <vapier@gentoo.org>
390
391         * acinclude.m4 (SIM_AC_COMMON): Call AC_USE_SYSTEM_EXTENSIONS.
392         * nrun.c: Include string.h/strings.h.
393         * aclocal.m4, config.in, configure: Regenerate.
394
395 2012-03-22  Mike Frysinger  <vapier@gentoo.org>
396
397         * acinclude.m4 (SIM_AC_OPTION_WARNINGS): Copy AC_ARG_ENABLE(werror),
398         WERROR_CFLAGS, and build_warnings from gdb/configure.ac.  Comment
399         out -Werror initialization.
400
401 2012-03-19  Mike Frysinger  <vapier@gentoo.org>
402
403         * Make-common.in (TAGS): Change a-z to [:lower:].
404         * acinclude.m4 (sim-trace): Likewise.
405         * gennltvals.sh: Change A-Z0-9 to [:upper:][:digit:].
406         Change A-Za-z0-9 to [:alnum:].
407
408 2012-03-18  Mike Frysinger  <vapier@gentoo.org>
409
410         * nrun.c (main): Display strsignal of sigrc.
411
412 2012-01-06  Mike Frysinger  <vapier@gentoo.org>
413
414         * Makefile.in (abs_srcdir): Declare.
415         (srcroot): Define in terms of abs_srcdir.
416         (headers): Change srcdir to abs_srcdir.
417
418 2012-01-02  Joel Brobecker  <brobecker@adacore.com>
419
420         * dv-sockser.h, sim-assert.h, sim-fpu.c: Reformat the copyright
421         header.
422
423 2011-12-19  Joel Brobecker  <brobecker@adacore.com>
424
425         * Make-common.in (hw-config.h): Work around bug in Solaris 2.8
426         system bourne shell.
427
428 2011-12-03  Mike Frysinger  <vapier@gentoo.org>
429
430         * syscall.c (cb_get_string): Rename from "get_string".
431         (get_path): Rename get_string call to cb_get_string.
432
433 2011-12-03  Mike Frysinger  <vapier@gentoo.org>
434
435         * Make-common.in (VPATH): Add $(srccom).
436         (DEP): Delete.
437         (DEPMODE, DEPDIR, depcomp, COMPILE.pre, COMPILE.post, COMPILE,
438         POSTCOMPILE): New variables.
439         (.c.o): Replace recipe with call to $(COMPILE) and $(POSTCOMPILE).
440         Include dependency files, when using GNU Make.  Delete all
441         dependency-only rules.
442         * aclocal.m4: Include ../../config/depstand.m4.  Call
443         ZW_CREATE_DEPDIR and ZW_PROG_COMPILER_DEPENDENCIES.
444         (MAKE, GMAKE): New substs.
445
446 2011-11-07  Mike Frysinger  <vapier@gentoo.org>
447
448         PR sim/13161
449         * configure.ac (AC_CHECK_FUNCS): Add posix_fallocate.
450         * configure, config.in: Regenerate.
451         * dv-cfi.c (attach_cfi_regs): Check for HAVE_POSIX_FALLOCATE.
452
453 2011-10-19  Mike Frysinger  <vapier@gentoo.org>
454
455         * acinclude.m4: Call AC_CHECK_LIB when $hardware contains cfi.
456
457 2011-10-18  John Wehle  <john@feith.com>  (tiny patch)
458
459         * sim-profile.c (profile_info): Only print the title once.
460
461 2011-10-17  Mike Frysinger  <vapier@gentoo.org>
462
463         * acinclude.m4: Rename from aclocal.m4.
464         * aclocal.m4: Regenerate.
465
466 2011-10-17  Mike Frysinger  <vapier@gentoo.org>
467
468         * aclocal.m4: Change AC_PREREQ comment to 2.64.
469         * common.m4: Delete.
470         * configure.ac: Change AC_PREREQ to 2.64.  Replace AC_CONFIG_HEADER
471         call and common.m4 include with SIM_AC_COMMON(cconfig.h).
472         * configure: Regenerate.
473
474 2011-10-14  Alexey Makhalov  <makhaloff@gmail.com>
475
476         * sim-alu.h (ALU32_AND): Clear carry flag.
477         (ALU32_AND): Clear carry flag.
478
479 2011-10-09  Mike Frysinger  <vapier@gentoo.org>
480
481         * dv-cfi.c: Include stdbool.h.
482
483 2011-10-09  Mike Frysinger  <vapier@gentoo.org>
484
485         * dv-cfi.c: Replace devices.h include with hw-base.h and hw-main.h.
486
487 2011-10-04  Mike Frysinger  <vapier@gentoo.org>
488
489         * aclocal.m4 (SIM_AC_COMMON): Call AM_ZLIB, ACX_PKGVERSION, and
490         ACX_BUGURL.  Define PKGVERSION and REPORT_BUGS_TO.
491
492 2011-07-12  Mike Frysinger  <vapier@gentoo.org>
493
494         * sim-command.c: Include sim-options.h.
495
496 2011-07-12  Mike Frysinger  <vapier@gentoo.org>
497
498         * aclocal.m4: Move sinclude comment after AC_INIT comment.
499
500 2011-07-12  Mike Frysinger  <vapier@gentoo.org>
501
502         * aclocal.m4 (SIM_AC_COMMON): Call AC_REQUIRE on AC_PROG_CC.
503         Delete direct call to AC_PROG_CC.
504
505 2011-07-05  Mike Frysinger  <vapier@gentoo.org>
506
507         * sim-command.c: New file.
508         * Make-common.in (SIM_NEW_COMMON_OBJS): Add sim-command.o.
509         (sim-command.o): New rule.
510
511 2011-05-27  Mike Frysinger  <vapier@gentoo.org>
512
513         * sim-options.c (standard_option_handler): Remove arg[0] check
514         when freeing simulator_sysroot.  Only strdup arg when arg[0] is
515         not an empty string, otherwise assign "" back to it.
516
517 2011-05-26  Mike Frysinger  <vapier@gentoo.org>
518
519         * nltvals.def: Regenerate to include Blackfin syscalls again.
520
521 2011-05-25  Mike Frysinger  <vapier@gentoo.org>
522
523         * sim-trace.c (OPTION_TRACE_SYSCALL): New enum.
524         (trace_options): Handle "trace-syscall" with OPTION_TRACE_SYSCALL.
525         (trace_option_handler): Handle OPTION_TRACE_SYSCALL.
526         (trace_idx_to_str): Likewise.
527         * sim-trace.h (TRACE_SYSCALL_IDX): New enum.
528         (TRACE_syscall): Define.
529         (WITH_TRACE_SYSCALL_P): Likewise.
530         (TRACE_SYSCALL_P): Likewise.
531
532 2011-05-23  Mike Frysinger  <vapier@gentoo.org>
533
534         * dv-glue.c (hw_glue_finish): Move "name" to function scope and
535         remove now-unnecessary sub-scope for glue->type setting.
536         Check to see if the "reg" property exists before we use it, and
537         if it doesn't exist, error out for "glue" devices.
538
539 2011-05-23  Mike Frysinger  <vapier@gentoo.org>
540
541         * dv-glue.c (hw_glue_finish): Set type to glue_or when name is
542         glue-or, and set type to glue_xor when name is glue-xor.
543         (hw_glue_port_event): Return immediately when type is glue_io
544         or unmatched.  Handle glue_or and glue_xor types.  Move HW_TRACE
545         and hw_port_event calls from glue_and to end of function.
546
547 2011-05-11  Mike Frysinger  <vapier@gentoo.org>
548
549         * callback.c, dv-pal.c, dv-sockser.c, hw-base.c, hw-device.c,
550         hw-instances.c, hw-ports.c, hw-properties.c, hw-tree.c, sim-abort.c,
551         sim-arange.c, sim-config.c, sim-core.c, sim-engine.c, sim-events.c,
552         sim-hw.c, sim-io.c, sim-memopt.c, sim-options.c, sim-profile.c,
553         sim-resume.c, sim-stop.c, syscall.c: Add space before parenthesis
554         around function arguments.
555
556 2011-04-14  Mike Frysinger  <vapier@gentoo.org>
557
558         * sim-options.c (complete_option_list, sim_complete_command):
559         New functions.
560
561 2011-04-02  Mike Frysinger  <vapier@gentoo.org>
562
563         * dv-glue.c: Fix up style.
564
565 2011-04-02  Mike Frysinger  <vapier@gentoo.org>
566
567         * hw-alloc.c (hw_alloc_data): Adjust brace.
568         * hw-base.c (hw_base_data): Likewise.
569         (generic_hw_unit_decode): Fix indentation.
570         * hw-device.h (_hw_unit, enum, hw): Adjust braces.
571         * hw-events.c (hw_event, hw_event_data): Likewise.
572         * hw-handles.c (hw_handle_mapping, hw_handle_data): Likewise.
573         * hw-instances.c (hw_instance_data): Likewise.
574         * hw-instances.h (hw_instance): Likewise.
575         * hw-main.h (hw_descriptor, enum): Likewise.
576         * hw-ports.c (hw_port_edge, hw_port_data, empty_hw_ports): Likewise.
577         * hw-ports.h (hw_port_descriptor): Likewise.
578         * hw-properties.c (hw_property_data): Likewise.
579         * hw-properties.h (enum, hw_property, _ihandle_runtime_property_spec,
580         _range_property_spec, _reg_property_spec): Likewise.
581         * hw-tree.c (_name_specifier, printer): Likewise.
582         (split_device_specifier, parse_string_property, hw_tree_traverse,
583         print_size, print_reg_property, print_string, print_properties):
584         Fix indentation.
585
586 2011-03-29  Mike Frysinger  <vapier@gentoo.org>
587
588         * aclocal.m4 (SIM_AC_OPTION_HARDWARE): Add cfi to default list.
589         * Make-common.in (dv-cfi.o): New rule.
590         * dv-cfi.c, dv-cfi.h: New files.
591
592 2011-03-21  Kevin Buettner  <kevinb@redhat.com>
593
594         * gennltvals.sh: Search sys/_default_fcntl.h, in addition to
595         fcntl.h and sys/fcntl.h, for constants.
596         * nltvals.def: Regenerate.
597         * sim-io.c (sim_io_stat, sim_io_fstat): New functions.
598         * sim-io.h (sys/types.h, sys/stat.h): Include.
599         (sim_io_stat, sim_io_fstat): Declare.
600
601 2011-03-14  Mike Frysinger  <vapier@gentoo.org>
602
603         * callback.c, cgen-engine.h, dv-core.c, dv-glue.c, dv-pal.c,
604         hw-base.c, hw-device.c, hw-device.h, hw-handles.c, hw-instances.c,
605         hw-ports.c, hw-ports.h, hw-properties.c, hw-tree.c, nrun.c,
606         run-sim.h, run.c, sim-alu.h, sim-assert.h, sim-base.h, sim-basics.h,
607         sim-config.c, sim-core.c, sim-core.h, sim-engine.h, sim-events.c,
608         sim-events.h, sim-fpu.c, sim-hw.c, sim-inline.h, sim-load.c,
609         sim-memopt.c, sim-n-core.h, sim-options.c, sim-profile.c,
610         sim-signal.c, sim-trace.c, sim-trace.h, sim-utils.c, sim-watch.c,
611         syscall.c: Trim trailing whitespace.
612
613 2011-03-05  Mike Frysinger  <vapier@gentoo.org>
614
615         * gennltvals.sh: Handle bfin targets.
616         * nltvals.def: Regenerate.
617
618 2011-02-25  Kevin Buettner  <kevinb@redhat.com>
619
620         * callback.c (fdbad): Return EBADF rather than EINVAL for bad
621         file descriptors.
622
623 2011-02-14  Mike Frysinger  <vapier@gentoo.org>
624
625         * hw-alloc.c (hw_alloc_data): Delete zalloc_p.
626         (hw_zalloc, hw_malloc): Delete zalloc_p reference.
627         (hw_free): Drop zfree logic and always call free.
628         * hw-base.c (hw_delete): Change zfree to free.
629         * hw-handles.c (hw_handle_remove_ihandle): Likewise.
630         (hw_handle_remove_phandle): Likewise.
631         * hw-instances.c (hw_instance_delete): Likewise.
632         * hw-tree.c (parse_reg_property): Likewise.
633         (parse_ranges_property): Likewise.
634         (parse_string_property): Likewise.
635         * sim-core.c (sim_core_uninstall): Likewise.
636         * sim-cpu.c (sim_cpu_free_all): Likewise.
637         * sim-hw.c (sim_hw_uninstall): Likewise.
638         * sim-memopt.c (do_memopt_delete): Likewise.
639         (sim_memory_uninstall): Likewise.
640         * sim-module.c (sim_module_uninstall): Likewise.
641         * sim-options.c (sim_parse_args): Likewise.
642         * sim-profile.c (profile_pc_cleanup): Likewise.
643         (profile_uninstall): Likewise.
644         * sim-watch.c (do_watchpoint_delete): Likewise.
645         * sim-utils.c (zfree): Delete.
646         (sim_state_free): Change zfree to free.
647         * sim-utils.h (zfree): Delete.
648
649 2011-02-13  Mike Frysinger  <vapier@gentoo.org>
650
651         * sim-events.h (_sim_events.time_from_event): Change type to signed64.
652
653 2011-01-12  Mike Frysinger  <vapier@gentoo.org>
654
655         * sim-hw.c (sim_hw_uninstall): Uncomment hw_tree_delete.
656
657 2011-01-12  Mike Frysinger  <vapier@gentoo.org>
658
659         * sim-module.c (sim_pre_argv_init): Return SIM_RC_FAIL when asprintf
660         fails.
661         * sim-options.c (sim_parse_args): Issue an error and return SIM_RC_FAIL
662         when asprintf fails.
663         * sim-utils.c (sim_do_commandf): Issue an error and return when
664         asprintf fails.
665         * sim-watch.c (sim_watchpoint_install): Return SIM_RC_FAIL when
666         asprintf fails.
667
668 2011-01-11  Mike Frysinger  <vapier@gentoo.org>
669
670         * sim-memopt.c (do_memopt_add): Set nr_bytes to s.st_size before
671         bytes has been calculated and when mmap_next_fd is valid and
672         nr_bytes is 0.
673         (memory_option_handler): Allow missing size when mmap_next_fd is
674         valid.
675
676 2011-01-10  Mike Frysinger  <vapier@gentoo.org>
677
678         * aclocal.m4 (SIM_AC_OPTION_HARDWARE): Set $hardware to $2 when $2 is
679         not empty, and always append $3 to $hardware.
680
681 2011-01-10  Mike Frysinger  <vapier@gentoo.org>
682
683         * hw-device.h (hw_abort, hw_vabort, hw_halt): Add noreturn attribute.
684         * sim-hw.h (sim_hw_abort): Likewise.
685
686 2011-01-05  Mike Frysinger  <vapier@gentoo.org>
687
688         * sim-load.c (sim_load_file): Change buffer type to unsigned char *.
689
690 2011-01-05  Joel Brobecker  <brobecker@adacore.com>
691
692         * run.1: Copyright year update.
693
694 2010-12-28  Mike Frysinger  <vapier@gentoo.org>
695
696         * hw-alloc.h (HW_NALLOC): Define.
697
698 010-12-28  Mike Frysinger  <vapier@gentoo.org>
699
700         * hw-alloc.h (HW_NZALLOC): Change ME,TYPE,N to me,type,n.
701
702 2010-12-15  Mike Frysinger  <vapier@gentoo.org>
703
704         * sim-memopt.c (OPTION_MAP_INFO): Define.
705         (memory_options): Handle --map-info.
706         (memory_option_handler): Handle OPTION_MAP_INFO.
707
708 2010-11-22  Mike Frysinger  <vapier@gentoo.org>
709
710         * sim-profile.c (PROFILE_PC_FREQ, PROFILE_PC_NR_BUCKETS,
711         PROFILE_PC_SHIFT, PROFILE_PC_START, PROFILE_PC_END,
712         PROFILE_INSN_COUNT): Add stubs when profile is disabled.
713
714 2010-11-22  Mike Frysinger  <vapier@gentoo.org>
715
716         * sim-core.c (WITH_HW): Add device casts to device_error,
717         device_io_read_buffer, and device_io_write_buffer.
718
719 2010-11-16  Mike Frysinger  <vapier@gentoo.org>
720
721         * dv-sockser.c (dv_sockser_write_buffer): New function.
722         (dv_sockser_write): Rewrite to use dv_sockser_write_buffer.
723         * dv-sockser.h (dv_sockser_write_buffer): New prototype.
724
725 2010-10-07  Hans-Peter Nilsson  <hp@axis.com>
726
727         * callback.c (os_lseek): Call wrap on lseek result.
728
729 2010-05-26  Ozkan Sezer  <sezeroz@gmail.com>
730
731         * dv-sockser.c (dv_sockser_init): Check error return from socket()
732         call by its equality to -1 not by it being negative.
733         (connected_p): Likewise for accept() call.
734
735 2010-04-23  Mike Frysinger  <vapier@gentoo.org>
736
737         * sim-fpu.c (sim_fpu_zero, sim_fpu_qnan): Add 0 initializers.
738
739 2010-04-21  Mike Frysinger  <vapier@gentoo.org>
740
741         * profile.c (sim_profile_print_bar): Add cpu argument.
742
743 2010-04-21  Mike Frysinger  <vapier@gentoo.org>
744
745         * sim-profile.h (sim_profile_print_bar): Use sim_cpu, not SIM_CPU.
746
747 2010-04-21  Mike Frysinger  <vapier@gentoo.org>
748
749         * sim-profile.c (profile_vprintf, profile_printf): New functions.
750         (profile_print_pc): Convert sim_io_printf to profile_printf.
751         (profile_print_insn): Likewise.
752         (profile_print_memory): Likewise.
753         (profile_print_core): Likewise.
754         (profile_print_model): Likewise.
755         (sim_profile_print_bar): Likewise.
756         (profile_print_speed): Likewise.
757         (profile_print_addr_ranges): Likewise.
758         (profile_info): Likewise.
759         * sim-profile.h (sim_profile_print_bar): Add cpu argument.
760
761 2010-04-19  Mike Frysinger  <vapier@gentoo.org>
762
763         * sim-model.c (OPTION_MODEL): Convert to enum.
764         (OPTION_MODEL_INFO): New enum.
765         (model_options): Add model-info/info-model entries.
766         (model_option_handler): Handle OPTION_MODEL_INFO.
767
768 2010-04-13  Mike Frysinger  <vapier@gentoo.org>
769
770         * dv-sockser.h (DV_SOCKSER_DISCONNECTED): Define.
771         * dv-sockser.c (dv_sockser_status): Set DV_SOCKSER_DISCONNECTED
772         initially.
773
774 2010-04-13  Mike Frysinger  <vapier@gentoo.org>
775
776         * sim-hrw.c (sim_write): Add const to buf arg.
777         * sim-utils.h (sim_write_fn): Likewise.
778
779 2010-04-12  Mike Frysinger  <vapier@gentoo.org>
780
781         * sim-profile.h (PROFILE_BRANCH_TAKEN, PROFILE_BRANCH_UNTAKEN): New
782         defines.
783
784 2010-04-12  Mike Frysinger  <vapier@gentoo.org>
785
786         * dv-core.c (dv_core_descriptor): Add NULL initializer.
787         * dv-glue.c (hw_glue_ports, dv_glue_descriptor): Likewise.
788         * dv-pal.c (hw_pal_ports, dv_pal_descriptor): Likewise.
789         * dv-sockser.c (sockser_options): Likewise.
790         * hw-ports.c (empty_hw_ports): Likewise.
791         * sim-hw.c (hw_options): Likewise.
792         * sim-model.c (model_options): Likewise.
793         * sim-options.c (standard_options): Likewise.
794         * sim-profile.c (profile_options): Likewise.
795         * sim-trace.c (trace_options): Likewise.
796         * sim-watch.c (watchpoint_options): Likewise.
797
798 2010-04-12  Mike Frysinger  <vapier@gentoo.org>
799
800         * sim-options.c (dup_arg_p): Add "const" to the "arg" argument,
801         the local "arg_table" variable, and the xmalloc cast.
802
803 2010-04-10  Mike Frysinger  <vapier@gentoo.org>
804
805         * sim-fpu.c (sim_fpu_print_status): Add const markings to local
806         "prefix" var.
807         (sim_fpu_print_func): Add const markings to format buffer.
808
809 2010-04-10  Mike Frysinger  <vapier@gentoo.org>
810
811         * sim-fpu.c (sim_fpu_print_status): Remove duplicate break statements.
812
813 2010-04-10  Mike Frysinger  <vapier@gentoo.org>
814
815         * sim-trace.c (save_data): Add const markings to "buf" argument.
816
817 2010-04-10  Mike Frysinger  <vapier@gentoo.org>
818
819         * sim-options.c (standard_option_handler): Add const markings to
820         local "type" var.
821
822 2010-04-02  Mike Frysinger  <vapier@gentoo.org>
823
824         * hw-ports.h: Fix spelling typos.
825
826 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
827
828         * configure.ac: Check for socklen_t.
829         * configure, config.in: Regenerated.
830         * dv-sockser.c (connected_p): Change addrlen type to socklen_t.
831
832 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
833
834         * sim-utils.c (sim_io_eprintf_cpu): Use %s with printf string.
835         * sim-hw.c (hw_option_handler): Likewise.
836
837 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
838
839         * sim-watch.c (watchpoint_type_to_str): Add const to return.
840         (interrupt_nr_to_str): Likewise.
841         (default_interrupt_names): Add const to pointer type.
842         (sim_watchpoint_install): Add const to prefix.
843         * sim-watch.h (struct _sim_watchpoints): Add const to interrupt_names.
844
845 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
846
847         * sim-core.c (sim_core_read_buffer): Change raddr to address_word.
848         (sim_core_write_buffer): Likewise.
849
850 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
851
852         * sim-trace.c (trace_option_handler): Move cpu_nr decl behind
853         the SIM_HAVE_ADDR_RANGE define.
854
855 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
856
857         * sim-core.h (device_error): Add const to message, and add printf
858         format attribute.
859
860 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
861
862         * sim-profile.c (profile_print_addr_ranges): Wrap with the
863         SIM_HAVE_ADDR_RANGE define.
864
865 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
866
867         * dv-glue.c (hw_glue_ports): Swap static and const.
868
869 2010-03-30  Mike Frysinger  <vapier@gentoo.org>
870
871         * nrun.c (usage): Use void in definition.
872         * sim-options.c (dup_arg_p): Convert old-style function definition.
873         (sim_parse_args): Likewise.
874         (sim_print_help): Likewise.
875         * sim-trace.c (set_trace_option_mask): Likewise.
876         (set_trace_option): Likewise.
877         * sim-utils.c (sim_analyze_program): Likewise.
878         (sim_elapsed_time_get): Likewise.
879         (sim_elapsed_time_since): Likewise.
880
881 2010-03-22  Mike Frysinger  <vapier@gentoo.org>
882
883         * sim/common/sim-options.c (enum): Remove SIM_HAVE_BIENDIAN ifdef.
884         (standard_options): Likewise.
885         (standard_option_handler): Likewise.
886
887 2010-03-16  Mike Frysinger  <vapier@gentoo.org>
888
889         * hw-ports.c (TRACE): Delete.
890         * hw-properties.c (TRACE): Delete.
891         (hw_find_ihandle_runtime_property): Change TRACE to HW_TRACE.
892         (hw_find_integer_property): Likewise.
893         (hw_find_integer_array_property): Likewise.
894         (hw_add_duplicate_property): Likewise.
895
896 2010-03-15  Mike Frysinger  <vapier@gentoo.org>
897
898         * hw-properties.h (hw_add_boolean_property): Rename "bool" to
899         "boolean".
900
901 2010-02-04  Mike Frysinger  <vapier@gentoo.org>
902
903         * sim-model.c: Include sim-model.h
904
905 2010-02-04  Mike Frysinger  <vapier@gentoo.org>
906
907         * sim-base.h: Declare sim_state.cpu as a pointer in the comment.  Drop
908         & from the STATE_CPU() examples.
909
910 2010-01-24  Doug Evans  <dje@sebabeach.org>
911
912         * cgen-accfp.c (fextsfdf): New arg how.  All callers updated.
913         (ftruncdfsf, floatsisf, flostsidf, ufloatsisf, fixsfsi, fixdfsi,
914         ufixsfsi): Ditto.
915         * cgen-fpu.h (CGEN_FPCONV_KIND): New enum.
916         (struct cgen_fp_ops): Update signatures of floating point conversion
917         operations.
918
919         * Make-common.in (CGEN_SIM_DEPS): Define.
920         (CGEN_INCLUDE_DEPS): Use it.
921         (CGEN_MAIN_CPU_DEPS): Simplify.
922
923 2010-01-22  Doug Evans  <dje@sebabeach.org>
924
925         * cgen-ops.h (SUBWORDXFSI): Fix word ordering.
926         (SUBWORDTFSI, JOINSIDI): Ditto.
927
928 2010-01-05  Doug Evans  <dje@sebabeach.org>
929
930         * cgen-types.h (SETDI): Delete, unused.
931
932 2009-12-02  Doug Evans  <dje@sebabeach.org>
933
934         * cgen-engine.h: Remove duplicated comment.
935
936 2009-11-23  Doug Evans  <dje@sebabeach.org>
937
938         * cgen-engine.h (EXTRACT_MSB0_SINT): Renamed from EXTRACT_MSB0_INT.
939         (EXTRACT_LSB0_SINT): Renamed from EXTRACT_LSB0_INT.
940
941 2009-11-22  Doug Evans  <dje@sebabeach.org>
942
943         * cgen-engine.h (EXTRACT_MSB0_LGSINT, EXTRACT_MSB0_LGUINT): Define.
944         (EXTRACT_LSB0_LGSINT, EXTRACT_LSB0_LGUINT): Define.
945         (EXTRACT_FN, SEMANTIC_FN): Use CGEN_INSN_WORD in prototype
946         instead of CGEN_INSN_INT.
947
948         * cgen-trace.h (trace_extract): Add cast to fix warning.
949
950 2009-11-05  Doug Evans  <dje@sebabeach.org>
951
952         * cgen-mem.h (DECLARE_GETT): Don't inline.
953         (DECLARE_SETT): Ditto.
954
955 2009-10-15  Joel Sherrill <joel.sherrill@oarcorp.com>
956
957         * sim-inline.h: Fix spelling error.
958
959 2009-10-02  Ralf Corsepius <ralf.corsepius@rtems.org>
960
961         * Make-common.in: Add datarootdir.
962
963 2009-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
964
965         * aclocal.m4 (SIM_CHECK_MEMBER, SIM_CHECK_MEMBERS)
966         (SIM_CHECK_MEMBERS_1): Remove.
967         * configure.ac: Replace SIM_CHECK_MEMBERS call with equivalent
968         AC_CHECK_MEMBERS one.
969         * configure: Regenerate.
970
971         * aclocal.m4 (SIM_CHECK_MEMBER): Use AU_ALIAS to define, not defn.
972         * configure: Regenerate.
973
974 2009-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
975
976         * config.in: Regenerate.
977         * configure: Likewise.
978
979         * aclocal.m4 (SIM_CHECK_MEMBER): Replace definition with
980         definition of AC_CHECK_MEMBER.
981
982         * aclocal.m4: m4_include toplevel config/override.m4.
983         * configure: Regenerate.
984
985 2009-07-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
986
987         * Makefile.in (datarootdir): New variable.
988
989 2009-07-07  Doug Evans  <dje@sebabeach.org>
990
991         * Make-common.in (CPU_DIR): Define.
992
993 2009-07-06  Doug Evans  <dje@sebabeach.org>
994
995         * Make-common.in (CGEN_CPU_EXTR,CGEN_CPU_READ): Pass canonical
996         identifiers for file types rather than encoding internal
997         implementation details of cgen.sh.
998         (CGEN_CPU_WRITE,CGEN_CPU_SEM,CGEN_CPU_SEMSW): Ditto.
999         * cgen.sh: Add support for parallel makes.
1000         Rewrite cpu/decode handling to avoid generating "extrafiles" twice.
1001
1002 2009-05-18  Jon Beniston <jon@beniston.com>
1003
1004         * gennltvals.sh: Add lm32 target.
1005         * nltvals.def: Add lm32 syscall definitions. 
1006
1007 2009-03-19  J"orn Rennecke  <joern.rennecke@arc.com>  (tiny change)
1008
1009         Speed up simulator startup:
1010         * sim-utils.c (zalloc): Use xcalloc.
1011
1012 2009-01-07  Hans-Peter Nilsson  <hp@axis.com>
1013
1014         * cgen-ops.h (ADDQI, SUBQI, MULQI, NEGQI, ABSQI, ADDHI, SUBHI)
1015         (MULHI, NEGHI, ABSHI, ADDSI, SUBSI, MULSI, NEGSI, ABSSI, ADDDI)
1016         (SUBDI, MULDI, NEGDI, ABSDI): Cast arguments to the unsigned type
1017         variant; UQI, UHI, USI, UDI, and cast the result to the signed
1018         type, QI, HI, SI, DI.
1019
1020         * callback.c (os_error): Mark as being a noreturn function.
1021         * sim-io.h (sim_io_error): Similar for sim_io_error.
1022
1023 2008-11-12  Joel Sherrill <joel.sherrill@oarcorp.com>
1024
1025         * aclocal.m4:  Fix underquoting of function names.
1026
1027 2008-10-21  Julian Brown  <julian@codesourcery.com>
1028
1029         * Make-common.in (run$(EXEEXT)): Add LDFLAGS.
1030
1031 2008-07-11  Hans-Peter Nilsson  <hp@axis.com>
1032
1033         * common.m4: Add test for libz and zlib.h.
1034         * configure: Regenerate to track ../common/common.m4 changes.
1035         * config.in: Ditto.
1036
1037 2008-06-06  Vladimir Prus  <vladimir@codesourcery.com>
1038             Daniel Jacobowitz  <dan@codesourcery.com>
1039             Joseph Myers  <joseph@codesourcery.com>
1040
1041         * aclocal.m4: Include ../../config/acx.m4.
1042         * common.m4: Use ACX_PKGVERSION and ACX_BUGURL.
1043         * configure, config.in: Regenerate.
1044         * Make-common.in (LIB_OBJS): Add version.o.
1045         (version.c, version.o): New rules.
1046         * run.c: Include version.h. 
1047         (usage): Add help parameter. Print output either to stdout or
1048         stderr depending on that parameter.
1049         (print_version): New.
1050         (main): Check for --help and --version.
1051         * run-sim.h (sim_target_display_usage): Add help parameter.
1052         * version.h: New.
1053
1054 2008-04-14  Hans Kester  <kester.hans@gmail.com>
1055
1056         * sim-signal.c: Define missing signals for _WIN32.
1057
1058 2008-02-12  M Ranga Swami Reddy  <MR.Swami.Reddy@nsc.com>
1059
1060         * gennltvals.sh: Add cr16.
1061         * nltvals.def: Rebuild.
1062
1063 2007-10-11  Jesper Nilsson  <jesper.nilsson@axis.com>
1064
1065         * callback.c (cb_is_stdin, cb_is_stdout, cb_is_stderr): Add functions.
1066         * syscall.c (cb_syscall): Test for stdin/out/err, not just fd 0/1/2.
1067
1068 2007-08-10  Nick Clifton  <nickc@redhat.com>
1069
1070         * sim-memopt.c (memory_options): Mention that the
1071         --memory-size switch accepts suffixes.
1072         (parse_size): Handle a suffix on the size value.
1073         * sim-options.c (standard_options): Mention that the mem-size
1074         switch accepts suffixes.
1075         (standard_option_handler): Handle a suffix on the size value.
1076
1077 2006-12-21  Hans-Peter Nilsson  <hp@axis.com>
1078
1079         * acconfig.h: Remove.
1080         * config.in: Regenerate.
1081
1082 2006-11-07  Thiemo Seufer  <ths@mips.com>
1083
1084         * gentmap.c: Fix compile time warning.
1085
1086 2006-11-07  Thiemo Seufer  <ths@mips.com>
1087
1088         * sim-base.h (text_start, text_end, start_addr): Use bfd_vma type
1089         for bfd text addresses.
1090
1091 2006-08-29  Thiemo Seufer  <ths@mips.com>
1092             Nigel Stephens  <nigel@mips.com>
1093
1094         * sim-fpu.c (pack_fpu): Handle QUIET_NAN correctly for
1095         SIM_QUIET_NAN_NEGATED.
1096
1097 2006-08-29  Nigel Stephens  <nigel@mips.com>
1098
1099         * sim-profile.c (profile_pc_init): Initialise default profiling
1100         frequency to a prime number.
1101         (profile_print_pc): Convert gmon.out sample data into target
1102         byte order.
1103
1104 2006-06-13  Richard Earnshaw  <rearnsha@arm.com>
1105
1106         * aclocal.m4: Pass ../../intl to ZW_GNU_GETTEXT_SISTER_DIR.
1107         * common.m4: Likewise.
1108         * configure: Regenerated.
1109
1110 2006-06-05  Daniel Jacobowitz  <dan@codesourcery.com>
1111
1112         * aclocal.m4: Use ZW_GNU_GETTEXT_SISTER_DIR.
1113         * configure: Regenerated.
1114
1115 2006-05-31  Daniel Jacobowitz  <dan@codesourcery.com>
1116
1117         * Make-common.in: Replace INTLLIBS and INTLDEPS with LIBINTL
1118         and LIBINTL_DEP everywhere.
1119         (CSEARCH): Use INCINTL.
1120         * aclocal.m4: Use ZW_GNU_GETTEXT_SISTER_DIR.  Include new
1121         gettext macros.
1122         * configure: Regenerated.
1123
1124 2006-03-29  Hans-Peter Nilsson  <hp@axis.com>
1125
1126         * aclocal.m4 (SIM_AC_OPTION_HARDWARE): Correct duplicate-
1127         option-contents test.
1128
1129 2005-11-28  Mark Mitchell  <mark@codesourcery.com>
1130
1131         * sim-signal.c (sim_signal_to_target): Fix typos.
1132
1133         * sim-reason.c (sim_stop_reason): Use
1134         sim_signal_to_target, not sim_signal_to_host.
1135         * sim-signal.c (sim_signal_to_host): Fix typo.
1136         (sim_signal_to_target): New function.
1137
1138 2005-07-10  Hans-Peter Nilsson  <hp@bitrange.com>
1139
1140         * sim-load.c (xprintf, eprintf): Remove fallout from ANSI_PROTOTYPES
1141         change.
1142
1143 2005-07-08  Ian Lance Taylor  <ian@airs.com>
1144
1145         * sim-fpu.c (sim_fpu_abs): Always clear the sign bit.
1146
1147         * sim-fpu.c (pack_fpu): If SIM_QUIET_NAN_NEGATED is defined, use a
1148         different fraction for a quiet NaN.
1149         (unpack_fpu): Likewise.
1150
1151 2005-07-08  Ben Elliston  <bje@au.ibm.com>
1152
1153         * callback.c: Remove ANSI_PROTOTYPES conditional code.
1154         * sim-load.c: Likewise.
1155         * syscall.c: Likewise.
1156
1157 2005-05-24  Corinna Vinschen  <vinschen@redhat.com>
1158
1159         * Make-common.in (LIBDEPS): Correctly use INTLDEPS for dependency
1160         check.
1161
1162 2005-05-17  Daniel Jacobowitz  <dan@codesourcery.com>
1163
1164         * Make-common.in (install-common, installdirs): Honor $DESTDIR.
1165
1166 2005-04-20  Manoj Iyer  <manjo@austin.ibm.com>
1167
1168         * sim-types.h: Changed unsigned32 and unsigned64 to signed32
1169         and signed64 for __ALPHA__.
1170
1171 2005-03-23  Mark Kettenis  <kettenis@gnu.org>
1172
1173         * aclocal.m4 Include ../../gettext.m4.
1174         (CY_WITH_NLS, CY_GNU_GETTEXT, AM_PATH_PROG_WITH_TEST)
1175         (AM_LC_MESSAGES): Remove.
1176         * configure: Regenerate.
1177
1178 2005-02-28  Jim Blandy  <jimb@redhat.com>
1179
1180         * aclocal.m4 (SIM_AC_OPTION_WARNINGS): Don't include
1181         -Wuninitialized in the default list of build warnings if CFLAGS is
1182         set, and doesn't include -O.  (Using -Wuninitialized without
1183         optimization produces a warning, which interferes with compilation
1184         with -Werror.)
1185         
1186 2005-02-21  Jim Blandy  <jimb@redhat.com>
1187
1188         * callback.c (os_fstat): Don't declare 't' unless it's used.
1189
1190 2005-02-09  Jim Blandy  <jimb@redhat.com>
1191
1192         * Make-common.in (CGEN): Load guile.scm, and include a trailing
1193         '-s' argument.
1194         (CGEN_FLAGS_TO_PASS): Include single quotes around the reference
1195         to $(CGEN), to ensure that the command substitution happens where
1196         the variable is referenced in the submake, not when the submake's
1197         arguments are expanded.
1198         (cgen.sh): Be prepared for the 'cgen' argument to contain spaces.
1199         (arch, cpu, decode, cpu-decode, defs, desc): Place the name of the
1200         application Scheme script directly after ${cgen}; don't precede it
1201         with a -s.
1202
1203 2005-01-28  Hans-Peter Nilsson  <hp@axis.com>
1204
1205         * syscall.c (cb_syscall) <case CB_SYS_pipe>: New case.
1206         * callback.c [HAVE_LIMITS_H]: Include limits.h.
1207         Include libiberty.h.
1208         (os_close, os_read, os_write, os_fstat, os_ftruncate): Support fd
1209         being either end of a pipe.
1210         (os_pipe, os_pipe_empty, os_pipe_nonempty): New functions.
1211         (os_shutdown): Clear pipe state.
1212         (default_callback): Initialize new members.
1213
1214         * callback.c (default_callback): Initialize target_endian.
1215         (cb_store_target_endian): Renamed from store, new first parameter
1216         host_callback *cb, drop last parameter big_p.  Take endianness
1217         from cb.
1218         (cb_host_to_target_stat): Change to use cb_store_target_endian.
1219         Remove variable big_p.
1220         * nrun.c (main): Initialize default_callback.target_endian.
1221
1222 2005-01-14  Andrew Cagney  <cagney@gnu.org>
1223
1224         * configure.ac: Replace SIM_AC_COMMON with sinclude of common.m4.
1225         Add explicit call to AC_CONFIG_HEADER.
1226         * common.m4: Delete call to AC_CONFIG_HEADER, update usage.
1227         * configure: Re-generate.
1228
1229 2005-01-12  Andrew Cagney  <cagney@gnu.org>
1230
1231         * common.m4: New file, based on of aclocal.m4.
1232
1233 2005-01-11  Andrew Cagney  <cagney@localhost.localdomain>
1234
1235         * aclocal.m4 (SIM_AC_OUTPUT): Rewrite to use 2.59 macros.
1236         * configure: Regenerated to track ../common/aclocal.m4 changes.
1237
1238 2005-01-07  Andrew Cagney  <cagney@gnu.org>
1239
1240         * configure.ac: Rename configure.in, require autoconf 2.59.
1241         * aclocal.m4 (SIM_AC_COMMON): Delete call to AC_CONFIG_AUX_DIR.
1242         * configure: Re-generate.
1243
1244 2004-12-15  Hans-Peter Nilsson  <hp@axis.com>
1245
1246         * syscall.c (cb_syscall) <case CB_SYS_truncate>
1247         <case CB_SYS_ftruncate>: New cases.
1248
1249 2004-12-13  Hans-Peter Nilsson  <hp@axis.com>
1250
1251         * syscall.c (cb_syscall) <case CB_SYS_lstat>: New case.
1252         (cb_syscall) <case CB_SYS_rename>: New case.
1253         * callback.c (os_lstat): New function.
1254
1255 2004-12-08  Hans-Peter Nilsson  <hp@axis.com>
1256
1257         * run.1: Document --sysroot=filepath.
1258         * sim-options.c (STANDARD_OPTIONS): New member OPTION_SYSROOT.
1259         (standard_options): Support --sysroot=<path>.
1260         (standard_option_handler): Handle OPTION_SYSROOT.
1261         * syscall.c (simulator_sysroot): Define, initialized empty.
1262         (get_path): Prepend simulator_sysroot to absolute file path.
1263         [HAVE_STRING_H]: Include string.h.
1264         [!HAVE_STRING_H && HAVE_STRINGS_H]: Include strings.h.
1265         * nrun.c [HAVE_UNISTD_H]: Include unistd.h.
1266         (main): If simulator_sysroot is not empty, chdir there.
1267         * sim-config.h (simulator_sysroot): Declare.
1268
1269         * aclocal.m4 (SIM_AC_OUTPUT): Substitute @cgen_breaks@ for "break
1270         cgen_rtx_error" in a CGEN-generated simulator.
1271         * gdbinit.in: Break on sim_core_signal too.  Have autoconf
1272         replacement for CGEN-related breakpoints.
1273
1274 2004-12-07  Hans-Peter Nilsson  <hp@axis.com>
1275
1276         * Make-common.in (sim-basics_h): Add $(callback_h).
1277
1278 2004-12-03  Hans-Peter Nilsson  <hp@axis.com>
1279
1280         * configure.in (SIM_CHECK_MEMBERS): Call for struct stat members
1281         st_dev, st_ino, st_mode, st_nlink, st_uid, st_gid, st_rdev,
1282         st_size, st_blksize, st_blocks, st_atime, st_mtime and st_ctime.
1283         * aclocal.m4 (SIM_CHECK_MEMBER, SIM_CHECK_MEMBERS_1)
1284         (SIM_CHECK_MEMBERS): New macros.
1285         * callback.c (cb_host_to_target_stat): Use temporary macro ST_x
1286         for struct stat member test and write.  Add ST_x calls for each
1287         struct stat member tested in configure.in.  Wrap each ST_x call in
1288         #ifdef of configure macro for that member.
1289         * configure, config.in: Regenerate.
1290
1291 2004-12-01  Hans-Peter Nilsson  <hp@axis.com>
1292
1293         * cgen.sh: New thirteenth parameter opcfile, defaulting to
1294         /dev/null.
1295         <case desc>: Pass -OPC opcfile.
1296         * Make-common.in (cgen-desc): Pass $(opcfile) as thirteenth
1297         parameter to cgen.sh.
1298
1299 2004-11-30  Richard Earnshaw  <rearnsha@arm.com>
1300
1301         * Make-common.in (sim-basics_h): Correct dependencies on
1302         cconfig.h and tconfig.h
1303         (sim-load.o): Correct typo in sim-basics_h dependency.
1304
1305 2004-11-18  Richard Earnshaw  <rearnsha@arm.com>
1306
1307         * Make-common.in (sim-*_h): Add macros for all sim headers listing
1308         sub-dependencies for other sim files that they include.
1309         (sim_main_headers): Use sim-*_h macros.
1310         (sim-load.o): Depend on sim-basics_h, not sim_main_headers.
1311
1312 2004-11-16  Hans-Peter Nilsson  <hp@axis.com>
1313
1314         * sim-config.c (sim_config): Recognize when a bfd has unspecified
1315         endian information.
1316
1317         * Make-common.in (sim-load.o): Depend on $(sim_main_headers) and
1318         $(remote_sim_h) too.
1319         (sim_main_headers): Add sim-utils.h.
1320
1321 2004-10-07  Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
1322
1323         * cgen-defs.h (ENDSWITCH): Changed to compile with gcc-3.4.2.
1324
1325 2004-07-26  Andrew Cagney  <cagney@gnu.org>
1326
1327         Problem from Olaf Hering <olh@suse.de>.
1328         * Makefile.in (install-man, installdirs): Add DESTDIR prefix.
1329
1330 2004-07-10  Ben Elliston  <bje@au.ibm.com>
1331
1332         * hw-tree.c (parse_integer_property): Typo fix in comments.
1333         * sim-options.c (sim_args_command): Likewise.
1334
1335 2004-06-28  Andrew Cagney  <cagney@gnu.org>
1336
1337         * run.c: Rename ui_loop_hook to deprecated_ui_loop_hook.
1338
1339 2004-06-27  J"orn Rennecke <joern.rennecke@superh.com>
1340
1341         * callback.c (os_shutdown): Fix bug in last change: actually
1342         mark file descriptors as available on startup.
1343
1344 2004-06-25  J"orn Rennecke <joern.rennecke@superh.com>
1345
1346         [ include/gdb: * callback.h (host_callback_struct): Replace
1347                        members fdopen and alwaysopen with fd_buddy.  ]
1348         * callback.c: Changed all users.
1349
1350 2004-06-15  Alan Modra  <amodra@bigpond.net.au>
1351
1352         * sim-load.c (sim_load_file): Use bfd_get_section_size
1353         instead of bfd_get_section_size_before_reloc.
1354
1355 2004-05-18  Daniel Jacobowitz  <dan@debian.org>
1356
1357         * dv-glue.c (hw_glue_finish): Cast result of sizeof to long before
1358         passing it to printf.
1359
1360 2004-05-10  Daniel Jacobowitz  <dan@debian.org>
1361
1362         * callback.c: Update copyright dates.
1363         * run.c: Likewise.
1364         * sim-basics.h: Likewise.
1365         * sim-load.c: Likewise.
1366         * syscall.c: Likewise.
1367
1368 2004-05-10  Maciej W. Rozycki  <macro@ds2.pg.gda.pl>
1369
1370         * callback.c: Include cconfig.h instead of config.h.
1371         * run.c: Likewise.
1372         * sim-basics.h: Likewise.
1373         * sim-load.c: Likewise.
1374         * syscall.c: Likewise.
1375
1376 2004-01-16  Ben Elliston  <bje@wasabisystems.com>
1377
1378         * Makefile.in (clean): Remove rm -f $(ALL), as $(ALL) is empty.
1379
1380 2003-12-19  Kazuhiro Inaoka  <inaoka.kazuhiro@renesas.com>
1381
1382         * sim-core.c (sim_core_trans_addr): Added for m32r-linux-run.
1383
1384 2003-11-22  Kazu Hirata  <kazu@cs.umass.edu>
1385
1386         * sim-options.c (standard_options): Fix the names of H8
1387         variants.
1388
1389 2003-10-30  Andrew Cagney  <cagney@redhat.com>
1390
1391         * sim-trace.c, sim-base.h: Replace "struct symbol_cache_entry"
1392         with "struct bfd_symbol".
1393
1394 2003-10-21  Andrew Cagney  <cagney@redhat.com>
1395
1396         * callback.c (os_truncate): Call "truncate", and not "stat".
1397
1398 2003-10-20  Andrew Cagney  <cagney@redhat.com>
1399
1400         * sim-base.h: Replace "struct sec" with "struct bfd_section".
1401
1402 2003-10-15  J"orn Rennecke <joern.rennecke@superh.com>
1403
1404         * callback.c (os_ftruncate, os_truncate): New functions.
1405         (default_callback): Initialize ftruncate and truncate members.
1406
1407 2003-09-08  Dave Brolley  <brolley@redhat.com>
1408
1409         On behalf of Doug Evans <dje@sebabeach.org>
1410         * cgen.sh: New arg archfile.
1411         * Make-common.in (cgen-arch,cgen-cpu,cgen-defs,cgen-decode,
1412         cgen-cpu-decode,cgen-desc): Update call to cgen.sh.
1413
1414 2003-08-28  Andrew Cagney  <cagney@redhat.com>
1415
1416         * dv-glue.c (hw_glue_finish): Change %d to %ld to match sizeof.
1417         * sim-options.c (print_help): Cast the format with specifier to
1418         "int".
1419
1420 2003-08-20  Michael Snyder  <msnyder@redhat.com>
1421             Dave Brolley  <brolley@redhat.com>
1422
1423         * cgen-par.h (flags, word1): New target-specific 
1424         fields of CGEN_WRITE_QUEUE_ELEMENT.
1425         (CGEN_WRITE_QUEUE_ELEMENT_FLAGS): New accessor macro.
1426         (CGEN_WRITE_QUEUE_ELEMENT_WORD1): New accessor macro.
1427         * gennltvals.sh: Add frv target.
1428         * nltvals.def: Add frv target.
1429
1430 2003-06-23  Michael Snyder  <msnyder@redhat.com>
1431
1432         * nrun.c (main): Delete h8/300 ifdef (sim now handles signals).
1433         * sim-reg.c: Fix cut-and-paste bug in comment.
1434
1435 2003-06-22  Andrew Cagney  <cagney@redhat.com>
1436
1437         From matthew green <mrg@redhat.com>:
1438         * sim-fpu.h: Update copyright.
1439         (sim_fpu_fraction, sim_fpu_guard): New prototypes.
1440         * sim-fpu.c: Update copyright.
1441         (sim_fpu_fraction, sim_fpu_guard): New inline functions.
1442
1443 2003-06-17  Frank Ch. Eigler  <fche@redhat.com>
1444
1445         From Doug Evans <dje@sebabeach.org>:
1446         * cgen-trace.h (sim_disasm_read_memory): Update args to be compatible
1447         with disassemble_info:read_memory_func.
1448         * cgen-trace.c (sim_disasm_read_memory): Ditto.
1449
1450 2003-06-04  Michael Snyder  <msnyder@redhat.com>
1451
1452         * common/run.c (main): Remove SIM_H8300 ifdef.
1453         (usage): Ditto.
1454         * common/sim-options.c (STANDARD_OPTIONS): Add SIM_H8300SX.
1455         (standard_options): Add '-x' for h8/300sx.
1456         (standard_option_handler): Add case for SIM_H8300SX.
1457
1458 2003-04-13  Michael Snyder  <msnyder@redhat.com>
1459
1460         * Make-common.in (sim-events.o, sim-config.o): Depend on sim-main.h.
1461
1462 2003-03-01  Andrew Cagney  <cagney@redhat.com>
1463
1464         * sim-engine.c (sim_engine_halt): If jmpbuf is invalid, abort.
1465         (sim_engine_vabort): Ditto.
1466
1467 2003-02-27  Andrew Cagney  <cagney@redhat.com>
1468
1469         * sim-utils.h (sim_analyze_program, sim_load_file): Rename _bfd to bfd.
1470         * sim-hload.c (sim_load), sim-base.h (sim_state_base): Ditto.
1471         * nrun.c (main): Ditto.
1472
1473 2003-02-26  Andrew Cagney  <cagney@redhat.com>
1474
1475         * sim-engine.h (sim_engine_abort): Add noreturn attribute.
1476         (sim_engine_vabort): Ditto.
1477         (sim_engine_halt, sim_engine_restart): Ditto.
1478
1479 2003-02-20  Andrew Cagney  <ac131313@redhat.com>
1480
1481         * Make-common.in (SIM_NEW_COMMON_OBJS): Remove sim-break.o
1482         (sim-break_h): Delete macro.
1483         (sim-break.o): Delete rule.
1484         * sim-break.c: Delete file.
1485         * sim-break.h: Delete file.
1486         * sim-base.h [SIM_HAVE_BREAKPOINTS]: Don't include "sim-break.h".
1487         (STATE_BREAKPOINTS): Delete macro.
1488         (sim_state_base): Delete field breakpoints.
1489         * sim-module.c (modules) [SIM_HAVE_BREAKPOINTS]: Don't add
1490         sim_break_install to array.
1491
1492 2003-01-08  Kazu Hirata  <kazu@cs.umass.edu>
1493
1494         * run.c (usage): Fix typos.
1495
1496 2002-11-27  Richard Sandiford  <rsandifo@redhat.com>
1497
1498         * sim-fpu.c (sim_fpu_inv): Use sim_fpu_div.
1499
1500 2002-11-22  Andrew Cagney  <ac131313@redhat.com>
1501
1502         * dv-core.c: Update copyright.  sim/common contributed to the FSF.
1503         * dv-glue.c, dv-pal.c, hw-base.c, hw-base.h, hw-device.c: Ditto.
1504         * hw-device.h, hw-handles.c, hw-handles.h: Ditto.
1505         * hw-instances.c, hw-instances.h, hw-properties.c: Ditto.
1506         * hw-properties.h, hw-tree.c, hw-tree.h, sim-alu.h: Ditto.
1507         * sim-basics.h, sim-bits.c, sim-bits.h, sim-config.c: Ditto.
1508         * sim-config.h, sim-core.c, sim-core.h, sim-endian.c: Ditto.
1509         * sim-endian.h, sim-events.c, sim-events.h, sim-inline.c: Ditto.
1510         * sim-inline.h, sim-io.c, sim-io.h, sim-n-bits.h: Ditto.
1511         * sim-n-core.h, sim-n-endian.h, sim-types.h: Ditto.
1512
1513 2002-11-13  Andrew Cagney  <cagney@redhat.com>
1514
1515         * run.c (main): Remove SIM_HAVE_ENVIRONMENT from #endif.
1516
1517 2002-11-06  Richard Sandiford  <rsandifo@redhat.com>
1518
1519         * Make-common.in (SIM_EXTRA_DISTCLEAN): New macro.
1520         (distclean): Depend on it.
1521
1522 2002-10-14  Alan Modra  <amodra@bigpond.net.au>
1523
1524         * cgen-trace.h: Test __BFD_H_SEEN__ rather than BFD_VERSION.
1525
1526 2002-08-29  Dave Brolley  <brolley@redhat.com>
1527
1528         * Make-common.in (CGEN_READ_SCM): Remove ../../cgen/stamp-cgen.
1529
1530 2002-07-17  Andrew Cagney  <cagney@redhat.com>
1531
1532         * run-sim.h: Add #ifdef RUN_SIM_H wrapper.
1533         (sim_set_callbacks, sim_size, sim_trace)
1534         (sim_set_trace, sim_set_profile_size, sim_kill): Declare.  Moved
1535         to here from "gdb/remote-sim.h".
1536
1537 2002-07-16  Andrew Cagney  <ac131313@redhat.com>
1538
1539         * sim-resume.c (sim_resume): Add local variable sig_to_deliver to
1540         avoid possible longjmp problems with automatic variable siggnal.
1541
1542 2002-07-14  Andrew Cagney  <ac131313@redhat.com>
1543
1544         From 2002-07-11 Momchil Velikov <velco@fadata.bg>:
1545         * Make-common.in (installdirs): Make $(libdir) too, needed when
1546         installing libsim.a.
1547
1548 2002-07-13  Andrew Cagney  <ac131313@redhat.com>
1549
1550         * gennltvals.sh (dir): Mark d30v as obsolete.
1551         * nltvals.def: Remove d30v.
1552
1553 2002-06-17  Andrew Cagney  <cagney@redhat.com>
1554
1555         * hw-events.c (hw_event_queue_schedule): Initialize `dummy'.
1556
1557         * sim-memopt.c: Include <unistd.h>.
1558         (do_memopt_add): Fix printf format.
1559         * sim-events.c (sim_events_schedule): Initialize ``dummy''.
1560
1561 2002-06-16  Andrew Cagney  <ac131313@redhat.com>
1562
1563         * aclocal.m4 (SIM_AC_OPTION_WARNINGS): Update to match GDB's
1564         --enable-gdb-build-warnings.
1565         * configure: Regenerated to track ../common/aclocal.m4 changes.
1566
1567 2002-06-09  Aldy Hernandez  <aldyh@redhat.com>
1568
1569         * sim-fpu.c (unpack_fpu): Initialize exponent for
1570         sim_fpu_class_zero.
1571         (i2fpu): Same.
1572         (sim_fpu_sqrt): Same.
1573
1574 2002-06-08  Andrew Cagney  <cagney@redhat.com>
1575
1576         * gentmap.c (gen_targ_map_c): Generate "gdb/callback.h".
1577         * sim-basics.h: Include "gdb/callback.h" and "gdb/remote-sim.h".
1578         * run.c: Ditto.
1579         * sim-load.c: Ditto.
1580         * callback.c: Ditto.
1581         * syscall.c: Ditto.
1582         * Make-common.in (callback_h): Define.
1583         (remote_sim_h): Define.
1584         (run.o): Update.
1585         (callback.o): Update.
1586         (syscall.o): Update.
1587         (sim-load.o): 
1588         (nrun.o): Update.
1589         (sim-hload.o): Update.
1590         (sim-io.o): Update.
1591         (sim-reason.o): Update.
1592         (sim-reg.o): Update.
1593         (sim-resume.o): Update.
1594
1595 2002-05-30  Kazu Hirata  <kazu@cs.umass.edu>
1596
1597         * run.c: Fix formatting.
1598
1599 2002-05-20  Nick Clifton  <nickc@cambridge.redhat.com>
1600
1601         * run-sim.h: New header.  Provide prototypes for functions used
1602         between run() and libsim.a which are not used by GDB.
1603         * run.c: Include run-sim.h.
1604         (main): If SIM_TARGET_SWITCHES is defined call
1605         sim_target_parse_command_line.
1606         (usage): If SIM_TARGET_SWITCHES is defined call
1607         sim_target_display_usage.
1608
1609 2002-05-17  Andrey Volkov  <avolkov@transas.com>
1610
1611         * run.c: Made h8300s as new target, not h8300h alias.
1612         Added new option -S (h8300s target)
1613         * sim-options.c: Ditto.
1614         
1615 2002-05-01  Chris Demetriou  <cgd@broadcom.com>
1616
1617         * callback.c: Use 'deprecated' rather than 'depreciated.'
1618
1619 2002-02-24  Andrew Cagney  <ac131313@redhat.com>
1620
1621         From wiz at danbala:
1622         * sim-fpu.h: Fix grammar and typos.
1623         Fix PR gdb/287.
1624
1625 2002-02-10  Chris Demetriou  <cgd@broadcom.com>
1626
1627         * callback.c: Fix some spelling errors.
1628         * hw-device.h: Likewise.
1629         * hw-tree.c: Likewise.
1630         * sim-abort.c: Likewise.
1631         * sim-alu.h: Likewise.
1632         * sim-core.h: Likewise.
1633         * sim-events.c: Likewise.
1634         * sim-events.h: Likewise.
1635         * sim-fpu.h: Likewise.
1636         * sim-profile.h: Likewise.
1637         * sim-utils.c: Likewise.
1638
1639 2002-01-31  Hans-Peter Nilsson  <hp@axis.com>
1640
1641         * cgen-ops.h (ADDCQI, ADDCFQI, ADDOFQI, SUBCQI, SUBCFQI, SUBOFQI):
1642         New functions.
1643
1644 2002-01-20  Ben Elliston  <bje@redhat.com>
1645
1646         * sim-fpu.h (SIM_FPU_IS_QNAN): Replace "Quite" with "Quiet" in
1647         the comment for this enumerator.
1648
1649 2002-01-14  Ben Elliston  <bje@redhat.com>
1650
1651         * sim-fpu.h: Fix comment about sim_fpu_* constants.
1652
1653 2001-12-20  Kazu Hirata  <kazu@hxi.com>
1654
1655         * run.c (usage): Fix a typo.
1656
1657 2001-07-05  Ben Elliston  <bje@redhat.com>
1658
1659         * Make-common.in (srccgen): Remove.
1660         (CGEN_CPU_DIR): Define.
1661         (CGEN_READ_SCM): Redefine without $(srccgen).
1662         (CGEN_ARCH_SCM): Ditto.
1663         (CGEN_CPU_SCM): Ditto.
1664         (CGEN_DECODE_SCM): Ditto.
1665         (CGEN_DESC_SCM): Ditto.
1666
1667 2001-04-25  Frank Ch. Eigler  <fche@redhat.com>
1668
1669         * sim-load.c (sim_load_file): Put it back: external now.
1670         * sim-utils.c (sim_analyze_program): Ditto.  Nyuk nyuk nyuk.
1671
1672 2001-04-21  Andrew Cagney  <ac131313@redhat.com>
1673
1674         * sim-load.c (sim_load_file): Delete call bfd_cache_close.  BFD
1675         internal interface.
1676         * sim-utils.c (sim_analyze_program): Ditto.
1677
1678 2001-04-19  Frank Ch. Eigler  <fche@redhat.com>
1679
1680         * sim-utils.c (sim_analyze_program): Call bfd_cache_close after
1681         we're finished with its immediate use.
1682         * sim-load.c (sim_load_file): Ditto.
1683
1684 2001-03-16  Frank Ch. Eigler  <fche@redhat.com>
1685
1686         Add support for mmap-based memory regions.
1687         * sim-memopt.c (mmap_next_fd): New global.
1688         (sim_memory_init): Reinitialize it.
1689         (OPTION_MEMORY_MAPFILE, memory_option_handler): Support new
1690         "--memory-mapfile FILE" option.  Check for some errors.
1691         (do_memopt_add): Conditionally do mmap instead of malloc for
1692         backing store of simulated memory.  Check for more errors.
1693         (do_simopt_delete, sim_memory_uninstall): Corresponding cleanup.
1694         * sim-memopt.h (munmap_length): New member of _sim_memopt.
1695         * configure.in: Look for mmap/fstat related functions and headers.
1696         * config.in, configure: Regenerated.
1697
1698 2001-03-15  Frank Ch. Eigler  <fche@redhat.com>
1699
1700         * sim-core.c (sim_core_map_attach): Correct overlap-related
1701         error messages.
1702
1703 2001-03-07  Michael Meissner  <meissner@redhat.com>
1704
1705         * run.c (alloca-conf.h): Delete, no longer provided.
1706
1707 2001-02-22  Ben Elliston  <bje@redhat.com>
1708
1709         * sim-trace.h (TRACE_VPU_IDX): Add.
1710         (TRACE_vpu): Define.
1711         (WITH_TRACE_VPU_P): Likewise.
1712         (TRACE_VPU_P): Likewise.
1713         * sim-trace.c (OPTION_TRACE_VPU): Define.
1714         (trace_options): Add --trace-vpu.
1715         (trace_option_handler): Handle OPTION_TRACE_VPU.
1716         (trace_option_handler): Include VPU tracing in --trace-semantics.
1717         (trace_idx_to_str): Handle TRACE_VPU_IDX.
1718
1719 2001-02-21  Ben Elliston  <bje@redhat.com>
1720
1721         * sim-trace.h (TRACE_BRANCH_INPUT1): New macro.
1722         (TRACE_BRANCH_INPUT2): Likewise.
1723
1724 2001-02-09  Ben Elliston  <bje@redhat.com>
1725
1726         * (profile_print_pc): Write header out in target byte order.
1727
1728 2001-02-09  Ben Elliston  <bje@redhat.com>
1729
1730         * sim-profile.c (profile_pc_init): Correct bug in loop logic when
1731         adjusting the pc shift value.
1732
1733 2001-01-12  Chris Demetriou  <cgd@sibyte.com>
1734
1735         * aclocal.m4 (SIM_AC_OPTION_SCACHE): Properly handle the case
1736         where a numeric value is supplied.
1737
1738 2001-01-06  Ben Elliston  <bje@redhat.com>
1739
1740         * cgen.sh: Allow extrafiles to include the semantics files when
1741         generating an ISA-specific decoder.
1742
1743 2000-12-27  Alexandre Oliva  <aoliva@redhat.com>
1744
1745         * Make-common.in (sim-io.o): Depend on targ-vals.h.
1746
1747 2000-12-23  Ben Elliston  <bje@redhat.com>
1748
1749         * cgen-trace.c (trace_result): Handle 'f' type operands; output
1750         them to the trace stream using sim_fpu_printn_fpu. Include
1751         "sim-fpu.h".
1752
1753 2000-12-15  Ben Elliston  <bje@redhat.com>
1754
1755         * sim-fpu.h (sim_fpu_printn_fpu): Declare.
1756         * sim-fpu.c (print_bits): Add digits parameter. Print only as many
1757         trailing digits as specified (-1 to print all digits).
1758         (sim_fpu_print_fpu): New wrapper around sim_fpu_printn_fpu.
1759         (sim_fpu_printn_fpu): Rename from sim_fpu_print_fpu; update calls
1760         to print_bits ().
1761
1762 2000-12-13  Ben Elliston  <bje@redhat.com>
1763
1764         * cgen.sh: Set prefix/PREFIX (append ISA if applicable). Factor
1765         sed expressions into $sedscript, substituting @prefix@/@PREFIX@.
1766         (defs): New action.
1767
1768 2000-12-12  Geoffrey Keating  <geoffk@redhat.com>
1769
1770         * sim-endian.h: Don't have parameters on macro definitions which
1771         are simply renaming functions, to permit use of XCONCAT2 in both
1772         the macro name and the arguments in a use of such a definition.
1773
1774 2000-12-11  Ben Elliston  <bje@redhat.com>
1775
1776         * cgen-ops.h (SUBWORDDFDI): New function.
1777
1778 2000-12-05  Ben Elliston  <bje@redhat.com>
1779
1780         * Make-common.in (cgen-defs): New target.
1781         (cgen-decode): Pass $(EXTRAFILES).
1782
1783         * genmloop.sh: Use @prefix@, not @cpu@ throughout. Add -prefix and
1784         -outfile-suffix options.
1785
1786 2000-12-04  Ben Elliston  <bje@redhat.com>
1787
1788         * cgen-ops.h (SUBWORDSIQI): Mask off top bits.
1789         (SUBWORDSIUQI): Likewise.
1790         (SUBWORDDIHI): Likewise.
1791         (SUBWORDDIQI): New function.
1792
1793         * cgen-trace.c (disassemble_insn): Remove unused declaration.
1794         * cgen-scache.c (scache_option_handler): Remove unused local var.
1795
1796 2000-12-03  Ben Elliston  <bje@redhat.com>
1797
1798         * sim-profile.c (profile_option_handler): Remove unused prof_nr.
1799
1800 2000-11-26  Stephane Carrez  <Stephane.Carrez@worldnet.fr>
1801
1802         * hw-events.c (delete_hw_event_data): Remove the scheduled events.
1803
1804 2000-11-26  Stephane Carrez  <Stephane.Carrez@worldnet.fr>
1805
1806         * dv-core.c (dv_core_attach_address_callback): Don't abort if
1807         space is not zero.
1808
1809 2000-11-24  Stephane Carrez  <Stephane.Carrez@worldnet.fr>
1810
1811         * hw-base.c (hw_delete): Don't free base_of_hw since it's freed.
1812         (set_hw_delete): Moved the macro as a function.
1813         * hw-base.h (set_hw_delete): Declare as external function.
1814         * hw-alloc.c (delete_hw_alloc_data): Allow to free the memory
1815         allocated using hw_malloc.
1816         
1817 2000-11-24  Stephane Carrez  <Stephane.Carrez@worldnet.fr>
1818
1819         * sim-options.c (sim_parse_args): Free the memory used for
1820         long_options, short_options, handlers, opt_cpu, orig_val.
1821
1822 2000-11-20  Ben Elliston  <bje@redhat.com>
1823
1824         * cgen-ops.h (SUBBI): New macro.
1825         (SUBWORDSIQI, SUBWORDSIHI, SUBWORDSIUQI): New functions.
1826         (SUBWORDDIHI, SUBWORDDIUQI, SUBWORDDIDF): Likewise.
1827
1828 2000-11-16  Ben Elliston  <bje@redhat.com>
1829
1830         * cgen-types.h (VOID): New type.
1831
1832 2000-11-09  Ben Elliston  <bje@redhat.com>
1833
1834         * sim-fpu.c (sim_fpu_one): Set exponent to 0.
1835         (sim_fpu_two): Set exponent to 1.
1836
1837 2000-10-26  Ben Elliston  <bje@redhat.com>
1838
1839         * cgen.sh: Handle an isa argument between cpu and mach. Default to
1840         `all'. Pass `-i' options to cgen applications.
1841         * Make-common.in (cgen-arch, cgen-cpu, cgen-decode, cgen-cpu-decode,
1842         cgen-desc): Pass $(isa) to cgen.sh.
1843
1844 2000-10-08  Ben Elliston  <bje@redhat.com>
1845
1846         * cgen-utils.c (cgen_rtx_error): New function.
1847
1848 2000-10-07  Ben Elliston  <bje@redhat.com>
1849
1850         * cgen-trace.c (sim_cgen_disassemble_insn): Handle failure
1851         conditions for sim_core_read_buffer().
1852
1853 2000-09-26  Dave Brolley  <brolley@redhat.com>
1854
1855         * cgen-utils.c (RORQI): New function.
1856         (ROLQI): New function.
1857         (RORHI): New function.
1858         (ROLHI): New function.
1859
1860 2000-08-28  Dave Brolley  <brolley@redhat.com>
1861
1862         * cgen-trace.c (sim_cgen_disassemble_insn): Make sure entire insn is
1863         in insn_value if it will fit.
1864
1865 2000-08-21  Frank Ch. Eigler  <fche@redhat.com>
1866
1867         * Make-common.in, cgen.sh: Contribute CGEN-related build targets/rules.
1868
1869 2000-08-15  Dave Brolley  <brolley@redhat.com>
1870
1871         * sim-profile.c (profile_print_speed): Print cpu frequency if not zero.
1872
1873 2000-08-15  Dave Brolley  <brolley@redhat.com>
1874
1875         * sim-profile.h (PROFILE_DATA): Add cpu_freq.
1876         (PROFILE_CPU_FREQ): New macro.
1877         * sim-profile.c (OPTION_PROFILE_CPU_FREQUENCY): New enumerator.
1878         (profile-options): Add profile-cpu-frequency.
1879         (parse_frequency): New function.
1880         (profile_option_handler): Handle OPTION_PROFILE_CPU_FREQUENCY.
1881         (profile_print_speed): Print cpu frequency and simulated execution time.
1882         Re-indent other items to match.
1883
1884 2000-08-09  Andrew Cagney  <cagney@lulu.cygnus.com>
1885
1886         * dv-sockser.c (dv_sockser_init): Eliminate MIN macro.
1887
1888 2000-07-27  Frank Ch. Eigler  <fche@redhat.com>
1889
1890         From Maciej W. Rozycki <macro@ds2.pg.gda.pl>
1891         * Makefile.in (install): Install run.1 man page.
1892
1893 Thu Jul 27 21:56:08 2000  Andrew Cagney  <cagney@b1.cygnus.com>
1894
1895         From 2000-06-23 Doug Evans <dje@casey.transmeta.com>:
1896         * Makefile.in (headers,nltvals.def): Merge.
1897
1898 Thu Jul 27 20:37:47 2000  Andrew Cagney  <cagney@b1.cygnus.com>
1899
1900         From 2000-06-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>:
1901         * nrun.c (main): Print the simulator statistics only in
1902         verbose mode.
1903         * hw-properties.h (hw_find_integer_array_property): Fix
1904         prototype (use signed_cell).
1905
1906         From 2000-06-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>:
1907         * sim-events.c (sim_events_remain_time): New function returning
1908         the time that remains before the event is raised.
1909         * hw-events.c (hw_event_remain_time): Likewise.
1910         * sim-events.h (sim_events_remain_time): Declare.
1911         * hw-events.h (hw_event_remain_time): Declare.
1912
1913         From 2000-06-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>:
1914         * sim-hw.c: Use <errno.h> instead of <sys/errno.h>
1915         (OPTION_HW_LIST): New option --hw-list to list the devices.
1916         (hw_option_handler): List the device tree with 'sim_hw_print'.
1917
1918         From 2000-06-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>:
1919         * sim-bits.h (_MSB_16, _LSB_16): Define for 16-bit targets.
1920         (MASK, LSBIT, MSBIT): Likewise and use _MSB_16 and _LSB_16.
1921         (EXTENDED): Define for 16-bit word size.
1922         * sim-bits.c (LSEXTRACTED, MSEXTRACTED, LSINSERTED,
1923         MSINSERTED, LSSEXT, MSSEXT): Implement for 16-bit word size.
1924         * sim-types.h: Added support for 16-bit targets.
1925
1926 2000-06-23  Frank Ch. Eigler  <fche@redhat.com>
1927
1928         * cgen-trace.h (TRACE_USEFUL_MASK): Remove TRACE_EVENTS_IDX.
1929
1930 2000-06-24  Frank Ch. Eigler  <fche@redhat.com>
1931
1932         From Maciej W. Rozycki <macro@ds2.pg.gda.pl>:
1933         * Makefile.in (distclean): Clean cconfig.h also.
1934
1935 Tue May 23 21:39:23 2000  Andrew Cagney  <cagney@b1.cygnus.com>
1936
1937         * configure: Regenerated to track ../common/aclocal.m4 changes.
1938
1939 Tue May 23 21:35:53 2000  Andrew Cagney  <cagney@b1.cygnus.com>
1940
1941         * aclocal.m4 (sim-profile): Enable the profiler by default.
1942
1943 Tue May 23 20:30:12 2000  Andrew Cagney  <cagney@amy.cygnus.com>
1944
1945         * run.c (main): Initialize sigrc.
1946
1947 Wed Apr 26 16:18:44 2000  Andrew Cagney  <cagney@b1.cygnus.com>
1948
1949         * sim-events.c (update_time_from_event): Add more detailed event
1950         tracing.
1951
1952 2000-03-30  Dave Brolley  <brolley@redhat.com>
1953
1954         * aclocal.m4 (cgen): Use guile to run cgen.
1955
1956 2000-03-23  Dave Brolley  <brolley@redhat.com>
1957
1958         * cgen-fpu.h: Rename extsfdf to fextsfdf. Rename truncdfsf to
1959         ftruncdfsf.
1960         * cgen-accfp.c (fextsfdf): New function.
1961         (ftruncdfsf): New function.
1962         (cgen_init_accurate_fpu): Initialize fextsfdf and ftruncdfsf.
1963
1964 2000-03-13  Jeff Johnston <jjohnstn@cygnus.com>
1965
1966         * cgen-ops.h: Added TRUNCSISI.
1967
1968 2000-03-08  Dave Brolley  <brolley@redhat.com>
1969
1970         * cgen-par.h (cgen_write_queue_kind): Add CGEN_FN_SF_WRITE.
1971         (CGEN_WRITE_QUEUE_ELEMENT): Add fn_sf_write.
1972         (sim_queue_fn_si_write): Last argument is has type USI.
1973         (sim_queue_fn_sf_write): New function.
1974         * cgen-par.c (sim_queue_fn_si_write): Declare 'value' as USI.
1975         (sim_queue_fn_sf_write): New function.
1976         (cgen_write_queue_element_execute): Handle CGEN_FN_SF_WRITE.
1977
1978 Tue Feb 22 16:45:09 2000  Andrew Cagney  <cagney@b1.cygnus.com>
1979
1980         * run.c (main): When SIM_HAVE_ENVIRONMENT enable tracing with
1981         sim_set_trace and run simulator using sim_resume.
1982         (main): Add option ``-o'' - operating environment.  Only continue
1983         after a signal when operating environment.
1984         (main): Always set REASON and SIGRC using sim_stop_reason.
1985         (sim_trace): Delete extern declaration.
1986
1987 2000-02-08  Nick Clifton  <nickc@cygnus.com>
1988
1989         * callback.c: Fix compile time warning messages.
1990         * run.c: Fix compile time warning messages.
1991      
1992 1999-12-17  Dave Brolley  <brolley@cygnus.com>
1993
1994         * sim-profile.h: (set_profile_option_mask): Add prototype.
1995         * sim-profile.c (set_profile_option_mask): No longer static.
1996
1997 Wed Dec  8 21:47:13 1999  Andrew Cagney  <cagney@b1.cygnus.com>
1998
1999         * sim-arange.c: Include <string.h>
2000
2001 1999-12-07  Dave Brolley  <brolley@cygnus.com>
2002
2003         * sim-options.c (print_help): '=' required before optional argument.
2004         * cgen-par.h (CGEN_FN_MEM_QI_WRITE): New enumerator.
2005         (CGEN_FN_MEM_HI_WRITE): New enumerator.
2006         (CGEN_FN_MEM_SI_WRITE): New enumerator.
2007         (CGEN_FN_MEM_DI_WRITE): New enumerator.
2008         (CGEN_FN_MEM_DF_WRITE): New enumerator.
2009         (CGEN_FN_MEM_XI_WRITE): New enumerator.
2010         (fn_mem_qi_write): New union members.
2011         (fn_mem_hi_write): New union members.
2012         (fn_mem_si_write): New union members.
2013         (fn_mem_di_write): New union members.
2014         (fn_mem_df_write): New union members.
2015         (fn_mem_xi_write): New union members.
2016         (sim_queue_fn_mem_qi_write): New function.
2017         (sim_queue_fn_mem_hi_write): New function.
2018         (sim_queue_fn_mem_si_write): New function.
2019         (sim_queue_fn_mem_di_write): New function.
2020         (sim_queue_fn_mem_df_write): New function.
2021         (sim_queue_fn_mem_xi_write): New function.
2022         * cgen-par.c (sim_queue_fn_mem_qi_write): New function.
2023         (sim_queue_fn_mem_hi_write): New function.
2024         (sim_queue_fn_mem_si_write): New function.
2025         (sim_queue_fn_mem_di_write): New function.
2026         (sim_queue_fn_mem_df_write): New function.
2027         (sim_queue_fn_mem_xi_write): New function.
2028         (cgen_write_queue_element_execute): Handle CGEN_FN_MEM_QI_WRITE,
2029         CGEN_FN_MEM_HI_WRITE, CGEN_FN_MEM_SI_WRITE, CGEN_FN_MEM_DI_WRITE,
2030         CGEN_FN_MEM_DF_WRITE, CGEN_FN_MEM_XI_WRITE.
2031
2032 1999-12-01  Dave Brolley  <brolley@cygnus.com>
2033
2034         * cgen-accfp.c (subsf): Check status code.
2035         (mulsf): Ditto.
2036         (negsf): Ditto.
2037         (abssf): Ditto.
2038         (sqrtsf): Ditto.
2039         (invsf): Ditto.
2040         (minsf): Ditto.
2041         (maxsf): Ditto.
2042         (subdf): Ditto.
2043         (muldf): Ditto.
2044         (divdf): Ditto.
2045         (negdf): Ditto.
2046         (absdf): Ditto.
2047         (sqrtdf): Ditto.
2048         (invdf): Ditto.
2049         (mindf): Ditto.
2050         (maxdf): Ditto.
2051
2052 1999-11-26  Dave Brolley  <brolley@cygnus.com>
2053
2054         * cgen-par.h (fn_df_write): Mode of data is DF.
2055         (sim_queue_fn_df_write): Mode of data is DF.
2056         * cgen-par.c (sim_queue_fn_df_write): Mode of data is DF.
2057
2058 1999-11-22  Dave Brolley  <brolley@cygnus.com>
2059
2060         * cgen-trace.c (SIZE_TRACE_BUF): Inxrease size of trace buffer.
2061         * cgen-par.h (CGEN_WRITE_QUEUE_SIZE): Increase size of queue.
2062
2063 1999-11-04  Dave Brolley  <brolley@cygnus.com>
2064
2065         * cgen-par.h (cgen_write_queue_kind): Add CGEN_FN_XI_WRITE and
2066         CGEN_MEM_XI_WRITE members.
2067         (CGEN_WRITE_QUEUE_ELEMENT): Add fn_xi_write and mem_xi_write members.
2068         (sim_queue_fn_xi_write): New function.
2069         (sim_queue_mem_xi_write): New function.
2070
2071         * cgen-par.c (sim_queue_fn_xi_write): New function.
2072         (sim_queue_mem_xi_write): New function.
2073         (cgen_write_queue_element_execute): Handle CGEN_FN_XI_WRITE and
2074         CGEN_MEM_XI_WRITE.
2075
2076 1999-10-22  Dave Brolley  <brolley@cygnus.com>
2077
2078         * cgen-par.h (insn_address): New field in CGEN_WRITE_QUEUE_ELEMENT.
2079         (CGEN_WRITE_QUEUE_ELEMENT_IADDR): New macro.
2080         * cgen-par.c: Set insn_address for each queued write. Get pc from
2081         cpu when executing queued writes.
2082
2083 1999-10-19  Dave Brolley  <brolley@cygnus.com>
2084
2085         * cgen-par.h (sim_queue_fn_pc_write): New function.
2086         (CGEN_FN_PC_WRITE): New enumerator.
2087         (fn_pc_write): New union member.
2088         * cgen-par.c (sim_queue_fn_pc_write): New function.
2089         (cgen_write_queue_element_execute): Handle CGEN_FN_PC_WRITE.
2090
2091 1999-10-18  Dave Brolley  <brolley@cygnus.com>
2092
2093         * cgen-par.h (CGEN_MEM_DI_WRITE): New enumerator.
2094         (CGEN_MEM_DF_WRITE): New enumerator.
2095         (mem_di_write): New union member.
2096         (mem_df_write): New union member.
2097         * cgen-par.c (sim_queue_mem_di_write): New function.
2098         (sim_queue_mem_df_write): New function.
2099         (cgen_write_queue_element_execute): Handle CGEN_MEM_DI_WRITE and
2100         CGEN_MEM_DF_WRITE.
2101         * cgen-accfp.c (divsf): Check for division errors.
2102
2103 1999-10-14  Doug Evans  <devans@casey.cygnus.com>
2104
2105         * cgen-engine.h (EXTRACT_INT,EXTRACT_UINT): Delete.
2106
2107 1999-10-07  Dave Brolley  <brolley@cygnus.com>
2108
2109         * cgen-par.h (CGEN_FN_HI_WRITE): New enumerator. 
2110         (fn_hi_write): New union member.
2111         (sim_queue_fn_hi_write): New function.
2112         * cgen-par.c (sim_queue_fn_hi_write): New function.
2113         (cgen_write_queue_element_execute): Handle CGEN_FN_HI_WRITE.
2114
2115 1999-09-29  Doug Evans  <devans@casey.cygnus.com>
2116
2117         * cgen-defs.h (sim_engine_invalid_insn): New arg `vpc'.
2118         Change type of result to SEM_PC.
2119
2120 Wed Sep 29 14:43:57 1999  Dave Brolley  <brolley@cygnus.com>
2121
2122         * cgen-defs.h (sim_engine_invalid_insn): Now returns PC.
2123
2124 1999-09-25  Doug Evans  <devans@casey.cygnus.com>
2125
2126         * cgen-ops.h (SUBWORD*): Delete cpu arg.
2127         (JOIN*): Delete cpu arg.
2128
2129 Tue Sep 21 17:14:16 1999  Dave Brolley  <brolley@cygnus.com>
2130
2131         * genmloop.sh (@cpu@_scache_lookup): No longer takes last_insn_p
2132         parameter.
2133         (SET_LAST_INSN_P): Set last_insn_p flag in the scache element.
2134
2135 Mon Sep 20 21:44:06 1999  Geoffrey Keating  <geoffk@cygnus.com>
2136
2137         * sim-fpu.c (i2fpu): Keep the guard bits sticky when converting
2138         large values.
2139
2140 Tue Feb  8 16:33:48 2000  Andrew Cagney  <cagney@b1.cygnus.com>
2141
2142         * run.c (main): Check the sim_stop_reason and only halt simulation
2143         when a valid stop condition is identified.
2144
2145 Wed Sep 15 14:12:37 1999  Andrew Cagney  <cagney@b1.cygnus.com>
2146
2147         * hw-tree.c, hw-properties.c, hw-instances.c: Include "sim-io.h".
2148
2149 Tue Sep 14 14:15:47 1999  Dave Brolley  <brolley@cygnus.com>
2150
2151         * cgen-par.h (CGEN_BI_WRITE): New enumerator.
2152         (bi_write): New union element.
2153         (sim_queue_bi_write): New function.
2154         * cgen-par.c (sim_queue_bi_write): New function.
2155         (cgen_write_queue_element_execute): Handle CGEN_BI_WRITE.
2156
2157 Thu Sep  2 18:15:53 1999  Andrew Cagney  <cagney@b1.cygnus.com>
2158
2159         * configure: Regenerated to track ../common/aclocal.m4 changes.
2160
2161         * aclocal.m4 (WERROR_CFLAGS, WARN_CFLAGS): Merge from
2162         ../gdb/configure.in.
2163         * Make-common.in (WERROR_CFLAGS, WARN_CFLAGS): Define.
2164         (SIM_WERROR_CFLAGS, SIM_WARN_CFLAGS): Define.
2165         (SIM_WARNINGS): Delete
2166         (CONFIG_CFLAGS): Update.
2167
2168 Tue Aug 31 16:01:42 1999  Dave Brolley  <brolley@cygnus.com>
2169
2170         * cgen-par.c: New file.
2171         * cgen-par.h: New file.
2172         * cgen-sim.h (cgen-par.h): #include it.
2173         * cgen-cpu.h (write_queue): New field.
2174         (CPU_WRITE_QUEUE): New access macro.
2175         * Make-common.in (CGEN_MAIN_CPU_DEPS): Add cgen-par.h.
2176         (cgen-par.o): New target.
2177
2178 1999-08-28  Doug Evans  <devans@casey.cygnus.com>
2179
2180         * cgen-types.h (mode_type,MODE_VOID): Renamed from MODE_VM.
2181         * cgen-utils.c (mode_names): Update.
2182
2183 1999-08-20  Doug Evans  <devans@casey.cygnus.com>
2184
2185         * genmloop.sh: New args -parallel-generic-write, -parallel-only.
2186         * cgen-engine.h (SEMANTIC_FN): Don't use version with PAREXEC
2187         buffer arg if WITH_PARALLEL_GENWRITE.
2188         (struct insn_sem): Handle WITH_PARALLEL_GENWRITE.
2189         (struct idesc): Ditto.
2190
2191 Wed Aug 18 18:17:28 1999  Doug Evans  <devans@canuck.cygnus.com>
2192
2193         * sim-model.c (model_option_handler): Add \n to error message.
2194
2195 1999-08-08  Doug Evans  <devans@casey.cygnus.com>
2196
2197         * cgen-engine.h (SEM_FN_NAME,SEMF_FN_NAME): Delete.
2198         (insn_sem): Rewrite.
2199         (sem_fn_desc): New struct.
2200         (idesc): Rewrite.
2201         * genmloop.sh (scache case,@cpu@_scache_lookup): Profile scache hit,
2202         misses if ! FAST_P.
2203         (scache case): Split into non-parallel/parallel versions.
2204         (@cpu@_engine_run_{full,fast}): Call @cpu@_{sem,semf}_init_idesc_table
2205         if not use semantic switch version.
2206
2207 1999-08-04  Doug Evans  <devans@casey.cygnus.com>
2208
2209         * cgen-defs.h (SEM_BRANCH_TYPE): New enum.
2210         * cgen-engine.h (SEM_BRANCH_UNTAKEN,SEM_BRANCH_UNCACHEABLE): Delete.
2211         (SEM_BRANCH_INIT_EXTRACT): Delete.
2212         (SEM_BRANCH_INIT): Replace npc_ptr with br_type.
2213         (SEM_BRANCH_FINI): Ditto.
2214         (SEM_BRANCH_VIA_ADDR): Ditto.
2215         (SEM_BRANCH_VIA_CACHE): Ditto.  Delete cachvarptr arg.
2216         (SEM_BRANCH_ADDR_CACHE): Delete.
2217         (SEM_SKIP_COMPILE,SEM_SKIP_INSN): New macros.
2218         * cgen-scache.h (cpu_scache): Replace member pbb_pr_npc_ptr with
2219         pbb_br_type.
2220         * genmloop.sh (eng.hin): Update prototype of ${cpu}_pbb_cti_chain.
2221         (@cpu@_pbb_begin): Initialize branch_target.
2222         (@cpu@_pbb_cti_chain): Replace arg new_vpc_ptr with br_type.
2223         (@cpu@_engine_run_full): Replace local pbb_br_npc_ptr with
2224         pbb_br_type.
2225         (@cpu@_engine_run_fast): Ditto.
2226
2227 Fri Jul 16 14:47:53 1999  Dave Brolley  <brolley@cygnus.com>
2228
2229         * cgen-utils.c (RORSI): New function.
2230         (ROLSI): New function.
2231
2232 1999-07-14  Doug Evans  <devans@casey.cygnus.com>
2233
2234         * Makefile.in (TAGS): Tweak TAGS regex.
2235         * cgen-mem.h (*): Add TAGS markers.
2236
2237 Sun Jul 11 23:47:20 1999  Andrew Cagney  <cagney@b1.cygnus.com>
2238
2239         * sim-resume.c (sim_resume): Ensure that the siggnal [sic] is only
2240         passed in when sim_resume is first entered - don't re-pass it
2241         after a restart.
2242         
2243 Sun Jul 11 23:34:44 1999  Andrew Cagney  <cagney@b1.cygnus.com>
2244
2245         * sim-options.c (standard_option_handler): Add OPTION_LOAD_VMA and
2246         OPTION_LOAD_LMA but only when is defined.
2247         (standard_options): When SIM_HANDLES_LMA is defined include
2248         options --load-lma and --load-vma.
2249         (standard_install): Initialize STATE_LOAD_AT_LMA_P.
2250
2251         * sim-base.h (STATE_LOAD_AT_LMA_P): Define.
2252         (struct sim_state_base): Add load_at_lma_p.
2253         * sim-hload.c (sim_load): Replace SIM_HANDLES_LMA with
2254         STATE_LOAD_AT_LMA_P.
2255
2256 Sun Jul 11 12:03:36 1999  Andrew Cagney  <cagney@b1.cygnus.com>
2257
2258         * nrun.c (main): Re-format loop gnu style.
2259
2260 Wed Jul  7 19:56:03 1999  Andrew Cagney  <cagney@b1.cygnus.com>
2261
2262         * dv-sockser.c (connected_p): Initialize addrlen.
2263
2264 1999-07-06  Dave Brolley  <brolley@cygnus.com>
2265
2266         * cgen-accfp.c (floatsidf): New function.
2267         (fixdfsi): New function.
2268
2269 1999-07-06  Doug Evans  <devans@casey.cygnus.com>
2270
2271         * sim-model.c (sim_model_init): Issue error if machine is unsupported.
2272
2273 1999-07-05  Doug Evans  <devans@casey.cygnus.com>
2274
2275         * Make-common.in (CGEN_MAIN_CPU_DEPS): Add cgen-fpu.h.
2276         (cgen-fpu.o,cgen-accfp.o): Add rules for.
2277         * cgen-fpu.c: New file.
2278         * cgen-fpu.h: New file.
2279         * cgen-accfp.c: New file.
2280         * cgen-cpu.h (CGEN_CPU): New member fpu.
2281         * cgen-mem.h: Redo fp support.
2282         * cgen-ops.h: Delete k&r support.  Redo fp support.
2283         * cgen-sim.h: Include cgen-fpu.h.
2284         * cgen-types.h (SF,DF,XF,TF): Moved to cgen-fpu.h.
2285
2286 1999-06-23  Doug Evans  <devans@casey.cygnus.com>
2287
2288         * cgen-engine.h (TARGET_SEM_BRANCH_FINI): Remove cruft at end of
2289         ifndef.
2290         * genmloop.sh (@cpu@_scache_lookup): Delete unused local var.
2291         (@cpu@_pbb_cti_chain): Minor clean up.
2292
2293 1999-05-08  Felix Lee  <flee@cygnus.com>
2294
2295         * aclocal.m4: Use AC_EXEEXT instead of AM_EXEEXT.  Delete defn of
2296         AM_CYGWIN32 and AM_EXEEXT.
2297         * configure: Regenerate.
2298         
2299 Fri Apr 16 16:43:22 1999  Doug Evans  <devans@charmed.cygnus.com>
2300
2301         * sim-core.c (device_error,device_io_read_buffer,
2302         device_io_write_buffer): Delete decls.
2303         * sim-core.h: Put them here.
2304
2305         * sim-core.c (sim_core_read_buffer): Pass sd to device_io_read_buffer.
2306         (sim_core_write_buffer): Pass sd to device_io_write_buffer.
2307         * sim-n-core.h (sim_core_read_aligned_N): Ditto.
2308         (sim_core_write_aligned_N): Ditto.
2309
2310 1999-04-14  Stephane Carrez  <stcarrez@worldnet.fr>
2311
2312         * sim-memopt.c (sim_memory_uninstall): Don't look into
2313         free()d memory.
2314
2315 1999-04-14  Doug Evans  <devans@casey.cygnus.com>
2316
2317         * cgen-utils.scm (virtual_insn_entries): Update attribute definition.
2318
2319 1999-04-13  Doug Evans  <devans@casey.cygnus.com>
2320
2321         * sim-core.c (sim_core_read_buffer): Handle NULL cpu when WITH_DEVICES.
2322         (sim_core_write_buffer): Ditto.
2323
2324 1999-04-02  Keith Seitz  <keiths@cygnus.com>
2325
2326         * sim-io.c (sim_io_poll_quit): Only call the poll_quit callback
2327         after the interval counter has expired.
2328         (POLL_QUIT_INTERVAL): Define. Used to tweak the frequency of
2329         poll_quit callbacks. May be overridden by Makefile.
2330         (poll_quit_counter): New global.
2331         * sim-events.c: Remove all mentions of ui_loop_hook. The
2332         host callback "poll_quit" will serve the purpose.
2333         * run.c: Add definition of ui_loop_hook when NEED_UI_LOOP_HOOK
2334         is defined.
2335         * nrun.c: Remove declaration of ui_loop_hook.
2336
2337 Wed Mar 31 18:55:41 1999  Doug Evans  <devans@canuck.cygnus.com>
2338
2339         * cgen-run.c (sim_resume): Don't tell main loop to run "forever"
2340         if being used by gdb.
2341
2342 1999-03-22  Doug Evans  <devans@casey.cygnus.com>
2343
2344         * cgen-types.h (XF,TF): Tweak.
2345         * cgen-ops.h: Redo inline support.  Delete DI_FN_SUPPORT,
2346         in cgen-types.h.
2347         (SUBWORD*,JOIN*): Define.
2348         * cgen-trace.c (sim_cgen_disassemble_insn): Update, base_insn_bitsize
2349         moved into cpu descriptor.
2350         * sim-model.h (MACH): New member `num'.
2351
2352 1999-02-09  Doug Evans  <devans@casey.cygnus.com>
2353
2354         * cgen-cpu.h (CGEN_DISASSEMBLER): New type.
2355         (CGEN_CPU): Member opcode renamed to cpu_desc.
2356         New members get_idata,disassembler.
2357         * cgen-defs.h (CGEN_INSN_VIRTUAL_P): CGEN_INSN_ATTR renamed to
2358         CGEN_INSN_ATTR_VALUE.
2359         (CGEN_STATE): Delete member opcode_table.
2360         (sim_disassemble_insn): Delete decl.
2361         * cgen-engine.h (struct insn_sem): Moved to here from <cpu>-decode.c.
2362         (struct idesc): Moved to here from <cpu>-decode.h.
2363         * cgen-run.c (prime_cpu): Call prepare_run callback.
2364         * cgen-trace.h (SFILE): New type.
2365         (sim_disasm_sprintf): Declare.
2366         (sim_disasm_read_memory,sim_disasm_perror_memory): Declare.
2367         (sim_cgen_disassemble_insn): Declare.
2368         * cgen-trace.c: Include errno.h,dis-asm.h.  Don't include cpu-opc.h.
2369         (insn_fields): Delete.
2370         (trace_insn_fini): STATE_OPCODE_TABLE (sd) replaced with
2371         CPU_CPU_DESC (cpu).
2372         (trace_insn): Call CPU_DISASSEMBLER hook.
2373         (sim_disasm_sprintf): New function.
2374         (sim_disasm_read_memory): New function.
2375         (sim_disasm_perror_memory): New function.
2376         (sim_cgen_disassemble_insn): New function.
2377         * cgen-utils.c: Don't include cpu-opc.h.
2378         (virtual_insn_entries): New static local.
2379         (cgen_virtual_insn_table): Renamed from cgen_virtual_opcode_table.
2380         (cgen_insn_name): Rewrite.
2381         (disasm_sprintf,sim_disassemble_insn): Moved to cgen-trace.c.
2382         * cgen.sh (desc): New file generator handler.
2383         * genmloop.sh: -parallel changed to -parallel-read/-parallel-write.
2384         Define WITH_PARALLEL_READ/WITH_PARALLEL_WRITE appropriately.
2385         Don't include cpu-opc.h,cpu-sim.h.
2386         * sim-model.c (model_set): Delete SIM_DESC arg.
2387         (sim_model_set): Update.
2388         * sim-model.h (MACH): New member prepare_run.
2389
2390 1999-01-28  Frank Ch. Eigler  <fche@cygnus.com>
2391
2392         * sim-memopt.c (memory_option_handler): Avoid memset() calls
2393         if redundant with allocator functions.
2394
2395 Wed Jan 27 17:19:09 1999  Doug Evans  <devans@canuck.cygnus.com>
2396
2397         * cgen-engine.h (EXTRACT_LSB0_{INT,UINT}): Fix.
2398
2399         * sim-profile.h: Make like sim-trace.h.
2400         (PROFILE_USEFUL_MASK): New macro.
2401         * sim-profile.c (profile_options): Make like trace_options, allow
2402         optional on|off arg where applicable.
2403         (set_profile_option_mask): New function.
2404         (sim_profile_set_option): New function.
2405         (profile_option_handler): Simplify.
2406         Have -p only enable selected things, not everything.
2407         Add missing break to OPTION_PROFILE_PC_RANGE.
2408         * cgen-scache.c (scache_options): Allow optional on|off arg to
2409         --profile-scache.
2410         (scache_option_handler): Use sim_profile_set_option.
2411
2412 1999-01-26  Frank Ch. Eigler  <fche@cygnus.com>
2413
2414         * sim-memopt.c (memory_options): Add MEMORY_FILL option.
2415         (memory_option_handler): Implement MEMORY_FILL option.  Make
2416         MEMORY_CLEAR an alias for MEMORY_FILL=0.
2417         (parse_ulong_value): New function.
2418         (do_memopt_add): Allocate all buffers.  Optionally fill them.
2419
2420 1999-01-15  Richard Henderson  <rth@cygnus.com>
2421
2422         * hw-events.c (hw_event_queue_schedule): _vtracef takes a
2423         va_list, not an integer.
2424         * sim-events.c (sim_events_schedule): Likewise.
2425
2426         * sim-types.h (UNSIGNED32, UNSIGNED64): Properly cast to 
2427         the appropriate type.
2428
2429 1999-01-14  Doug Evans  <devans@casey.cygnus.com>
2430
2431         * cgen-defs.h (PCADDR,CIA): Define in terms of IADDR.
2432         (sim_disassemble_insn): Update prototype.
2433         (sim_engine_invalid_insn): Ditto.
2434         * cgen-engine.h (SEMANTIC_FN): Add !WITH_SCACHE version.
2435         (SEM_BRANCH_INIT): PCADDR->IADDR.
2436         (SEM_NBRANCH_FINI): New macro for !WITH_SCACHE case.
2437         * cgen-scache.c (scache_lookup,scache_lookup_or_alloc): PCADDR->IADDR.
2438         * cgen-scache.h (*): Ditto.
2439         * cgen-trace.c (*): Ditto.
2440         * cgen-trace.h (*): Ditto.
2441         * cgen-utils.c (*): Ditto.
2442         * cgen-types.h (integer modes): Use signedNN/unsignedNN types.
2443         (insn_t): Delete.
2444         * genmloop.sh (@cpu@_fill_argbuf): Add !WITH_SCACHE support.
2445         (simple engine framework): Rewrite.
2446         * sim-module.c (modules): Install model module sooner (and in
2447         particular before the profile module).
2448
2449 1999-01-12  Doug Evans  <devans@casey.cygnus.com>
2450
2451         * sim-model.h (sim_mach_lookup_bfd_name): Add prototype.
2452         * sim-model.c (sim_mach_lookup_bfd_name): New function.
2453         (sim_model_init): Call it.
2454
2455         * cgen-trace.c (trace_insn): Pass pc to trace_prefix for virtual insns.
2456
2457 1999-01-05  Doug Evans  <devans@casey.cygnus.com>
2458
2459         * Make-common.in (CGEN_INCLUDE_DEPS): Add cgen-defs.h, cgen-engine.h.
2460         * cgen-engine.h (SEM_BRANCH_FINI): New arg pcvar, all uses updated.
2461         (SEM_BRANCH_INIT_EXTRACT): New macro.
2462         (SEM_BRANCH_INIT): Add taken_p.
2463         (TARGET_SEM_BRANCH_FINI): Provide default definition.
2464         (SEM_BRANCH_FINI): Use it.
2465         (SEM_INSN): Update.
2466         * cgen-run.c (sim_resume): Handle tracing of last insn.
2467         * cgen-scache.h (WITH_SCACHE): Define as 0 if not defined.
2468         * cgen-trace.c (current_abuf): New static global.
2469         (trace_insn_init): Initialize it.
2470         (trace_insn_fini): Use it.
2471         (trace_insn): Set it.
2472         * cgen.sh (arch case): Pass -m ${mach} to cgen.
2473         * genmloop.sh (@cpu@_emit_before): Only define if WITH_SCACHE_PBB.
2474         (@cpu@_emit_after): Ditto.
2475         (simple @cpu@_engine_run_full): New local `pc'.  Initialize semantic
2476         labels if WITH_SEM_SWITCH_FULL.
2477         * sim-model.c: Include bfd.h.
2478         (sim_model_init): New function.
2479         (sim_model_install): Record init fn.
2480         * sim-model.h (MACH): New member bfd_name.
2481         * sim-module.c (modules): Initialize model before scache.
2482
2483 1998-12-24  Frank Ch. Eigler  <fche@cygnus.com>
2484
2485         * dv-sockser.c (DEFAULT_TIMEOUT): Increase to 1 ms.
2486         
2487         * nrun.c (main): Remain in simulation loop for traps and
2488         exceptions when in operating environment mode.
2489         (ui_loop_hook): New stub hook for standalone use.
2490         * sim-events.c (sim_events_process): Call ui_loop_hook
2491         periodically on CYGWIN host.
2492
2493         * sim-reason.c (sim_stop_reason): Return host signal numbers
2494         to gdb on sim_stopped and sim_signalled cases.
2495         * sim-engine.c (sim_engine_halt): Call SIM_CPU_EXCEPTION_SUSPEND
2496         hook just before longjmp.
2497         * sim-resume.c (sim_resume): Call SIM_CPU_EXCEPTION_RESUME
2498         hook just before sim_engine_run.
2499
2500         * sim-n-core.h (sim_core_trace_M): Allay const warning.
2501         * sim-trace.h (trace_generic): Ditto.
2502         * sim-trace.c (trace_generic): Ditto.
2503         
2504 1998-12-14  Doug Evans  <devans@casey.cygnus.com>
2505
2506         * Make-common.in (SIM_MAIN_DEPS): New var.
2507         (CGEN_MAIN_CPU_DEPS): New var.
2508         * aclocal.m4: Add --enable-cgen-maint option.
2509         * cgen-mem.h (GETMEM*): New arg `pc'.  Pass to sim_core routine.
2510         (SETMEM*): Ditto.
2511         (GETIMEM*): Pass pc value to sim_core routine.
2512
2513 Fri Dec 11 16:58:36 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2514
2515         * hw-handles.c (hw_handle_add_ihandle, hw_handle_add_phandle):
2516         Compare with ZERO not NULL.
2517
2518 Thu Dec 10 14:14:39 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2519
2520         * hw-properties.c, hw-instances.c, hw-tree.c: Include
2521         "sim-assert.h".
2522
2523 1998-12-09  Doug Evans  <devans@casey.cygnus.com>
2524
2525         * sim-arange.c: Include libiberty.h, and stdlib.h if present.
2526         * sim-trace.c: Include stdlib.h if present.
2527         * dv-sockser.c: Include unistd.h if present.
2528         (dv_sockser_init): Add missing arg to call to sim_io_eprintf.
2529         * cgen-scache.c (scache_flush): Delete unused locals i,sc.
2530
2531 1998-12-08  James E Wilson  <wilson@wilson-pc.cygnus.com>
2532
2533         * gennltvals.sh: Add i960.
2534         * nltvals.def: Rebuild.
2535
2536 1998-12-04  Doug Evans  <devans@casey.cygnus.com>
2537
2538         * cgen-defs.h: New file, old cgen-sim.h.
2539         * cgen-sim.h: Simple header that includes others.
2540         * sim-arange.c: New file.
2541         * sim-arange.h: New file.
2542         * sim-basics.h: Include it.
2543         * Make-common.in (SIM_NEW_COMMON_OBJS): Add sim-arange.o.
2544         (sim-arange.o): Add rule for.
2545         * sim-cpu.h (sim_cpu_msg_prefix): Add prototype.
2546         (sim_io_eprintf_cpu): Add prototype.
2547         * sim-inline.h (HAVE_INLINE): Define if GNUC.
2548         (INLINE2): New macro.
2549         (EXTERN_INLINE): New macro.
2550         * sim-module.c (sim_post_argv_init): Initialize cpu backlink
2551         before calling module init fns.
2552         * sim-profile.c (OPTION_PROFILE_*): Move into enum.
2553         (profile_init): New function.
2554         (profile_options): New option --profile-range.
2555         (profile_option_handler): Handle --profile-range.
2556         (profile_print_insn): Qualify address range specific section titles.
2557         (profile_print_addr_ranges): New function.
2558         (profile_info): Print address ranges if specified.
2559         (profile_install): Set profile_init init fn.
2560         * sim-profile.h (PROFILE_DATA): New member `range'.
2561         * sim-trace.c (trace_init): New function.
2562         (trace_options): New option --trace-range.
2563         (trace_option_handler): Handle --trace-range.
2564         (trace_install): Set trace_init init fn.
2565         * sim-trace.h (TRACE_DATA): New member `range'.
2566         * sim-utils.c (sim_cpu_msg_prefix): New function.
2567         (sim_io_eprintf_cpu): New function.
2568         * cgen-engine.h (PC_IN_TRACE_RANGE_P): New macro.
2569         (PC_IN_PROFILE_RANGE_P): New macro.
2570         * cgen-trace.c (trace_insn_init): Set current_insn to NULL.
2571         (trace_insn_fini): New arg abuf.  All callers updated.
2572         Exit early if trace_insn not called.  Check ARGBUF_PROFILE_P before
2573         printing cycle counts.
2574         * cgen-trace.h (trace_insn_fini): Update prototype.
2575         (TRACE_RESULT_P): New macro.
2576         (TRACE_INSN_INIT,TRACE_INSN_FINI): New arg abuf.  All callers updated.
2577         (TRACE_INSN): Check ARGBUF_TRACE_P.
2578         (TRACE_EXTRACT,TRACE_RESULT): New arg abuf.  All callers updated.
2579         * cgen-types.h (SIM_INLINE): Delete.
2580         (SIM_HAVE_MODEL,SIM_HAVE_ADDR_RANGE): Define.
2581         * cgen-utils.c: Don't include cgen-engine.h
2582         * genmloop.sh (@cpu@_fill_argbuf): New function.
2583         (@cpu@_fill_argbuf_tp): New function.
2584         (@cpu@_emit_before,@cpu@_emit_after): New functions.
2585         (@cpu@_pbb_begin): Prefix cti_sc,insn_count with '_'.
2586         (SET_CTI_VPC,SET_INSN_COUNT): Update.
2587         (@cpu@_pbb_before): Check ARGBUF_PROFILE_P before calling
2588         doing profiling.  Update call to TRACE_INSN_INIT,TRACE_INSN_FINI.
2589         (@cpu@_pbb_after): Check ARGBUF_PROFILE_P before calling
2590         doing profiling. Update call to TRACE_INSN_FINI.
2591
2592         * sim-memopt.c (sim_memory_uninstall): Result type is `void'.
2593
2594 1998-12-03  Frank Ch. Eigler  <fche@cygnus.com>
2595
2596         * sim-memopt.c (sim_memory_uninstall): Deallocate all memory
2597         regions.
2598
2599 1998-12-01  Doug Evans  <devans@casey.cygnus.com>
2600
2601         * sim-inline.c (SIM_INLINE_P): Fix typo.
2602
2603 1998-11-30  Doug Evans  <devans@casey.cygnus.com>
2604
2605         * cgen-utils.c (cgen_virtual_opcode_table): Update.
2606
2607 Tue Nov 24 18:40:03 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2608
2609         * gennltvals.sh: Add v850 and d10v. Sort alphabetically.
2610         * nltvals.def: Re-generate.
2611
2612 Mon Nov 23 13:28:38 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2613
2614         * sim-core.c (reverse_n, sim_core_uninstall, sim_core_init,
2615         sim_core_map_attach, sim_core_map_detach, next_event_queue,
2616         new_sim_core_mapping): Only define when EXTERN_SIM_CORE_P, pacify
2617         GCC.
2618         * sim-events.c (sim_events_uninstall, sim_events_suspend,
2619         sim_events_resume, sim_events_zalloc, insert_sim_event): Ditto.
2620
2621 1998-11-22  Doug Evans  <devans@tobor.to.cygnus.com>
2622
2623         * genmloop.sh (${cpu}_pbb_chain): Watch for Ctrl-C's.
2624         (${cpu}_pbb_cti_chain): Ditto.
2625
2626 1998-11-18  Doug Evans  <devans@casey.cygnus.com>
2627
2628         * Make-common.in (cgen-utils.o): Depend on cgen-engine.h.
2629         * cgen-engine.h (EXTRACT_[ML]SB0_{INT,UINT}): New macros.
2630         (EXTRACT_INT,EXTRACT_UINT): New macros.
2631         (SEM_SEM_ARG): New macro.
2632         (SEM_NEXT_VPC): New arg `pc'.
2633         * cgen-sim.h (EXTRACT_SIGNED,EXTRACT_UNSIGNED): Delete.
2634         (sim_disassemble_insn): Update prototype.
2635         * cgen-trace.c (current_insn,insn_fields): New static locals.
2636         (trace_insn): Set them.
2637         * cgen-utils.c: #include cgen-engine.h.
2638         (sim_disassemble_insn): New arg insn_fields.
2639         Handle variable length insns.
2640         * genmloop.sh: Only emit pbb decls if -pbb.
2641         (${cpu}_scache_lookup): New arg `vpc'.
2642         (scache support): Fetch pc before entering loop.
2643
2644         * gennltvals.sh: Add fr30 support.
2645         * nltvals.def: Rebuild.
2646
2647 Wed Nov 18 10:22:22 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2648
2649         * sim-types.h: Re-do type system so that GCC's attribute and mode
2650         are used to specify types.  Handle case of ALPHA.
2651
2652 1998-11-13  Frank Ch. Eigler  <fche@elastic.org>
2653         
2654         * aclocal.m4: Add tests for dlopen family.
2655         * config.in: Regenerated.
2656         
2657 Wed Nov 11 14:02:25 1998  Doug Evans  <devans@canuck.cygnus.com>
2658
2659         * sim-hload.c (sim_load): Pass `prog_name' to sim_load_file, not NULL.
2660
2661 Wed Nov  4 23:51:19 1998  Doug Evans  <devans@seba.cygnus.com>
2662
2663         * genmloop.sh (eng.hin): Rename HAVE_PARALLEL_EXEC to
2664         HAVE_PARALLEL_INSNS, define as 0 or 1.  Emit decls of fns in mloop.cin.
2665         * cgen-engine.h: Typedefs of IADDR,CIA,SEM_ARG,SEM_PC moved ...
2666         * cgen-sim.h: ... to here.
2667
2668 Wed Oct 28 12:00:57 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2669
2670         * aclocal.m4 (enable-build-warnings): Replace
2671         enable-sim-warnings. Extend =LIST syntax so that prepend and
2672         append of options is possible.  Drop -Werror, add
2673         -Wstrict-prototypes for GDB compatibility.
2674         * Make-common.in (SIM_WARNINGS): Update.
2675
2676 Mon Oct 19 13:56:32 1998  Doug Evans  <devans@seba.cygnus.com>
2677
2678         * Make-common.in (CGEN_INCLUDE_DEPS): Define.
2679         (sim-core.o): Delete duplicate dependence on $(SIM_EXTRA_DEPS).
2680         (sim-cpu.o,sim-endian.o,sim-hw.o): Ditto.
2681         (cgen-run.o,cgen-scache.o,cgen-trace.o,cgen-utils.o): Delete
2682         explicit cgen header dependencies, require SIM_EXTRA_DEPS to include
2683         CGEN_INCLUDE_DEPS.
2684         * cgen-cpu.h: New file.
2685         * cgen-engine.h: New file.
2686         * cgen-scache.h: New file.
2687         * cgen-sim.h: Delete portions moved to new files.
2688         * genmloop.sh: Generate two files eng.hin,mloop.cin explicitly,
2689         rather than sending result to stdout.
2690
2691 Fri Oct  9 14:20:22 1998  Doug Evans  <devans@seba.cygnus.com>
2692
2693         * Make-common.in (sim-reg.o): New rule.
2694         (cgen-run.o): New rule.
2695         * cgen-ops.h: Delete many BI macros.  Change all UBI -> BI.
2696         * cgen-run.c (prime_cpu): New function.
2697         * cgen-scache.c: Add pseudo-basic-block (pbb) scaching support.
2698         (scache_option_handler, case OPTION_PROFILE_SCACHE): Handle explicitly
2699         mentioned cpu.
2700         (scache_flush_cpu,scache_lookup,scache_lookup_or_alloc): New fns.
2701         * cgen-sim.h (CGEN_INSN_VIRTUAL_TYPE): New enum.
2702         (CGEN_INSN_VIRTUAL_P): New macro.
2703         (SEM_PC): New typedef.
2704         (SEMANTIC_FN): Change type of result to SEM_PC.
2705         (SEM_SET_FULL_CODE,SEM_SET_FAST_CODE,SEM_SET_CODE): New macros.
2706         (IDESC_CTI_P,IDESC_SKIP_P): New macros.
2707         (SCACHE_MAP): New typedef.
2708         (CPU_SCACHE): Add pbb support.
2709         (scace_lookup,scache_lookup_or_alloc,scache_flush_cpu): Declare.
2710         (SEM_BRANCH_INIT_EXTRACT,SEM_BRANCH_INIT,SEM_BRANCH_FINI): New macros.
2711         (CGEN_CPU): New members running_p,insn_count,{fast,full}_engine_fn,
2712         max_slice_insns.
2713         (INSN_NAME): Delete.
2714         (cgen_insn_name): Declare.
2715         (sim_engine_invalid_insn): Renamed from sim_engine_illegal_insn.
2716         * cgen-trace.c (trace_buf): Shrink from 1024 to 256 bytes.
2717         (first_insn_p): Make static.
2718         (trace_insn): Handle virtual insns specially.
2719         (cgen_trace_printf): Ensure we haven't overflowed the buffer.
2720         * cgen-types.h (UBI): Delete.
2721         (MODE_TYPE): New enum.
2722         (HOSTINT,HOSTUINT,HOSTPTR): Delete.
2723         * cgen-utils.c (mode_names): Delete UBI.  Add INT,UINT,PTR.
2724         (cgen_virtual_opcode_table): New global.
2725         (cgen_insn_name): New function.
2726         (sim_disassemble_insn): Ignore virtual insns.
2727         * genmloop.sh: Delete top level loop generation.  Add pbb support.
2728         * sim-cpu.h (CPU_INSN_NAME_FN): New typedef.
2729         (sim_cpu_base): New members max_insns,insn_name,model_data.
2730         (CPU_PC_GET,CPU_PC_SET): New macros.
2731         (sim_pc_get,sim_pc_set): Declare.
2732         * sim-model.c (model_set): Call model init fn.
2733         * sim-model.h (MODEL_FN): New typedef.
2734         (INSN_TIMING): New member model_fn.
2735         (MODEL): New members num,init.
2736         * sim-profile.c (sim_profile_print_bar): Renamed from print_bar.
2737         All callers updated.
2738         (profile_insn_init): New fn.
2739         (profile_print_insn): Update, INSN_NAME -> CPU_INSN_NAME.
2740         Exit early if insn profiling not supported.
2741         (profile_print_memory): Update, MAX_MODES -> MODE_TARGET_MAX.
2742         (profile_install): Record profile_insn_init as init fn.
2743         (profile_uninstall): Free PROFILE_INSN_COUNT if non-null.
2744         * sim-profile.h: Update, MAX_MODES -> MODE_TARGET_MAX.
2745         (PROFILE_DATA): Delete member exec_time.
2746         Change insn_count to pointer to array, rather than the array.
2747         (sim_profile_print_bar): Declare.
2748
2749 Wed Oct  7 16:56:42 1998  Doug Evans  <devans@seba.cygnus.com>
2750
2751         * cgen-run.c: New file.
2752         * sim-reg.c: New file.
2753
2754 Mon Sep 14 10:58:19 1998  Frank Ch. Eigler  <fche@cygnus.com>
2755
2756         * aclocal.m4: Add checks for -lsocket and -lnsl.
2757
2758         * dv-sockser.c (dv_sockser_init): Use SO_REUSEADDR to
2759         allow local port reuse on listening socket.
2760
2761 Tue Sep  1 15:36:52 1998  Frank Ch. Eigler  <fche@cygnus.com>
2762
2763         * sim-config.h: Remove reference to linux kernel header.
2764
2765 Tue Aug 25 12:45:27 1998  Frank Ch. Eigler  <fche@cygnus.com>
2766
2767         * dv-sockser.c (sockser_addr): Make variable non-static.
2768
2769 Mon Aug 24 11:47:37 1998  Joyce Janczyn  <janczyn@cygnus.com>
2770
2771         * sim-hw.{c,h} (sim_hw_parse): Return struct hw pointer.
2772
2773 Tue Aug 11 18:12:19 1998  Doug Evans  <devans@canuck.cygnus.com>
2774
2775         * sim-events.c (sim_events_elapsed_time): Fix calculation.
2776
2777 Tue Aug  4 20:36:46 1998  Jeff Holcomb  <jeffh@cygnus.com>
2778
2779         * Make-common.in (install-common): Add $(EXEEXT) when installing
2780         run.
2781
2782 Mon Aug  3 11:46:01 1998  Doug Evans  <devans@seba.cygnus.com>
2783
2784         * cgen-sim.h (cgen_state): New member opcode_table.
2785         * cgen-utils.c (sim_disassemble_insn): Use it.
2786
2787 Fri Jul 24 10:14:18 1998  Doug Evans  <devans@canuck.cygnus.com>
2788
2789         * cgen-mem.h (DECLARE_SETT): Fix return type.
2790         * cgen-sim.h (sim_engine_illegal_insn): Declare.
2791         * cgen-scache.c: Include stdlib.h.
2792         * cgen-trace.c (trace_extract): Use %lx for PCADDR.
2793         * sim-model.c (model_option_handler): Remove unused variable `n'.
2794
2795 Tue Jul 21 16:27:43 1998  Doug Evans  <devans@seba.cygnus.com>
2796
2797         * cgen-utils.c: Include bfd.h.
2798         (sim_disassemble_insn): Update call to CGEN_EXTRACT_FN.
2799
2800 Wed Jul  8 18:24:10 1998  Jeffrey A Law  (law@cygnus.com)
2801
2802         * sim-bits.h (EXTEND24): Fix typo.
2803
2804 Wed Jul  8 17:41:47 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2805
2806         * sim-events.c (ETRACE_P): New macro.
2807         (struct _sim_event): Add member trace.
2808         (sim_events_free): Reclaim trace message.
2809
2810         * sim-events.c, sim-events.h (sim_events_schedule_vtracef,
2811         sim_events_schedule_tracef): New functions, include printf trace
2812         information in argument list.  If tracing, store asprintf'd trace
2813         message in sim_event.
2814
2815         * hw-events.c, hw-events.h (hw_event_queue_schedule_tracef,
2816         hw_event_queue_schedule_vtracef): New functions, mimic
2817         sim_event_tracef.
2818
2819 Mon Jul  6 15:51:14 1998  Jeffrey A Law  (law@cygnus.com)
2820
2821         * sim-bits.h (EXTEND24): Define.
2822
2823 Thu Jul  2 17:13:25 1998  Doug Evans  <devans@seba.cygnus.com>
2824
2825         * cgen-sim.h (CPU_SCACHE): Make size unsigned.
2826         (CPU_SCACHE_HASH_MASK): New macro.
2827         (SCACHE_HASH_PC): Rewrite.
2828         * genmloop.sh (engine_resume_{full,fast}): Move some of hash
2829         computation out of main loop.
2830
2831 Wed Jul  1 16:44:12 1998  Doug Evans  <devans@seba.cygnus.com>
2832
2833         * cgen-sim.h (RECORD_IADDR): Delete.
2834         * cgen-types.h (HOSTINT,HOSTUINT,HOSTPTR): New types.
2835         * genmloop.sh (engine_resume_{full,fast}): Delete icount.
2836
2837 Wed Jun 17 12:25:08 1998  Mark Alexander  <marka@cygnus.com>
2838
2839         * gennltvals.def (mn10200): Add entry.
2840         * nltvals.def: Regenerate with MN10200 additions.
2841
2842 Wed Jun 17 13:18:28 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2843
2844         * sim-inline.h (EXTERN_*): Replace with EXTERN_*_P. Correct
2845         documentation on how it works.
2846
2847         * sim-core.h, sim-core.c (sim_core_install, sim_core_attach,
2848         sim_core_detach, sim_core_read_buffer, sim_core_write_buffer,
2849         sim_core_set_xor, sim_core_xor_read_buffer,
2850         sim_core_xor_write_buffer): Update.
2851
2852         * sim-events.h, sim-events.c (sim_events_install,
2853         sim_events_watch_clock, sim_events_schedule_after_signal,
2854         sim_events_schedule, sim_events_watch_sim, sim_events_watch_core,
2855         sim_events_deschedule): Update.
2856
2857         * sim-fpu.h, sim-fpu.c (sim_fpu_zero, sim_fpu_one, sim_fpu_two,
2858         sim_fpu_max32, sim_fpu_max64): Update.
2859
2860 Sat Jun 13 07:45:38 1998  Doug Evans  <devans@fallis.cygnus.com>
2861
2862         * cgen-trace.c (trace_insn_fini): Redo cycle handling.
2863         * sim-profile.h (PROFILE_DATA): Rename cycle handling members.
2864         * sim-profile.c (profile_print_model): Update.
2865
2866 Fri Jun 12 18:35:07 1998  Doug Evans  <devans@seba.cygnus.com>
2867
2868         * gennltvals.def (m32r): Use common syscall.h now.
2869         (mn10300): Add entry.
2870         * nltvals.def: Regenerate.
2871
2872         * sim-engine.c (sim_engine_get_run_state): New function.
2873         * sim-engine.h (sim_engine_get_run_state): Declare it.
2874
2875 Thu Jun 11 00:50:03 1998  Doug Evans  <devans@seba.cygnus.com>
2876
2877         * sim-core.h (SIM_CORE_SIGNAL_FN): New typedef.
2878         * sim-core.c (sim_core_signal): Make extern, always define.
2879
2880 Wed Jun 10 16:02:29 1998  Doug Evans  <devans@seba.cygnus.com>
2881
2882         * Make-common.in (CGEN_FLAGS_TO_PASS): New variable.
2883         * cgen-ops.h (ANDIF): New macro.
2884         (ANDIF[BQHSD]I): Delete.
2885
2886 Thu Jun  4 13:53:54 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2887
2888         * hw-events.c (create_hw_event, delete_hw_event): Delete.
2889         (hw_event_queue_schedule, hw_event_queue_deschedule,
2890         bounce_hw_event): Fix hw-event memory corruptions found by Joyce
2891         Janczyn.
2892
2893         * hw-alloc.h (HW_NZALLOC): Define.
2894
2895         * Make-common.in (test-hw-events): Add target for testing the
2896         hw-event code.
2897
2898 Mon May 25 21:11:26 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2899
2900         * Make-common.in (SIM_COMMON_HW_OBJS): Add hw-handles.o and
2901         hw-instances.o.
2902         hw-handles.c, hw-instances.c, hw-handles.h, hw-instances.h: New
2903         files.
2904         * hw-main.h: Include hw-handles.h, hw-instances.h.
2905         * hw-base.h ({create,delete}_hw_{handles,instances}_data): Declare
2906         * hw-base.c (hw_create, hw_delete): Call same.
2907         
2908 Mon May 25 18:55:35 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2909
2910         * dv-core.c: Include hw-main.h and sim-main.h.
2911         * dv-pal.c: Include hw-main.h and sim-io.h.
2912         * dv-glue.c: Include hw-main.h.
2913
2914         * hw-main.h: New file.  Move list of includes to here.
2915         * hw-base.h: From here.
2916         * Make-common.in (hw_base_headers): Rename to hw_main_headers.
2917         (hw-*.o, dv-*.o): Update.
2918         * hw-tree.c, hw-base.c, hw-properties.c, hw-ports.c, hw-device.c,
2919         hw-events.c, hw-alloc.c, sim-hw.c: Include hw-main.h instead of
2920         sim-main.h.
2921
2922         * hw-base.h (do_hw_attach_regs, do_hw_poll_read_method,
2923         do_hw_poll_read): Move declarations from here.
2924         * hw-main.h: To here.
2925         
2926         * hw-base.h (struct hw_device_descriptor, hw_finish_callback):
2927         Move from here.
2928         * hw-main.h (struct hw_descriptor, hw_finish_method): To here,
2929         rename.
2930         * Make-common.in (hw-config.h): Update
2931         * hw-base.c, dv-pal.c, dv-glue.c: Update
2932
2933         * dv-glue.c, hw-device.h, hw-base.h, hw-ports.c: Rename
2934         `*_callback' to `*_method.
2935
2936 Mon May 25 18:41:18 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2937
2938         * hw-base.h (set_*): Move set method macros from here.
2939         * hw-device.h: To here.
2940
2941 Mon May 25 18:21:38 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2942
2943         * hw-base.h (create_hw_property_data, delete_hw_property_data):
2944         Declare.
2945
2946         * hw-base.c (hw_create, hw_delete): Call
2947         * hw-properties.c (create_hw_property_data,
2948         delete_hw_property_data): Define.
2949         
2950 Mon May 25 17:40:46 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2951
2952         * hw-device.c, hw-properties.c: Include hw-base.h
2953
2954         * hw-alloc.h, hw-alloc.c: New files. Move alloc code to here.
2955         * hw-device.c: From here.
2956         * hw-base.h: Include "hw-events.h".
2957
2958         * hw-base.h (create_hw_alloc_data, delete_hw_alloc_data): Declare.
2959         * hw-base.c (hw_create, hw_delete): Call.
2960         * hw-alloc.c (create_hw_alloc_data, delete_hw_alloc_data): Define.
2961
2962         * Make-common.in (SIM_NEW_COMMON_OBJS): Add hw-alloc.o.
2963         (hw-alloc.o): New target.
2964         
2965 Mon May 25 17:14:27 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2966
2967         * hw-events.h, hw-events.c: New files.  Move event code to here.
2968         * sim-hw.c: From here.
2969         * hw-base.h: Include "hw-events.h".
2970         * Make-common.in (SIM_NEW_COMMON_OBJS): Add hw-events.o.
2971         (hw-events.o): New target.
2972
2973         * hw-device.h (struct hw): Add struct hw_event_data events_of_hw.
2974         * hw-events.h (struct hw_event): Replace typedef hw_event.
2975         
2976         * hw-base.h (create_hw_event_data, delete_hw_event_data): Declare.
2977         * hw-base.c (hw_create, hw_delete): Call.
2978         * hw-events.c (create_hw_event_data, delete_hw_event_data): Define.
2979
2980         * dv-pal.c: Update.
2981
2982 Mon May 25 16:55:16 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2983
2984         * hw-base.c (panic_hw_port_event, empty_hw_ports): Move from here.
2985         * hw-ports.c: To here.
2986         
2987         * hw-base.h, hw-ports.c (create_hw_port_data,
2988         delete_hw_port_data): New functions.
2989         * hw-base.c (hw_delete, hw_create): Call same.
2990         
2991         * hw-base.h (set_hw_ports, set_hw_port_event): Move set functions
2992         from here.
2993         * hw-ports.h: To here.
2994
2995 Mon May 25 16:42:48 1998  Andrew Cagney  <cagney@b1.cygnus.com>
2996
2997         * hw-device.c (hw_ioctl), hw-device.h (hw_ioctl_callback): Drop
2998         PROCESSOR and CIA arguments.
2999
3000 Fri May 22 12:16:27 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3001
3002         * aclocal.m4 (SIM_AC_OPTION_HW): Add enable / disable argument.
3003         Move common object files from here.
3004         * Make-common.in (SIM_COMMON_HW_OBJS): To here.
3005         
3006 Thu May 21 17:57:16 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3007
3008         * sim-hw.c: Include ctype.h.
3009         (do_hw_poll_read): Do not assume EAGAIN.
3010
3011 Wed May 20 04:37:57 1998  Doug Evans  <devans@seba.cygnus.com>
3012
3013         * cgen-trace.c (first_insn_p): New static local.
3014         (trace_insn_init): Set it.
3015         (trace_insn_fini): Use TRACE_PREFIX.
3016         (trace_insn): Rewrite to use trace_prefix.
3017         * sim-trace.c (trace_prefix): Don't print filename arg if NULL.
3018         Adjust width accordingly.
3019
3020         * sim-profile.h (PROFILE_DATA): New member profile_any_p.
3021         (PROFILE_ANY_P,PROFILE_INSN_P,PROFILE_MEMORY): New macros.
3022         (PROFILE_SCACHE_P,PROFILE_PC_P,PROFILE_CORE_P): New macros.
3023         (PROFILE_COUNT_INSN,PROFILE_COUNT_READ,PROFILE_COUNT_WRITE): Simplify.
3024         (PROFILE_COUNT_CORE): Simplify.
3025         * sim-profile.c (profile_option_handler): Compute profile_any_p.
3026
3027 Tue May 19 23:55:30 1998  Doug Evans  <devans@seba.cygnus.com>
3028
3029         * cgen-ops.h (ADDCFSI): Fix typo.
3030
3031 Sat May 16 12:44:52 1998  Doug Evans  <devans@seba.cygnus.com>
3032
3033         * cgen-sim.h (CGEN_CPU): New members idesc_{read,sem}_init_p.
3034         * genmloop.sh: Use them rather than static locals.
3035
3036         * sim-engine.c (sim_engine_set_run_state): New function.
3037         * sim-engine.h (sim_engine_set_run_state): Declare.
3038         * genmloop.sh (pending_reason,pending_sigrc): New static locals.
3039         (@cpu@_engine_stop): New args reason,sigrc.  All callers updated.
3040         (engine_resume): Reorganize.  Allow synchronous exit from main loop.
3041
3042 Fri May 15 16:06:05 1998  Doug Evans  <devans@seba.cygnus.com>
3043
3044         * cgen-trace.c (trace_insn_init): New arg first_p. 
3045         All callers updated.
3046         (trace_insn_fini): New arg last_p.  All callers updated.
3047         * cgen-trace.h (trace_insn_init,trace_insn_fini): Update.
3048         (TRACE_INSN_INIT,TRACE_INSN_FINI): Update.
3049         * genmloop.sh (engine_resume): Update.
3050
3051 Fri May 15 15:59:00 1998  Joyce Janczyn  <janczyn@cygnus.com>
3052
3053         * Make-common.in (install-common): Run ranlib on installed copy of
3054         libsim.a.
3055
3056 Fri May 15 15:03:00 1998  Joyce Janczyn  <janczyn@cygnus.com>
3057
3058         * Make-common.in (install-common): Rename and install libsim.a.
3059
3060 Tue May 12 15:23:57 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3061
3062         * sim-io.c (unistd.h): Include.
3063
3064 Wed May  6 16:04:18 1998  Doug Evans  <devans@seba.cygnus.com>
3065
3066         * Make-common (sim_main_headers): Sort.
3067         (cgen-*.o): Add cgen-sim.h dependency.
3068
3069         * cgen-scache.c (scache_init): Only allocate space if scache element
3070         size is non-zero.
3071         (scache_flush,scache_print_profile): Check if scache in use first.
3072
3073         * cgen-sim.h (IDESC): Provide forward declaration.
3074         (DECODE): Delete.
3075         (CGEN_CPU): Always define scache member.  New members idesc,opcode.
3076         (cgen_cpu_max_extra_bytes): Declare.
3077         * cgen-utils.c (cgen_cpu_max_extra_bytes): New function.
3078
3079         * sim-cpu.h: New file.  sim_cpu_base moved here.
3080         Move sim_cpu_lookup decl here.
3081         * sim-base.h: #include "sim-cpu.h".
3082         * sim-cpu.c: New file.
3083         * Make-common (sim_main_headers): Add sim-cpu.h.
3084         (sim-cpu.o): Add rule for.
3085
3086         * sim-model.c (set_model): Delete.
3087         (sim_model_set,model_set): New functions.
3088         (sim_model_install): Renamed from model_install.
3089         Don't set default model here.
3090         (model_option_handler): Rewrite --model processing.
3091         (sim_model_lookup,sim_mach_lookup): New functions.
3092         * sim-model.h (MAX_MODELS,MAX_INSNS): Delete.
3093         (insn_timing): Delete.
3094         (INSN_TIMING): New member `num'.
3095         (IMP_PROPERTIES): Always define scache_elm_size member.
3096         (MACH): New member init_cpu.
3097         (sim_machs): Renamed from machs.
3098         (sim_model_install): Renamed from model_install.
3099         (sim_model_set,sim_model_lookup,sim_mach_lookup): Declare.
3100         * sim-module.c (modules): Update.
3101
3102         * sim-profile.c (profile_print_insn): Add cpu arg to INSN_NAME macro.
3103
3104         * sim-io.c: #include <errno.h>.
3105
3106 Wed May  6 12:39:15 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3107
3108         * dv-pal.c (struct hw_pal_device): Add reader.
3109         (hw_pal_finish): Initialize reader.
3110         (scan_hw_pal): Use reader.
3111
3112         * hw-base.h, sim-hw.c (do_hw_poll_read): New function.
3113         (HW_IO_EOF, HW_IO_NOT_READY): Define.
3114         * dv-pal.c: Use.
3115
3116         * sim-io.h, sim-io.c (sim_io_poll_read): New function.  Copy from
3117         ../ppc/main.c sim_io_read_stdin.
3118
3119 Fri May  1 12:11:02 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3120
3121         * hw-tree.h (hw_tree_print): Paramaterize with print and file
3122         arguments.
3123         * hw-tree.c: Update.
3124         
3125         * hw-base.h (hw_port_event_callback): Delete CPU/CIA args.
3126         * hw-device.h (hw_io_read_buffer, hw_io_write_buffer): Delete
3127         CPU/CIA args.
3128         * hw-ports.h (hw_port_event): Ditto.
3129         * hw-ports.c (hw_port_event): Update.
3130         * hw-base.c (panic_hw_io_read_buffer, panic_hw_io_write_buffer):
3131         Update.
3132         * dv-pal.c (hw_pal_io_read_buffer, hw_pal_io_write_buffer):
3133         Update.
3134         (hw_pal_io_write_buffer): Call hw_halt not sim_engine_halt.
3135         (do_counter_event): Update.
3136         * dv-glue.c (hw_glue_io_read_buffer): Update.
3137         (hw_glue_port_event): Update.
3138
3139         * hw-device.h (SIM_DESC): Replace with struct sim_state.
3140         * hw-base.h (hw_create): Ditto.
3141         * hw-base.c (hw_create): Ditto.
3142         
3143         * hw-device.c (hw_abort, hw_trace, hw_hw_event_queue_schedule,
3144         hw_event_queue_deschedule, hw_event_queue_time): Delete, moved
3145         from here to.
3146         * sim-hw.c: Here.
3147         * hw-device.h (hw_system_cpu): Declare.
3148         * sim-hw.c (hw_system_cpu): New function.
3149
3150         * sim-core.c (sim_core_map_attach, sim_core_attach): Call
3151         sim_hw_abort not hw_abort.
3152         (sim-hw.h): Include.
3153         (sim_core_read_buffer, sim_core_write_buffer): Call
3154         sim_hw_io_read_buffer and sim_hw_io_write_buffer. Do not pass CPU
3155         argument.
3156         (sim_core_set_xor): Do not pass CPU when aborting.
3157
3158         * sim-n-core.h (sim_core_read_aligned_N,
3159         sim_core_write_aligned_N): Call sim_hw_abort not hw_abort.
3160         (sim_core_read_aligned_N, sim_core_write_aligned_N): Call
3161         sim_cpu_hw_io_read_buffer and sim_cpu_hw_io_write_buffer. Does not
3162         return length.
3163
3164         * sim-hw.h: Declare sim_hw_io_{read,write}_buffer. Declare
3165         sim_hw_print.
3166         * sim-hw.c (sim_hw_io_read_buffer, sim_hw_io_write_buffer,
3167         sim_cpu_hw_io_read_buffer, sim_cpu_hw_io_write_buffer): New
3168         functions.
3169         (sim_hw_print): New function.
3170
3171         * sim-engine.h (sim_engine_vabort): Declare.
3172         * sim-engine.c (sim_engine_vabort): New function.
3173
3174 Wed Apr 29 23:58:52 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3175
3176         * sim-trace.c (print_data): For floating-point numbers trace raw
3177         hex value.
3178         (trace_result_fp2): New function.
3179         * sim-trace.h (trace_result_fp2): New declaration.
3180         (TRACE_FP_RESULT2): New macro.
3181
3182 Tue Apr 28 18:28:58 1998  Geoffrey Noer  <noer@cygnus.com>
3183
3184         * common/aclocal.m4: call AM_EXEEXT in SIM_AC_COMMON, define
3185         AM_CYGWIN32 and AM_EXEEXT.
3186         * common/Make-common.in: set EXEEXT, add missing EXEEXTs
3187         to run and install-common rules.
3188         * common/configure: regenerate
3189
3190 Sat Apr 25 17:45:01 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3191
3192         * sim-types.h (cell_word): New type.
3193         (natural_cell): Delete type.
3194
3195 Sun Apr 26 15:31:55 1998  Tom Tromey  <tromey@creche>
3196
3197         * configure: Regenerated to track ../common/aclocal.m4 changes.
3198         * config.in: Ditto.
3199
3200 Sun Apr 26 15:25:07 1998  Tom Tromey  <tromey@cygnus.com>
3201
3202         * acconfig.h (NEED_DECLARATION_PRINTF): Removed.
3203
3204 Fri Apr 24 14:16:40 1998  Tom Tromey  <tromey@creche>
3205
3206         * configure: Regenerated to track ../common/aclocal.m4 changes.
3207         * config.in: Ditto.
3208
3209 Fri Apr 24 11:38:08 1998  Tom Tromey  <tromey@cygnus.com>
3210
3211         * acconfig.h: New file.
3212         * Make-common.in (top_builddir): New macro.
3213         (INTL_LIB): Removed.
3214         (INTLLIBS): New macro.
3215         (INTLDEPS): Likewise.
3216         (LIBDEPS): Use INTLDEPS.
3217         (EXTRA_LIBS): Use INTLLIBS.
3218         * aclocal.m4 (SIM_AC_COMMON): Call CY_GNU_GETTEXT.
3219         (CY_WITH_NLS, CY_GNU_GETTEXT, AM_PATH_PROG_WITH_TEST,
3220         AM_LC_MESSAGES): New macros from GNU gettext.
3221
3222 Fri Apr 24 19:57:59 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3223
3224         * sim-config.h: Discard leading _ from macros.
3225         * sim-types.h: Ditto.
3226
3227 Wed Apr 22 14:14:19 1998  Michael Meissner  <meissner@cygnus.com>
3228
3229         * Make-common.in (CSEARCH): Add -I to intl directories.
3230         (INTL_LIB): Point to libintl.a.
3231         (LIBDEPS): Add $(INTL_LIB).
3232         (EXTRA_LIBS): Ditto.
3233
3234 Tue Apr 21 12:44:27 1998  Doug Evans  <devans@canuck.cygnus.com>
3235
3236         * cgen-types.h (GETHIDI,MAKEDI): Tweak.
3237
3238         * cgen-ops.h (ADDCFSI): Fix.
3239         (SUBCFSI): Tweak.
3240
3241 Tue Apr 21 13:18:41 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3242
3243         * sim-types.h (signed_address, unsigned_address): Define.
3244
3245 Mon Apr 20 21:47:54 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3246
3247         * sim-fpu.c (sim_fpu_2d): Don't return an SNaN, convert it into a
3248         QNaN.
3249
3250 Thu Apr 16 10:30:14 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3251
3252         * sim-fpu.c, sim-fpu.h (sim_fpu_fractionto, sim_fpu_tofraction):
3253         New functions, pack / unpack sim_fpu struct using raw values.
3254         (sim_fpu_is): Differentiate between negative and positive
3255         infinity.
3256
3257 Tue Apr 14 18:49:31 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3258
3259         * sim-bits.h (EXTEND4): Define.
3260         (EXTEND4, EXTEND15, EXTEND11): Ditto.
3261         
3262 Tue Apr 14 16:31:35 1998  John Metzler  <jmetzler@cygnus.com>
3263
3264         * sim-memopt.c (parse_addr): Sunos 4.5 does not have strtol
3265         declared so we need this cast to prevent long long addresses
3266         from being misconfigures. Results in access to unmapped memory.
3267
3268 Tue Apr 14 13:19:14 1998  Doug Evans  <devans@canuck.cygnus.com>
3269
3270         * Make-common.in (RUNTESTFLAGS): Define.
3271         (check): Pass RUNTESTFLAGS to recursive make.
3272
3273 Tue Apr 14 15:09:19 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3274
3275         * sim-info.c (sim_info): Be verbose when either VERBOSE or
3276         STATE_VERBOSE_P.
3277
3278 Sat Apr  4 23:24:17 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3279
3280         * aclocal.m4 (sim-inline): By default, disable sim-inline when
3281         cross compiling.
3282
3283 Sat Apr  4 20:36:25 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3284
3285         * aclocal.m4 (sim-cflags): Add -fomit-frame-pointer to defaults.
3286         (sim-inline): Update to match sim-inline.[hc]
3287         * configure: Regenerated to track ../common/aclocal.m4 changes.
3288
3289         * Make-common.in (sim_main_headers): Add sim-inline.h
3290
3291         * sim-bits.h (sim-bits.c): Include when H_REVEALS_MODULE_P.
3292         selected.
3293         * sim-endian.h (sim-endian.c): Ditto.
3294         
3295         * sim-events.h (_SIM_EVENTS_H_): Replace with SIM_EVENTS_H.
3296         (sim_events_set_trace): Delete unused prototype.
3297         
3298         * sim-core.h (_SIM_CORE_H_): Replace with SIM_CORE_H.
3299         * sim-core.c (_SIM_CORE_C_): Ditto for SIM_CORE_C.
3300
3301         * sim-fpu.h (sim-fpu.c): Include when H_REVEALS_MODULE_P.
3302         (sim_fpu_to232i, sim_fpu_to232u, sim_fpu_i232to, sim_fpu_u232to):
3303         Comment out, not yet implemented in sim-fpu.c.
3304         (sim_fpu_zero, sim_fpu_one, sim_fpu_two, sim_fpu_qnan,
3305         sim_fpu_max32, sim_fpu_max64): Mark as EXTERN_SIM_FPU.
3306         
3307         * sim-inline.h: Rewrite description.
3308         (H_REVEALS_MODULE_P, C_REVEALS_MODULE_P): Define.
3309         (SIM_MAIN_INLINE): Add inline option.
3310         
3311         * sim-inline.c (semantics.c, idecode.c, engine.c, ...): Do not
3312         include generated files. Handled by generator directly.
3313         
3314 Sat Apr  4 01:07:06 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3315
3316         * sim-trace.c (set_trace_option_mask): Keep TRACE_ANY_P
3317         up-to-date.
3318
3319         * sim-trace.h (TRACE_ANY_P): Define.
3320         (struct _trace_data): Add trace_any_p.
3321
3322 Mon Mar 30 17:11:55 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3323
3324         * run.c (main): Handle all alternatives of enum sim_stop.
3325         (main): Delete unused `asection *s'.
3326
3327 Fri Mar 27 16:15:52 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3328
3329         * hw-tree.h, hw-tree.c (hw_tree_vparse): New function
3330
3331         * configure: Regenerated to track ../common/aclocal.m4 changes.
3332
3333         * sim-hw.c: New file.
3334         * sim-hw.h (sim_hw_parse): Declare function.
3335         (hw-tree.h): Do not include.
3336         
3337         * sim-base.h (STATE_HW): Define.
3338         (struct sim_state_base): Add member struct *hw.
3339
3340         * sim-module.c (sim-hw.h): Include.
3341         (modules): Add sim_hw_install.
3342         
3343         * aclocal.m4 (sim_hw_obj): Add sim-hw.o
3344
3345 Fri Mar 27 14:55:06 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3346
3347         * sim-base.h (CPU_INDEX): Define.
3348
3349         * sim-utils.c (sim_state_alloc): Initialize.
3350         * sim-module.c (sim_post_argv_init): Ditto.
3351
3352 Thu Mar 26 10:07:57 1998  Stu Grossman  <grossman@bhuna.cygnus.co.uk>
3353
3354         * aclocal.m4 (sim_hw_obj):  Fix sed expression to generate
3355         properly formatted lists.
3356
3357 Thu Mar 26 10:37:22 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3358
3359         * dv-pal.c (enum hw_pal_address_mask): From Stu Grossman, was
3360         0x2f needs to be 0x3f.
3361
3362 Thu Mar 26 09:10:56 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3363
3364         * hw-tree.c (hw_tree_find_property): Return NULL when device is
3365         not found.
3366         (hw_tree_find_*_property): Clean up error message when property is
3367         not found.
3368
3369         * dv-pal.c (hw_pal_io_read_buffer): Check the smp property is
3370         present before looking for it.
3371
3372 Wed Mar 25 16:17:38 1998  Ian Carmichael  <iancarm@cygnus.com>
3373
3374         * aclocal.m4 (AC_CHECK_HEADERS): Add check for fpu_control.h.  
3375         (AC_CHECK_FUNCS): Add check for __setfpucw.
3376         * configure: Regenerated.
3377
3378 Wed Mar 25 09:18:34 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3379
3380         * dv-pal.c (hw_pal_countdown, hw_pal_countdown_value,
3381         hw_pal_timer, hw_pal_timer_value): Define.
3382         (hw_pal_io_read_buffer, hw_pal_io_write_buffer): Add timer support
3383         (do_counter_event, do_counter_read, do_counter_value,
3384         do_counter_write): new functions.
3385
3386 Tue Mar 24 12:24:24 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3387
3388         * hw-tree.c (hw_printf): Send tree dump to stderr, same as other
3389         trace output.
3390
3391         * hw-base.c (hw_create): Stop searching for a device when one is
3392         found.
3393
3394 Wed Mar 25 12:35:29 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3395
3396         * configure: Regenerated to track ../common/aclocal.m4 changes.
3397
3398 Mon Mar 23 10:25:08 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3399
3400         * aclocal.m4 (SIM_AC_OPTION_HARDWARE): Add second argument,
3401         appends extra devices.
3402         (SIM_AC_OPTION_HARDWARE): Substute sim_hw, a non-duplicate list of
3403         the device names.
3404         
3405         * Make-common.in (hw-config.h): New target, create hw-config.h
3406         file.
3407         (SIM_HW): Definition from @sim_hw@.
3408         (hw-base.o): Depend on hw-config.h
3409
3410 Tue Mar 24 17:41:35 1998  Stu Grossman  <grossman@bhuna.cygnus.co.uk>
3411
3412         * Make-common.in:  Get SHELL from configure.
3413         * (stamp-tvals sim-inline.c):  Use $(SHELL) when invoking
3414         move-if-change.  Fixes NT native build problem.
3415         * Makefile.in (nltvals.def):   Use $(SHELL) when invoking
3416         move-if-change.  Fixes NT native build problem.
3417         * configure:  Regenerate with autoconf 2.12.1 to fix shell issues for
3418         NT native builds.
3419         
3420 Sun Mar 22 16:54:40 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3421
3422         * hw-device.h, hw-device.c (hw_strdup): New function.
3423
3424         * hw-base.c (hw_create): Use hw_strdup when saving a copy of the
3425         strings name, family and args.
3426         (full_name_of_hw): Use hw_strdup when returning the full path.
3427
3428         * hw-properties.c: Clean up property not found / wrong type error
3429         messages.
3430         
3431         * hw-tree.c (hw_tree_parse): Finish a devices initialization
3432         before attaching any ports.
3433
3434         * hw-base.c (hw-config.): Include.  Replace hardwired table.
3435
3436         * dv-glue.c: Copy over ../ppc/hw_glue.c.  Update to new framework.
3437
3438         * Make-common.in: Add rule for dv-glue.o.
3439
3440 Sun Mar 22 16:45:54 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3441
3442         * hw-base.c (hw_finish): Move setting of trace level to here.
3443         (hw_create): From here.
3444
3445         * hw-base.h, hw-base.c (do_hw_attach_regs): Copy function from
3446         ../ppc/device_table.c.
3447
3448         * dv-pal.c (hw_pal_finish): Attach PAL device to parent bus.
3449
3450         * hw-tree.c (print_properties): Supress path when printing
3451         properties of root node.
3452
3453 Sun Mar 22 16:21:15 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3454
3455         * hw-device.h (HW_TRACE): Define.
3456         (hw_trace): Declare.
3457         * hw-device.c (hw_trace): Implement function.
3458
3459         * hw-base.c (hw_create): Set hw trace level from "trace?"
3460         property.
3461
3462         * dv-core.c (dv_core_attach_address_callback): Add trace.
3463
3464         * dv-pal.c: Replace DTRACE with HW_TRACE.
3465
3466 Sun Mar 22 15:23:35 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3467
3468         * hw-device.h (HW_ZALLOC, HW_MALLOC): New macros.
3469         (hw_alloc_data): Delcare.
3470         (struct hw): Add member alloc_of_hw.
3471         
3472         * hw-device.c (hw_zalloc, hw_malloc, hw_free, hw_free_all): New
3473         functions. Assocate memory with a device.
3474         (stdlib.h): Include.
3475         
3476         * hw-base.h (set_hw_delete): Define.
3477         (hw_delete_callback): Declare.
3478         (hw_delete): Declare.
3479
3480         * hw-base.c (hw_delete): Implement function.
3481         (struct hw_base_data): Add member to_delete.
3482         (ignore_hw_delete): New function, does nothing.
3483         (hw_create): Set the hw_delete method.
3484         (hw_create): Allocate the base type using HW_ZALLOC before setting
3485         any methods.
3486
3487         * hw-tree.h, hw-tree.c (hw_tree_delete): New function.
3488         
3489         * hw-properties.c: Replace zalloc/zfree with hw_zalloc/hw_free.
3490         
3491         * hw-ports.c: Replace zalloc/zfree with hw_zalloc/hw_free.
3492         (attach_hw_port_edge): Add struct hw argument
3493
3494         * dv-pal.c (hw_pal_finish): Replace zalloc/zfree with
3495         hw_zalloc/hw_free.
3496
3497 Sun Mar 22 15:09:52 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3498
3499         * hw-device.h (hw_attach_address_callback,
3500         hw_detach_address_callback): Attach to a single space not a space
3501         mask. Clarify interpretation of SPACE:ADDR parameters.
3502
3503         * hw-base.c (passthrough_hw_attach_address,
3504         passthrough_hw_detach_address): Update.
3505         * dv-core.c (dv_core_attach_address_callback): Ditto.
3506         * dv-pal.c (hw_pal_attach_address): Ditto.
3507
3508 Thu Mar 19 00:41:00 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3509
3510         * sim-options.h: Document additional CPU arg to OPTION_HANDLER.
3511
3512 Wed Mar 18 14:13:02 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3513
3514         * Make-common.in (SIM_HW_OBJS, SIM_HW_SRC, SIM_DV_OBJS): Define.
3515         (hw-base_h, hw-device_h, hw-handles_h, hw-instances_h, hw_ports_h,
3516         hw-properties_h, hw-tree_h): Define, point at corresponding
3517         header.
3518         (hw_base_headers): Define list of headers included by hw-base.h
3519         (hw-base.o, hw-device.o, hw-instances.o, hw-handles.o, hw-ports.o,
3520         hw-properties.o, hw-tree.o): Specify dependencies.
3521         (dv-core.o, dv-pal.o): Ditto.
3522
3523         * sim-hw.h: New file.
3524
3525         * hw-device.h, hw-device.c, hw-properties.h, hw-properties.c,
3526         hw-ports.h, hw-ports.c: New files. Copied from ../ppc/device.[ch].
3527         
3528         * hw-tree.h, hw-tree.c: New files. Copied from ../ppc/tree.[hc].
3529
3530         * hw-base.h, hw-base.c: new files.  Copied from
3531         ../ppc/device_table.[hc].
3532
3533         * dv-core.c, dv-pal.c: New files. Copied from
3534         ../ppc/hw_{core,pal}.c
3535         
3536         * sim-basics.h (struct hw): Declare.
3537         (enum port_direction, enum object_disposition): Declare.
3538
3539 Wed Mar 18 12:38:12 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3540
3541         * aclocal.m4 (SIM_AC_OPTION_HARDWARE): Set sim_hw_obj, sim_dv_obj,
3542         sim_dv_src in Makefile. Take list of devices as parameter to m4
3543         macro..
3544
3545         * configure: Regenerated to track ../common/aclocal.m4 changes.
3546
3547 Mon Mar 16 12:37:33 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3548
3549         * sim-trace.h, sim-trace.c (trace_prefix): Pass in sim_cia so that
3550         trace_prefix can abort cleanly.
3551
3552 Sat Mar 14 18:36:12 1998  Doug Evans  <devans@seba.cygnus.com>
3553
3554         * dv-sockser.c, dv-sockser.h: New files.
3555         * Make-common.in (dv-sockser.o): Add rule for.
3556         * aclocal.m4: Check for fcntl.h.
3557         * config.h: Add HAVE_FCNTL_H.
3558
3559         * sim-break.c (remove_breakpoint): Fix thinko.
3560
3561         * sim-hload.c (sim_load): Provide default value of SIM_HANDLES_LMA.
3562         Use SIM_HANDLES_LMA for lma_p arg to sim_load_file.
3563
3564 1998-03-13  Fred Fish  <fnf@cygnus.com>
3565
3566         * sim-base.h (struct sim_state_base): Add prog_syms and
3567         define macro STATE_PROG_SYMS.
3568         * sim-trace.c (trace_prefix): Add variables abfd, symsize,
3569         symbol_count, and asymbols.  Call bfd_get_symtab_upper_bound
3570         and bfd_canonicalize_symtab, to get symbol table on first use
3571         and preserve it via STATE_PROG_SYMS for future calls to
3572         bfd_find_nearest_line.
3573
3574 Wed Mar 11 14:02:47 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3575
3576         * sim-core.h, sim-core.c (sim_core_map_to_str): Delete.
3577
3578         * sim-core.c (sim_core_attach): Handle a generic number of maps -
3579         up to nr_maps, not just access_* maps.
3580
3581         * sim-profile.h (struct PROFILE_DATA): Track nr_maps different
3582         maps.
3583
3584         * sim-profile.c (profile_print_core): Make map unsigned.  Iterate
3585         over nr_maps not sim_core_nr_maps.
3586
3587         * sim-events.h, sim-events.c (sim_events_watch_core): Change
3588         core_map argument to unsigned.
3589         (struct _sim_core): Ditto for struct member core_map.
3590
3591         * sim-core.h (nr_sim_core_maps, sim_core_*_map): Delete
3592
3593         * sim-basics.h (access_io, access_*_io): Define.
3594         (map_read, map_write, map_exec, map_io): Define.
3595
3596         * sim-core.c, sim-core.h (sim_core_attach): Replace argument
3597         attach with more generic mapmask.
3598         (sim_core_{read,write}_*): Change map argument to unsigned.
3599         
3600         * sim-core.c (sim_core_uninstall, sim_core_attach,
3601         sim_core_detach): Iterate over nr_maps instead of
3602         sim_core_nr_maps.
3603
3604         * sim-break.c (insert_breakpoint): Write breakpoints to exec_map
3605         instead of the write_map.
3606         (remove_breakpoint): Ditto.
3607
3608         * genmloop.sh (engine_resume_full): Replace sim_core_*_map
3609         with read_map, write_map, exec_map resp.
3610
3611         * cgen-mem.h (DECLARE_GETMEM, DECLARE_SETMEM, DECLARE_GETIMEM):
3612         Ditto.
3613
3614         * cgen-utils.c (sim_disassemble_insn): Ditto.
3615
3616         * sim-hrw.c (sim_write, sim_write): Ditto.
3617
3618         * sim-utils.h, sim-utils.c (access_to_str, map_to_str,
3619         transfer_to_str): New functions.
3620
3621 Mon Mar  9 12:50:59 1998  Doug Evans  <devans@seba.cygnus.com>
3622
3623         * sim-base.h (sim_state_base): New member environment.
3624         (STATE_ENVIRONMENT): New macro.
3625         * sim-config.c (current_environment): Delete.
3626         (sim_config_default): New function.
3627         (sim_config): Set STATE_ENVIRONMENT, not current_environment.
3628         * sim-config.h (current_environment,CURRENT_ENVIRONMENT): Delete.
3629         (sim_config_default): Add prototype.
3630         * sim-module.c (sim_pre_argv_init): Call sim_config_default.
3631         * sim-options.c (standard_option_handler, case OPTION_ENVIRONMENT):
3632         Set STATE_ENVIRONMENT, not current_environment.
3633
3634 Mon Mar  9 11:59:03 1998  Jim Wilson  <wilson@cygnus.com>
3635
3636         * sim-fpu.c (NR_GUARDS64): Change NR_PAD32 to NR_PAD64.
3637
3638 Tue Mar  3 10:53:05 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3639
3640         * sim-types.h (SIGNED32, SIGNED64): Pacify GCC.
3641
3642         * sim-alu.h (ALU64_BEGIN): Make alu64_r unsigned.
3643
3644 Mon Mar  2 10:20:06 1998  Doug Evans  <devans@seba.cygnus.com>
3645
3646         * Make-common.in (TAGS): Make smarter.
3647         * Makefile.in (TAGS): Ditto.
3648
3649 Fri Feb 27 19:09:57 1998  Doug Evans  <devans@canuck.cygnus.com>
3650
3651         * sim-module.c (*): Fix typos in assertion tests.
3652
3653 Sat Feb 28 13:54:10 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3654
3655         * sim-module.c (sim_pre_argv_init): String passed to asprintf
3656         can't be constant.
3657         
3658         * sim-options.c (sim_parse_args): Ditto.
3659         (sim_args_command): Return OK, instead of nothing, for an empty
3660         command.
3661
3662 Fri Feb 27 13:29:13 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3663
3664         * sim-profile.c (profile_info): Rename from profile_print. Drop
3665         misc and misc_cpu callback arguments.  Use
3666         PROFILE_INFO_CPU_CALLBACK and STATE_PROFILE_INFO_CALLBACK instead.
3667         (profile_install): Install profile_info function.
3668
3669         * sim-profile.h (PROFILE_INFO_CPU_CALLBACK,
3670         STATE_PROFILE_INFO_CALLBACK): Define.
3671         (struct PROFILE_DATA): Add field info_cpu_callback.
3672         (profile_print): Delete function.
3673
3674         * sim-base.h (STATE_MODULES): Define.  Replace individual
3675         STATE_*_LIST with single struct module_list.
3676
3677         * sim-module.h (MODULE_INFO_FN, MODULE_INFO_LIST): Declare.
3678         (struct module_list): Declare.
3679         
3680         * sim-module.h, sim-module.c (sim_module_add_info_fn,
3681         sim_module_info): New functions.
3682         (sim_module_install): Clean up module data structures.
3683
3684         * sim-info.c (sim_info): New file. New function. Call
3685         sim_module_info.
3686
3687         * Make-common.in (sim-info.o): Define rule.
3688         (SIM_NEW_COMMON_OBJS): Add sim-info.o.
3689
3690
3691 Fri Feb 27 18:26:16 1998  Doug Evans  <devans@canuck.cygnus.com>
3692
3693         * sim-base.h (sim_cpu_base): New members name, options.
3694         (sim_cpu_lookup): Add prototype.
3695         * sim-module.c (sim_pre_argv_init): Provide default names for cpus.
3696         * sim-options.h (DECLARE_OPTION_HANDLER): New argument `cpu'.
3697         (sim_add_option_table): Update prototype.
3698         * sim-options.c (sim_add_option_table): New argument `cpu'.
3699         (standard_option_handler,standard_install): Update.
3700         (sim_parse_args): Handle cpu specific options.
3701         (print_help): New static function.
3702         (sim_print_help): Call it.  Print cpu specific options.
3703         (find_match): New static function.
3704         (sim_args_command): Call it.  Handle cpu specific options.
3705         * sim-utils.c (sim_cpu_lookup): New function.
3706         * sim-memopt.c (memory_option_handler): Update.
3707         (sim_memopt_install): Update.
3708         * sim-model.c (model_option_handler): Update.
3709         (model_install): Update.
3710         * sim-profile.c (profile_option_handler): Update.
3711         (profile_install): Update.
3712         * sim-trace.c (trace_option_handler): Update.
3713         (trace_install): Update.
3714         * sim-watch.c (watchpoint_option_handler): Update.
3715         (sim_watchpoint_install): Update.
3716         * cgen-scache.c (scache_option_handler): Update.
3717         (scache_install): Update.
3718
3719 Wed Feb 25 11:00:26 1998  Doug Evans  <devans@canuck.cygnus.com>
3720
3721         * Make-common.in (check): Run `make check' in testsuite dir.
3722
3723 Wed Feb 25 14:40:24 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3724
3725         * sim-trace.c (trace_result0): New function.
3726
3727         * sim-trace.h (TRACE_FP_*, TRACE_FPU_*): Rename TRACE_FPU_*
3728         macro's to TRACE_FP_*. TRACE_FPU_* should be defined and used when
3729         tracing sim_fpu variables.
3730         (TRACE_ALU_RESULT0): Define.
3731         (TRACE_FP_RESULT_WORD): Define.
3732         (TRACE_FP_INPUT_WORD1): Define.
3733
3734         * sim-fpu.c, sim-fpu.h (sim_fpu_max32, sim_fpu_max64, sim_fpu_one,
3735         sim_fpu_two): New constants.
3736         (sim_fpu_op1, sim_fpu_op2): New types.
3737         (struct _sim_fpu): Delete member result.  Re-order other members.
3738         (sim_fpu_sign, sim_fpu_exp): New functions.
3739         (sim_fpu_max, sim_fpu_min): new functions.
3740         (EXPMAX32, EXPMAX64, NR_PAD32, NR_PAD64, NR_GUARDS32, NR_GUARDS64,
3741         NORMAL_EXPMAX32, NORMAL_EXPMAX64): Define.
3742         
3743 Tue Feb 24 22:45:39 1998  Doug Evans  <devans@seba.cygnus.com>
3744
3745         * sim-profile.c (profile_print): Delete duplicate test of
3746         PROFILE_INSN_IDX.
3747         (profile_print_pc): Exit early if data collection not set up.
3748         (profile_print_core): Simplify by calling sim_core_map_to_str.
3749         * sim-core.h (sim_core_map_to_str): Declare.
3750         * sim-core.c (sim_core_map_to_str): Make non-static.
3751
3752         * genmloop.sh (engine_resume): Update insn_count before exiting.
3753         (engine_resume_full): Keep accurate core profile data.
3754
3755         * cgen-utils.c (sim_disassemble_insn): Don't use
3756         sim_core_read_aligned_N, it messes up profiling results.
3757
3758 Mon Feb 23 20:45:57 1998  Mark Alexander  <marka@cygnus.com>
3759
3760         * nltvals.def: Regenerate with MN10300 additions.
3761
3762 Tue Feb 24 13:18:42 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3763
3764         * sim-trace.h (TRACE_ALU_RESULT2): Define.
3765         
3766         * sim-trace.h, sim-trace.c (trace_result_word2,
3767         trace_input_word4, trace_result_word4): New function.
3768
3769 Mon Feb 23 13:08:35 1998  Doug Evans  <devans@canuck.cygnus.com>
3770
3771         * cgen-sim.h (SEM_NEXT_PC): New arg `len'.
3772
3773         * sim-xcat.h: Delete.
3774         * cgen-mem.h: Delete inclusion of sim-xcat.h.
3775         * cgen-sim.h: Ditto.
3776         * sim-alu.h: Replace sim-xcat.h with symcat.h.
3777         * sim-n-bits.h: Ditto.
3778         * sim-n-core.h: Ditto.
3779         * sim-n-endian.h: Ditto.
3780
3781 Mon Feb 23 13:19:58 1998  Michael Meissner  <meissner@cygnus.com>
3782
3783         * syscall.c (cb_syscall): Handle short reads, and EOF.
3784
3785 Tue Feb 24 00:29:57 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3786
3787         * sim-trace.c (print_data): case trace_fmt_fp missing break.  Use
3788         sim_fpu to safely print fp_word values.
3789         (print_data): Add trace_fmt_bool and trace_fmt_addr.
3790         (trace_result_bool1, trace_result_addr1): New functions.
3791         (trace_input_bool1, trace_input_addr1): New functions.
3792
3793         * sim-trace.h (TRACE_FPU_*): Define.
3794
3795 Mon Feb 23 13:24:54 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3796
3797         * sim-fpu.h (enum sim_fpu_class): Add sim_fpu_class_denorm.
3798         (sim_fpu_fpto, sim_fpu_tofp): Define.
3799
3800 Fri Feb 20 18:08:51 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3801
3802         * sim-fpu.c (sim_fpu_cmp): New function.
3803
3804 Wed Feb 18 16:29:21 1998  Doug Evans  <devans@canuck.cygnus.com>
3805
3806         * cgen-utils.h (sim_disassemble_insn): Use CGEN_INSN_BITSIZE
3807         instead of abuf->length.
3808         * sim-trace.c (trace_options): Have -t only trace a few useful things.
3809         (set_trace_option_mask): Renamed from set_trace_options.
3810         (set_trace_option): New function.
3811         (trace_option_handler): Update calls to set_trace_option{,_mask}.
3812         * sim-trace.h (TRACE_USEFUL_MASK): New macro.
3813
3814 Wed Feb 18 12:42:15 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3815
3816         * sim-basics.h: Declare struct _sim_fpu.
3817
3818 Tue Feb 17 16:27:46 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3819
3820         * sim-trace.h (TRACE_ALU_INPUT*, TRACE_ALU_RESULT): Define.
3821         (trace_prefix, trace_input*, trace_result*): Declare.
3822         (trace_one_insn): Change declaration, assume trace_prefix called.
3823         (trace_generic): Like trace_one_insn.
3824         (TRACE_ALU_IDX, TRACE_*_IDX): Change #define's to enum.
3825         (TRACE_alu, TRACE_[a-z]*): Update.
3826         
3827         * sim-trace.c (trace_prefix, trace_input*, trace_result*,
3828         trace_insn, save_data, trace_idx_to_str, print_data): New
3829         functions.
3830         (trace_one_insn): Rewrite.
3831         (trace_generic): New function.
3832         
3833 Tue Feb 17 17:27:30 1998  Doug Evans  <devans@seba.cygnus.com>
3834
3835         * aclocal.m4 (USE_MAINTAINER_MODE): New variable.
3836
3837         * cgen-sim.h (SEMANTIC_CACHE_FN): Delete.
3838         (SEMANTIC_FN): Rewrite declaration.
3839         (DECODE): Update type of semantic_fast member.
3840         ({EX,SEM}_FN_NAME): Have only one version.
3841         * sim-base.h (sim_state_base): Delete conditionals surrounding
3842         member scache_size.
3843
3844 Tue Feb 10 18:31:49 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3845
3846         * sim-load.c (sim_load_file): Print LMA/VMA according to value
3847         used.
3848
3849 Tue Feb 10 14:56:23 1998  Ian Carmichael  <iancarm@cygnus.com>
3850
3851         * sim-core.c: Add missing prototypes for WITH_DEVICES.
3852         Add missing parameters to device_io calls.
3853         * sim-core.h: Add missing parameters to device_io calls.
3854
3855 Mon Feb  9 14:48:37 1998  Doug Evans  <devans@canuck.cygnus.com>
3856
3857         * cgen-sim.h (DECODE): Always use switch for `read' for now.
3858         (PAREXEC): Renamed from PARALLEL_EXEC.  All uses updated.
3859         (SEMANTIC{,_CACHE}_FN): Fix return type.
3860         * genmloop.sh (@cpu@_engine_run): Delete `current_state'.
3861         (engine_resume): Likewise.  Make `engine' volatile.  Save copy
3862         of cpu pointer in volatile object.  Initialize read switch if
3863         -parallel.
3864
3865 Thu Feb  5 13:27:04 1998  Doug Evans  <devans@seba.cygnus.com>
3866
3867         * cgen-sim.h (EX_FN_NAME): _exc_ -> _ex_.
3868         (SEM_INSN): New macro.
3869
3870 Tue Feb  3 16:31:56 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3871
3872         * sim-run.c (sim_engine_run): Assume IMEM is 32 bit.
3873
3874 Sun Feb  1 16:47:51 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3875
3876         * configure: Regenerated to track ../common/aclocal.m4 changes.
3877
3878 Sun Feb  1 16:16:57 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3879
3880         * sim-types.h (fp_word): New type, define according to
3881         WITH_TARGET_FLOATING_POINT_BITSIZE.
3882
3883         * aclocal.m4 (default_sim_floating_point_bitsize): Add
3884         configuration of size of floating point registers.
3885
3886 Sun Feb  1 14:02:31 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3887
3888         * sim-profile.c (profile_print): Only print CPU <N> if other
3889         output is going to appear.
3890
3891 Sat Jan 31 18:15:41 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3892
3893         * configure: Regenerated to track ../common/aclocal.m4 changes.
3894
3895 Sat Jan 31 18:03:55 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3896
3897         * sim-types.h (address_word): Typedef according to
3898         WITH_TARGET_ADDRESS_BITSIZE.
3899         (signed_cell, unsigned_cell, natural_cell): Ditto using
3900         WITH_TARGET_CELL_BITSIZE.
3901         
3902         * sim-config.h (WITH_TARGET_ADDRESS_BITSIZE): Define.
3903         (WITH_TARGET_CELL_BITSIZE): Define.
3904         (WITH_HOST_WORD_BITSIZE): Delete.
3905
3906         * sim-config.c (print_sim_config): Update.
3907
3908         * aclocal.m4 (SIM_AC_OPTION_BITSIZE): Add support for
3909         configuration of address and OpenFirmware cell sizes.
3910
3911 Fri Jan 30 09:36:33 1998  Andrew Cagney  <cagney@b1.cygnus.com>
3912
3913         * sim-engine.h (sim_engine_run): Add argument nr_cpus.
3914         * sim-run.c (sim_engine_run): Update.
3915         
3916         * sim-engine.h (SIM_ENGINE_HALT_HOOK): Use SET_CPU_CIA instead of
3917         CPU_CIA.
3918         * sim-run.c (sim_engine_run): Ditto.
3919
3920         * sim-resume.c (sim_resume): Obtain nr_cpus from sim_engine.
3921         (sim_resume): Pass nr_cpus to sim_engine_run.
3922
3923         * sim-engine.h (struct _sim_engine): Add member nr_cpus.
3924         
3925         * sim-engine.c (sim_engine_init): Hardwire nr_cpus to
3926         MAX_NR_PROCESSORS.
3927         (sim_engine_nr_cpus) sim-engine.c, sim-engine.h: New function
3928         
3929 Fri Jan 23 14:20:54 1998  Doug Evans  <devans@seba.cygnus.com>
3930
3931         * Make-common.in (stamp-tvals): New rule.
3932         (targ-vals.h,targ-map.c): Depend on it.
3933         (clean): Remove stamp-tvals.
3934
3935 Tue Jan 20 21:35:13 1998  Michael Meissner  <meissner@cygnus.com>
3936
3937         * sim-utils.c (sim_state_alloc): #if 0 variable that is only used
3938         in code also #if 0'ed.
3939
3940 Mon Jan 19 22:26:29 1998  Doug Evans  <devans@seba>
3941
3942         * configure: Regenerated to track ../common/aclocal.m4 changes.
3943         * aclocal.m4: Recognize --enable-maintainer-mode.
3944
3945 Mon Jan 19 12:45:45 1998  Doug Evans  <devans@seba.cygnus.com>
3946
3947         * cgen-scache.h: Deleted.
3948         * Make-common.in (cgen-run.o,cgen-scache.o): Delete cgen-scache.h dep.
3949         * cgen-scache.c: Only compile contents if WITH_SCACHE.
3950         (scache_init): Use runtime computed size of SCACHE.
3951         (scache_flush): Likewise.
3952         * cgen-mem.h (GETIMEMU[QHSD]I): Declare.
3953         ([GS]ETT{QI,UQI,HI,UHI,SI,USI,DI,UDI}): Declare.
3954         * cgen-sim.h: Scache support moved here.
3955         (PC): Redo definition.
3956         (ARGBUF,SCACHE,PARALLEL_EXEC): Provide forward decls.
3957         (DECODE): Add parallel execution support.
3958         Only include semantic label members if using switch.
3959         (SWITCH,CASE,BREAK,DEFAULT,ENDSWITCH): Portable computed goto support.
3960         (CGEN_CPU): Delete members exec_state, halt_sigrc, halt_jmp_buf.
3961         (IADDR,CIA,SEM_ARG,EX_FN_NAME,SEM_FN_NAME,RECORD_IADDR,SEM_ARGBUF,
3962         SEM_NEXT_PC,SEM_BRANCH_VIA_{CACHE,ADDR},SEM_NEW_PC_ADDR): Moved here
3963         from cgen-types.h.
3964         (engine_{stop,run,resume,halt,signal}): Delete decls.
3965         * cgen-types.h (CGEN_{XCAT3,CAT3}): Delete.
3966         (argbuf,scache): Delete forward decls.
3967         (STATE): Delete decl.
3968         * cgen-utils.c: Don't include decode.h, mem-ops.h, sem-ops.h.
3969         Include cgen-mem.h, cgen-ops.h.
3970         (engine_halt,engine_signal): Delete.
3971         ({ex,exc,sem,semc}_illegal): Delete.
3972         (sim_disassemble_insn): Result of extract fn is in bits.
3973         * genmloop.sh: Rewrite.
3974
3975         * cgen-trace.c (trace_insn): Set printed_result_p=0 if not tracing
3976         line numbers.
3977
3978         * sim-base.h (sim_state_base): Delete member `model'.
3979         (sim_cpu_base): Add member `model'.
3980         * sim-model.h (IMP_PROPERTIES): New type.
3981         (MACH): New members imp_props, models.
3982         (models): Delete decl.
3983         * sim-model.c (set_model): Update.
3984         * sim-profile.c (profile_print_model): Update.
3985
3986         * sim-utils.c (sim_state_alloc): Delete setting of cpu backlink here.
3987
3988 Fri Jan 16 12:33:09 1998  Nick Clifton  <nickc@cygnus.com>
3989
3990         * cgen-trace.c (trace_insn): Call CGEN_INSN_MNEMONIC() rather than
3991         CGEN_INSN_SYNTAX().
3992
3993 Mon Dec 15 23:17:11 1997  Andrew Cagney  <cagney@b1.cygnus.com>
3994
3995         * configure: Regenerated to track ../common/aclocal.m4 changes.
3996         * config.in: Ditto.
3997
3998 Mon Dec 15 23:16:03 1997  Andrew Cagney  <cagney@b1.cygnus.com>
3999
4000         * aclocal.m4 (AR): Check for sigaction.
4001
4002 Thu Dec  4 09:21:05 1997  Doug Evans  <devans@canuck.cygnus.com>
4003
4004         * Make-common.in (sim-core.o): Depend on $(sim_main_headers).
4005
4006         * sim-config.h (WITH_TREE_PROPERTIES): Define as 0.
4007         * sim-config.c (sim_config): Replace WITH_DEVICES with
4008         WITH_TREE_PROPERTIES.
4009
4010         * configure: Regenerated to track ../common/aclocal.m4 changes.
4011
4012 Wed Dec  3 17:56:02 1997  Doug Evans  <devans@canuck.cygnus.com>
4013
4014         * Make-common.in (SIM_ENVIRONMENT): New variable.
4015         (CONFIG_CFLAGS): Add it.
4016         * aclocal.m4 (SIM_AC_OPTION_ENVIRONMENT): Handle
4017         --enable-sim-environment option.
4018         * configure: Regenerated.
4019         * sim-config.h (environment support): Rewrite.
4020         * sim-config.c (current_environment): Define as enum, unconditionally.
4021         (current_alignment): Define unconditionally.
4022         (config_environment_to_a): Update.
4023         (config_alignment_to_a): Fix type of argument.  Define unconditionally.
4024         (sim_config): Handle environment and alignment determination
4025         unconditionally.  Delete sanity checks of current_environment,
4026         unnecessary.
4027         (print_sim_config): Update.
4028         * sim-options.c (STANDARD_OPTIONS enum): Add OPTION_ENVIRONMENT.
4029         (standard_options): Add --environment.
4030         (standard_option_handler): Likewise.
4031
4032 Fri Nov 28 12:21:25 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4033
4034         * sim-alu.h: Add notes on carry vs borrow for subtraction.
4035         (ALU{,8,16,32,64}ADD): Redefine ADD macro as add overflowing.
4036         (ALU{,8,16,32,64}ADDC): Define - add carrying.
4037         (ALU{,8,16,32,64}SUB): Redefine SUB macro as subtract overflowing.
4038         (ALU{,8,16,32,64}SUBB): Define - subtract borrowing.
4039         (ALU{,8,16,32,64}SUBC): Define - tract carrying.
4040         (ALU{,8,16,32,64}ADD_CA, ALU{,8,16,32,64}ADDC_C): Replace single
4041         argument ADD_CA macro with two argument ADDC_C - add carrying with
4042         carry in.
4043         (ALU{,8,16,32,64}SUB_CA, ALU{,8,16,32,64}SUBC_X): Replace single
4044         argument SUB_CA macro with two argument SUBC_X - subtract
4045         carrying, extended.
4046         (ALU{,8,16,32,64}SUBB_B): Define - subtract borrowing with
4047         borrow-in.
4048         (ALU{,8,16,32,64}NEGC, ALU{,8,16,32,64}NEGB): Define.
4049
4050 Sun Nov 30 17:40:57 1997  Michael Meissner  <meissner@cygnus.com>
4051
4052         * sim-io.c (sim_io_{syscalls,getstring}): Delete.  No longer used.
4053         * sim-io.h (sim_io_syscalls): Delete.
4054
4055 Fri Nov 28 20:10:09 1997  Michael Meissner  <meissner@cygnus.com>
4056
4057         * syscall.c (cb_syscall): Add missing else, so write to stdout
4058         isn't doubled.
4059
4060         * sim-alu.h (ALU{,8,16,32,64}_SET_CARRY): Provide macros to import
4061         the carry bit from the CPU's psw.
4062
4063 Fri Nov 28 11:15:05 1997  Doug Evans  <devans@canuck.cygnus.com>
4064
4065         * gennltvals.sh: Redo syscall support.
4066         * nltvals.def: Regenerated.
4067
4068 Wed Nov 26 16:49:38 1997  Michael Meissner  <meissner@cygnus.com>
4069
4070         * syscall.c (cb_syscall): If writing to stdout or stderr, flush
4071         the stream immediately.
4072
4073 Wed Nov 26 12:32:11 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4074
4075         * sim-io.c (sim_io_getstring): Delete unused len2.
4076         (sim_io_syscalls): Ditto for sys_errno.
4077
4078 Wed Nov 26 11:18:40 1997  Doug Evans  <devans@canuck.cygnus.com>
4079
4080         * syscall.c (cb_syscall): Test CB_SYSCALL struct magic number.
4081
4082         * Make-common.in (run.o): Depend on remote-sim.h.
4083         (nrun.o,sim-hload.o,sim-hrw.o): Likewise.
4084         (sim-io.o,sim-reason.o,sim-resume.o): Likewise.
4085
4086 Tue Nov 25 20:12:46 1997  Michael Meissner  <meissner@cygnus.com>
4087
4088         * sim-io.c (sim_io_syscalls): Disable lseek.
4089
4090 Tue Nov 25 00:12:38 1997  Doug Evans  <devans@seba.cygnus.com>
4091
4092         * gennltvals.sh: Generate syscall values for d30v.
4093
4094         * gennltvals.sh: Use libgloss/syscall.h for sparc.
4095         * nltvals.def: Regenerate.
4096
4097         * callback.c (os_stat): Make 3rd arg a host struct stat ptr.
4098         (os_fstat): Likewise.  Validate fd argument.
4099         (cb_host_to_target_stat): Delete big_p arg.  If HS arg is NULL,
4100         just compute target stat struct length.
4101         * syscall.c: #include "libiberty.h", <sys/types.h>, <sys/stat.h>.
4102         (ENOSYS,ENAMETOOLONG): Provide definitions if missing.
4103         (get_string): Return host errno values so they can be properly
4104         translated later.
4105         (cb_syscall): Likewise.
4106         (cb_syscall, cases open,unlink): Use get_path instead of get_string.
4107         (cb_syscall, case read): Use read_stdin for file descriptor 0.
4108         (cb_syscall, case write): Use write_stderr for file descriptor 2.
4109         (cb_syscall): Add cases for lseek, unlink, stat, fstat, time.
4110         (get_path): New function.
4111
4112 Mon Nov 24 18:56:07 1997  Michael Meissner  <meissner@cygnus.com>
4113
4114         * sim-io.c (sim_io_syscalls): New function to provide system call
4115         emulation.  Provide exit, open, close, read, write, lseek, and
4116         unlink.
4117         (sim_io_getstring): New function to return a string from a
4118         simulated memory location.
4119
4120         * sim-io.h (sim_io_syscalls): Add declaration.
4121
4122 Mon Nov 24 12:09:59 1997  Doug Evans  <devans@seba.cygnus.com>
4123
4124         * sim-core.c (sim_core_signal): Fix spelling error in message.
4125
4126         * sim-hrw.c (sim_read): Use read map, not write map.
4127
4128         * Make-common.in (all): Add .gdbinit.
4129         * gdbinit.in: Add dump command.
4130
4131         * sim-model.c (model_options): Use '\0' for `shortopt'.
4132
4133         * sim-trace.c (trace_option_handler): Set state trace file
4134         for --trace-file in addition to cpu's values.
4135         (trace_vprintf): If cpu == NULL, try state's trace file.
4136         (trace_options): Reorganize table, reword some descriptions.
4137
4138 Sun Nov 23 10:57:00 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4139
4140         * sim-fpu.c (sim_fpu_abs, sim_fpu_neg, sim_fpu_inv), sim-fpu.h:
4141         New functions.
4142
4143 Sat Nov 22 19:16:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4144
4145         * sim-reason.c (sim_stop_reason): For sim_signalled, return the
4146         signal untranslated, document problem with this.
4147
4148         * nrun.c (main): Check for a prog name of `*step'.  If present,
4149         step the simulator instead of allowing it to run free.
4150
4151         * sim-signal.c (SIGQUIT): Define on _MSC_VER hosts.
4152
4153         * Make-common.in (sim_main_headers): Add sim-signal.h.
4154
4155 Fri Nov 21 09:32:32 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4156
4157         * sim-signal.c (sim_signal_to_host): Return 0 for SIM_SIGNONE.
4158
4159 Thu Nov 20 20:35:20 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4160
4161         * sim-signal.h: Start simulator signals at 64 so that host signal
4162         numbers can be detected and reported.
4163
4164         * sim-signal.h (SIM_SIGFPE), sim-signal.h: Add signal.
4165
4166 Wed Nov 19 12:02:41 1997  Doug Evans  <devans@seba.cygnus.com>
4167
4168         * callback.c (cb_host_to_target_stat): Fix return values.
4169
4170         * cgen-sim.h (enum_signal_type): Delete.
4171         (engine_signal): Update prototype.
4172         * cgen-utils.c: Don't include <signal.h>.
4173         (sim_signal_to_host): Delete, lives in sim-signal.c now.
4174         (engine_signal): Update.
4175
4176         * sim-utils.c (sim_state_alloc): Call SIM_STATE_ALLOC if defined.
4177         (sim_state_free): Call SIM_STATE_FREE if defined.
4178
4179         * sim-module.c (sim_module_install): Don't leave any modules
4180         installed if one fails to install.
4181
4182 Wed Nov 19 13:25:48 1997  Michael Meissner  <meissner@cygnus.com>
4183
4184         * sim-options.c: Don't include ../libiberty/alloca-conf.h any
4185         more, since alloca is not used in this file.
4186
4187         * sim-alu.h (ALU{32,64}_*): Rewrite 32 and 64 bit ALU support to
4188         correctly set the carry and overflow bits for those types.
4189         (ALU{8,16,32,64}_{ADD,SUB}_CA): Take VAL argument to add along
4190         with carry, so carry is correct after doing both adds.
4191         (ALU*): Space out '\' to make it easier to read.
4192
4193 Tue Nov 18 15:53:45 1997  Doug Evans  <devans@canuck.cygnus.com>
4194
4195         * sim-core.c (sim_core_signal): Use sim_stopped instead of
4196         sim_signalled.
4197
4198         * sim-signal.c, sim-signal.h: New files.
4199         * Make-common.in (sim-signal.o): Add rule for.
4200         (SIM_NEW_COMMON_OBJS): Add sim-signal.o.
4201         * sim-abort.c: Don't include <signal.h>.
4202         * sim-basics.h: #include "sim-signal.h".
4203         * sim-break.c: Don't include <signal.h>.
4204         (sim_handle_breakpoint): Replace SIGTRAP with SIM_SIGTRAP.
4205         * sim-core.c: Don't include <signal.h>.
4206         (SIGBUS): Delete definition.
4207         (sim_core_signal): Replace SIGSEGV,SIGBUS with SIM_SIGSEGV,SIM_SIGBUS.
4208         * sim-engine.c: Don't include <signal.h>.
4209         (sim_engine_abort): Replace SIGABRT with SIM_SIGABRT.
4210         * sim-reason.c (sim_stop_reason): Call sim_signal_to_host.
4211         * sim-resume.c: Don't include <signal.h>.
4212         (SIGTRAP): Delete definition.
4213         (has_stepped): Replace SIGTRAP with SIM_SIGTRAP.
4214         * sim-stop.c: Don't include <signal.h>.
4215         (control_c_simulation): Replace SIGINT with SIM_SIGINT.
4216         * sim-watch.c: Don't include <signal.h>.
4217         (handle_watchpoint): Replace SIGINT with SIM_SIGINT.
4218
4219         * Make-common.in (SIM_NEW_COMMON_OBJS): New variable.
4220
4221         * sim-base.h (CIA_ADDR): Provide default definition.
4222         * sim-core.c (sim_core_signal): Use CIA_ADDR to fetch value.
4223         * sim-break.c (sim_handle_breakpoint): Likewise.
4224
4225 Mon Nov 17 14:15:31 1997  Doug Evans  <devans@seba.cygnus.com>
4226
4227         * Make-common.in (srccom): New variable.
4228
4229         * Make-common.in (DEP, COMMON_DEP_CFLAGS): Define.
4230         (LIB_OBJS): Add syscall.o.
4231         (gentmap): Pass $(NL_TARGET) to $(CC).
4232         (syscall.o): Add rule for.
4233         (sim_main_headers): Add $(SIM_EXTRA_DEPS).
4234         (sim-bits.o): Depend on $(sim-n-bits_h).
4235         (sim-load.o): Depend on callback.h.
4236
4237         * Make-common.in (cgen-*.o): Update dependencies, mem-ops.h renamed to
4238         cgen-mem.h, sem-ops.h renamed to cgen-ops.h.
4239         * cgen-mem.h, cgen-ops.h: New files.
4240
4241         * aclocal.m4 (--enable-sim-scache): Pass -DWITH_SCACHE=0 for "=no".
4242
4243         * Makefile.in (nltvals.def): Depend on gennltvals.sh.
4244         Rewrite build rule.
4245         * callback.c: #include string.h or strings.h.
4246         #include sys/types.h and sys/stat.h.
4247         (cb_init_syscall_map,cb_init_errno_map,cb_init_open_map): Declare.
4248         (os_get_errno,os_open): Update.
4249         (os_stat,os_fstat): New functions.
4250         (os_init): Initialize syscall_map, errno_map, open_map.
4251         (default_callback): Add entries for os_stat, os_fstat, syscall_map,
4252         errno_map, open_map, signal_map, stat_map.
4253         (cb_read_target_syscall_maps): New function.
4254         (cb_target_to_host_syscall): New function.
4255         (cb_host_to_target_errno): Renamed from host_to_target_errno.
4256         (cb_target_to_host_open): Renamed from target_to_host_open.
4257         (store): New function.
4258         (cb_host_to_target_stat): New function.
4259         * syscall.c: New file.
4260         * gentmap.c (sys_tdefs): New global.
4261         (gen_targ_vals_h): Output target syscall numbers.
4262         (gen_targ_map_c): Update.  Output target syscall translation map.
4263         * gentvals.sh: New first argument `target'.  Preface table with
4264         #ifdef NL_TARGET_$target if non-null target passed.
4265         * gennltvals.sh: New file.
4266         * nltvals.def: Regenerated.
4267
4268 Fri Nov 14 11:33:34 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4269
4270         * sim-n-core.h (sim_core_read_unaligned_N): Return static
4271         sim_core_dummy_M.
4272         (sim_core_dummy_M): Declare.
4273         
4274 Wed Nov 12 18:16:15 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4275
4276         * sim-core.c (sim_core_signal): Print the address of the
4277         instruction.
4278
4279 Thu Nov 13 11:49:41 1997  Doug Evans  <devans@seba.cygnus.com>
4280
4281         * sim-base.h (sim_state_base): Move `magic' to end of struct.
4282
4283         * sim-base.h (sim_state_base): Add member trace_data.
4284         (STATE_TRACE_DATA): New macro.
4285         * sim-trace.h (TRACE_DEBUG_IDX,TRACE_debug): New macros.
4286         ({WITH_,}TRACE_DEBUG_P): New macros.
4287         (STATE_TRACE_FLAGS,STRACE_P,STRACE_DEBUG_P): New macros.
4288         (_sim_cpu): Delete forward reference.
4289         (debug_printf): Update.
4290         * sim-trace.c (OPTION_TRACE_DEBUG): Define.
4291         (trace_options): Add --trace-debug.
4292         (set_trace_options): Handle it.
4293         (trace_option_handler): Likewise.
4294         (trace_install): Init state trace_data struct.
4295         (trace_uninstall): Close state trace file.
4296         * sim-events.c (ETRACE): Only print source file and line number if
4297         --trace-debug.
4298         * sim-n-core.h (sim_core_trace_M): Likewise.
4299
4300         * sim-core.c (sim_core_signal): Add missing "\n" in message.
4301
4302 1997-11-13  Felix Lee  <flee@cygnus.com>
4303
4304         * sim-n-core.h (sim_core_read_unaligned_N): illegal empty
4305         initializer.
4306         * sim-types.h (unsigned128,signed128): fix typo for MSVC.
4307
4308 Wed Nov 12 12:18:08 1997  Doug Evans  <devans@canuck.cygnus.com>
4309
4310         * aclocal.m4 (SIM_AC_OPTION_SCACHE): Fix typo.
4311
4312         * Make-common.in (BUILT_SRC_FROM_COMMON): Remove files no longer
4313         built this way.
4314         (sim-config.o): Remove non-existent $(sim-nconfig_h) dependency.
4315         (clean): Don't delete $(BUILT_SRC_FROM_COMMON) if building in
4316         source tree.
4317
4318 Tue Nov 11 13:28:02 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4319
4320         * sim-events.c (sim_events_process): Re-compute the time -
4321         update_time_from_event - as each event is processed. Reverses
4322         previous change.
4323
4324 Fri Nov  7 00:37:36 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4325
4326         * callback.c (os_poll_quit): Replace _WIN32 with _MSC_VER.
4327
4328 Fri Nov  7 00:37:36 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4329
4330         * sim-events.c (sim_events_process): Delete redundant call to
4331         update_time_from_event.
4332         (sim_events_slip): Always decrement time_from_event.
4333         (sim_events_tick, sim_events_deschedule, update_time_from_event):
4334         Delete assertion that time_from_event >=0 when work in queue, no
4335         longer applicable.
4336
4337 Thu Nov  6 12:06:46 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4338
4339         * sim-options.c (STANDARD_OPTIONS): Change OPTION_* to an enum.
4340         (standard_option_handler): Update.
4341
4342         * sim-options.h: Clarify documentation.
4343         (OPTION_LONG_ONLY_P): Delete definition.
4344         (OPTION_VALID_P): Define.
4345         
4346         * sim-options.c (sim_print_help): Allow short only options.
4347         (sim_parse_args): Ditto.
4348         (sim_args_command): Skip short only options.
4349         (sim_parse_args): Allocate space for NUM_OPTS not just 256. Make
4350         separate entries for short and long options in the HANDLERS and
4351         ORIG_VAL tables.
4352         (sim_parse_args): Disable argument permutation.
4353
4354 Wed Nov  5 13:40:31 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4355
4356         * sim-core.h (DECLARE_SIM_CORE_WRITE_N. DECLARE_SIM_CORE_READ_N):
4357         Add argument M, size of data type.
4358         (sim_core_read_misaligned_3, sim_core_write_misaligned_3):
4359         Declare, ditto for 5, 6 & 7 byte transfers.
4360         (sim_core_write_unaligned_1, sim_core_write_unaligned_1): Define
4361         as aligned variant.
4362         
4363         * sim-n-core.h (sim_core_trace_M): Rename from
4364         sim_core_trace_N. Add nr_bytes argument. Replace transfer argument
4365         with transfer type. Print transfer direction.  Handle 1 and 2 byte
4366         transfers.
4367         (sim_core_read_unaligned_N, sim_core_write_unaligned_N): Trace
4368         unaligned accesses.
4369         (unsigned_M, T2H_M, H2T_M): Rename from unsigned_N, T2H_N, H2T_N.
4370         Update all functions.
4371
4372         * sim-core.c: Generate functions starting with 16 not 1.
4373         (sim_core_read_unaligned_3): Generate. Ditto for 3 byte write and
4374         all 5, 6 & 7 byte transfers.
4375
4376         * sim-n-core.h (sim_core_read_misaligned_N,
4377         sim_core_write_misaligned_N): Implement.
4378
4379 Mon Nov  3 15:03:04 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4380
4381         * sim-endian.h (U16_8): Implement
4382
4383         * sim-endian.c (sim_endian_split_16, sim_endian_join_16): New functions
4384
4385         * sim-endian.h (VL8_16, VH8_16): Implement.
4386
4387         * sim-memopt.c (memory_option_handler): Typecast 64bit value to
4388         long in printf.
4389         (memory_option_handler): Only zalloc modulo bytes when non-zero.
4390         (memory_option_handler): Skip comma in alias address list
4391
4392 Fri Oct 31 13:03:33 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4393
4394         * sim-memopt.c (do_memopt_add, do_memopt_delete): Add level and
4395         space params.
4396         (parse_size, parse_addr): New functions
4397         (memory_option_handler, memory_options): Parse address & size
4398         using new functions. Pass level, space, modulo to do_memopt_add &
4399         do_memopt_del.
4400
4401         * sim-memopt.h (struct _sim_memopt): Add level & space fields.
4402
4403         * sim-core.h (sim_core_arrach, sim_core_detach): Replace
4404         `attach_type attach' argument with `unsigned level' argument.
4405         Document.
4406
4407         * sim-core.c (new_sim_core_mapping, sim_core_map_attach,
4408         sim_core_attach): Replace argument attach with level.  Update
4409         verification of arguments.
4410         (sim_core_map_detach, sim_core_detach): Replace argument attach
4411         with level.
4412
4413         * sim-basics.h (enum _attach_type): Delete.
4414
4415 Thu Oct 30 13:45:00 1997  Doug Evans  <devans@seba.cygnus.com>
4416
4417         * sim-core.h (sim_core_write_8): Define.
4418
4419 Tue Oct 28 12:29:22 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4420
4421         * sim-bits.h: Document ROTn macro.
4422
4423         * sim-endian.h (H2T): Handle 16 byte variables.
4424
4425         * sim-n-core.h (sim_core_read_unaligned_N): Return a dummy when an
4426         error.
4427
4428         * sim-core.c: Do not generate sim_core_*_word.
4429
4430         * sim-n-core.h (sim_core_trace_N): Add line_nr argument.
4431         (sim_core_write_aligned_N, sim_core_read_aligned_N): Update.
4432
4433         * sim-core.h (sim_core_read_unaligned_word,
4434         sim_core_read_aligned_word, sim_core_read_word,
4435         sim_core_write_unaligned_word, sim_core_write_aligned_word,
4436         sim_core_write_word): Change to macros that map onto sim_core_*_N.
4437
4438 Mon Oct 27 11:25:10 1997  Doug Evans  <devans@canuck.cygnus.com>
4439
4440         * sim-n-endian.h: Add TAGS entrys for 16 byte versions.
4441
4442         * sim-endian.h: Disable 16 byte support.
4443
4444 Mon Oct 27 12:00:48 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4445
4446         * sim-endian.c (_SWAP_16): Define.  Generate 126 bit swap code.
4447
4448         * sim-n-core.h (sim_core_trace_N): New function.
4449         (sim_core_read_aligned_N, sim_core_write_aligned_N): Use,
4450         (sim_core_read_unaligned_N): Do not retyrn bogus value wden error.
4451
4452         * sim-endian.h:  Add 128 bit variant.
4453
4454         * sim-core.h, sim-core.c: Add 128 bit variant.
4455
4456         * sim-types.h: Add signed128 and unsigned128 types using a struct.
4457
4458 Fri Oct 24 11:33:07 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4459
4460         * sim-events.c (sim_events_process): Clear events->work_pending.
4461         (sim_events_tickn, sim_events_tick): Accumulate, instead of
4462         setting, nr_ticks_to_process.
4463         (sim_events_preprocess): Allow nr_ticks_to_process to be non-zero
4464         when the event queue isn't next.
4465
4466         * sim-events.h, sim-events.c (sim_events_slip): New function.
4467
4468 Wed Oct 22 14:18:38 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4469
4470         * sim-hload.c (sim_load): Pass lma_p==0 and do_load=sim_load.
4471
4472         * sim-utils.h, sim-load.c (sim_load_file): Add lma_p and do_load
4473         arguments.
4474
4475 Tue Oct 21 18:37:57 1997  Doug Evans  <devans@canuck.cygnus.com>
4476
4477         * nrun.c (main): Remove useless test of name != NULL.
4478         Exit if bfd_openr fails.  Call bfd_check_format after bfd_openr.
4479
4480 Tue Oct 21 10:42:38 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4481
4482         * sim-fpu.c (EXPMAX): Type is unsigned.
4483         (MIN_INT, MAX_INT): Type is signed64.
4484         (i2fpu): Type of val is signed64.
4485
4486 Tue Oct 21 10:42:38 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4487
4488         * sim-profile.h (PROFILE_PC_BUCKET_SIZE): Treat a shift of zero as
4489         a bucket size of zero.
4490
4491         * sim-profile.c (OPTION_PROFILE_PC_GRANULARITY,
4492         OPTION_PROFILE_PC): Define.
4493         (profile_option_handler): Add support for --profile-pc and
4494         --profile-pc-granularity options.
4495         (profile_pc_init): When possible, compute nr buckets from bucket
4496         size.
4497
4498         * sim-profile.c (profile_pc_init): Align the profile-pc end
4499         address with the profile-pc bucket size.
4500
4501         * sim-profile.h (PROFILE_PC_NR_BUCKETS): Rename PROFILE_PC_SIZE to
4502         something less ambiguous.
4503         (PROFILE_PC_BUCKET_SIZE): Ditto for PROFILE_PC_SAMPLE_SIZE.
4504
4505         * sim-profile.c (profile_pc_cleanup): New function. Move
4506         profile_pc_uninstall code to here.
4507         (profile_pc_uninstall): Call.
4508         (profile_pc_init): Call.
4509
4510 Mon Oct 20 17:23:58 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4511
4512         * sim-profile.c (profile_print_pc): Dump pc profile to dmon.out
4513         file using BSD gprof format.
4514
4515         * sim-bits.h (LSBIT, MSBIT, BIT): Force result to type
4516         unsigned_word.
4517         (LSBIT8, LSBIT16, LSBIT32, LSBIT64, MSBIT8, MSBIT16, MSBIT32,
4518         MSBIT64): Force result to unsignedN.
4519
4520 Thu Oct 16 11:38:56 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4521
4522         * sim-alu.h (ALU16_BEGIN, ALU32_BEGIN, ALU64_BEGIN): Drop opening
4523         brace from macro.
4524         (ALU8_BEGIN, ALU8_SET, ALU8_ADD, ALU8_SUB, ALU8_NEGATE): Define.
4525         (ALU16_ADD, ALU16_SUB, ALU16_NEGATE): Simplify arrithmetic.
4526         (ALU32_ADD, ALU32_SUB, ALU32_NEGATE): Simplify arrithmetic.
4527         (ALU64_ADD, ALU64_SUB, ALU64_NEGATE): Simplify arrithmetic.
4528
4529 Wed Oct 15 09:24:19 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4530
4531         * sim-core.h (struct _sim_core_mapping): Change free_buffer to
4532         type void*.
4533
4534         * sim-core.c (sim_core_uninstall, new_sim_core_mapping,
4535         sim_core_map_attach, sim_core_map_detach): Change free_buffer to
4536         type void*.
4537         (sim_core_attach): Rename buffer_freed to free_buffer, type
4538         void*. Ensure that allocated buffer is alligned according to
4539         region's address.
4540
4541 Mon Oct 13 11:34:50 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4542
4543         * sim-alu.h (ALU64_HAD_OVERFLOW): Define.
4544         (ALU64_SUB): Define.
4545
4546         * Make-common.in (all): Build SIM_EXTRA_ALL first.
4547         (.gdbinit): Remove dependencies, generate once per build.
4548
4549 Tue Oct 14 19:20:09 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4550
4551         * sim-n-core.h (sim_core_read_aligned_N,
4552         sim_core_write_aligned_N): Make xaddr param type address_word not
4553         unsigned_word.
4554
4555 Fri Oct  3 09:49:18 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4556
4557         * sim-fpu.h, sim-fpu.c: Rewrite.  Change sim_fpu object to an
4558         unpacked floating point struct.  Pass sim_fpu object by reference.
4559         Add preliminary support for rounding modes.
4560         
4561 Fri Oct  3 09:28:00 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4562
4563         * configure: Regenerated to track ../common/aclocal.m4 changes.
4564
4565 Thu Oct  2 19:43:52 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4566
4567         * aclocal.m4 (sim-bitsize): Fix typo, WITH_TARGET_WORD_BITSIZE not
4568         WITH_TARGET_BITSIZE.
4569
4570 Thu Sep 25 23:20:20 1997  Felix Lee  <flee@yin.cygnus.com>
4571
4572         * sim-profile.c (profile_print_core): label needs empty statement.
4573
4574 Thu Sep 25 11:20:47 1997  Stu Grossman  <grossman@babylon-5.cygnus.com>
4575
4576         * sim-break.c (sim_set_breakpoint sim_clear_breakpoint):  Use ZALLOC
4577         and zfree instead of xmalloc and free.  Prevents warnings.
4578
4579 Wed Sep 24 17:38:57 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4580
4581         * configure: Regenerated to track ../common/aclocal.m4 changes.
4582
4583 Wed Sep 24 17:23:31 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4584
4585         * Make-common.in (SIM_BITSIZE): Assign from configured value.
4586         (CONFIG_CFLAGS): Add SIM_BITSIZE.
4587
4588         * aclocal.m4 (--enable-sim-bitsize): Developer option for
4589         controling the bitsize/msb of the target.
4590
4591 Wed Sep 24 17:41:40 1997  Stu Grossman  <grossman@babylon-5.cygnus.com>
4592
4593         * Make-common.in:  New files sim-break.c, sim-break.h.
4594         * sim-base.h:  Add point to breakpoint list to sim_state_base.
4595         * sim-break.c sim-break.h:  New modules that implement intrinsic
4596         breakpoint support.
4597         * sim-module.c:  Add breakpoint module.
4598         
4599 Tue Sep 23 00:26:39 1997  Felix Lee  <flee@yin.cygnus.com>
4600
4601         * sim-events.c (SIM_EVENTS_POLL_RATE): poll more often than once
4602         an hour.
4603         * sim-n-core.h (WITH_XOR_ENDIAN): MSVC barfs on
4604         if (0) { 1 % 0; }
4605         * sim-core.c (sim_core_xor_write_buffer): WITH_XOR_ENDIAN + 1.
4606         (SIGBUS) define for Windows.
4607         * sim-trace.c (trace_printf,debug_printf): added ALMOST_STDC.
4608         * sim-resume.c: define SIGTRAP for windows.
4609         * sim-xcat.h: use token pasting if ALMOST_STDC.
4610
4611 Tue Sep 23 11:04:38 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4612
4613         * Make-common.in (SIM_SCACHE, SIM_DEFAULT_MODEL): Assign
4614         configured values.
4615         (CONFIG_CFLAGS): Add same.
4616         
4617 Mon Sep 22 17:20:27 1997  Felix Lee  <flee@cygnus.com>
4618
4619         * sim-types.h (SIGNED64): ##i64 when _MSC_VER, not _WIN32.
4620         (SIGNED32): use ##i32.
4621
4622 Tue Sep 23 11:04:38 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4623
4624         * configure: Regenerated to track ../common/aclocal.m4 changes.
4625
4626 Tue Sep 23 10:07:47 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4627
4628         * aclocal.m4 (sim-endian): Simplify logic determining [default]
4629         endian of target.
4630
4631         * Make-common.in (SIM_WARNINGS, SIM_ALIGNMENT, SIM_ENDIAN,
4632         SIM_HOSTENDIAN, SIM_RESERVED_BITS, SIM_ASSERT, SIM_FLOAT,
4633         SIM_HARDWARE, SIM_INLINE, SIM_PACKAGES, SIM_REGPARM, SIM_SMP,
4634         SIM_STDCALL, SIM_XOR_ENDIAN): Assign configured values.
4635         (CONFIG_CFLAGS): Add same.
4636
4637         * aclocal.m4: Perform AC_SUBST on optional options.
4638
4639 Mon Sep 22 11:46:20 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4640
4641         * sim-config.h (WITH_DEFAULT_ALIGNMENT): Don't hardwire any alignment.
4642
4643         * sim-options.c (standard_option_handler): Typo in warning message.
4644
4645         * sim-base.h (STATE_MODEL): Make conditional on SIM_HAVE_MODEL.
4646
4647         * sim-profile.c (profile_print_insn): Check 0 .. MAX_INSN for any
4648         insn count.  Make count conditional on there being a valid
4649         INSN_NAME.
4650         (profile_pc_init): Make default PC profile frequency an arbitrary
4651         256.
4652
4653         * sim-base.h: Ditto.
4654
4655         * sim-profile.h (WITH_PROFILE_MODEL_P): Only enable modeling when
4656         SIM_HAVE_MODEL.
4657
4658         * sim-model.h (struct MACH): Depreciate, to be replaced by bfd
4659         archure struct.
4660
4661 Mon Sep 22 11:46:20 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4662
4663         * configure: Regenerated to track ../common/aclocal.m4 changes.
4664
4665 Mon Sep 22 11:45:00 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4666
4667         * aclocal.m4 (sim_alignment): Simplify logic for selecting the
4668         configured alignment.
4669
4670 Fri Sep 19 17:45:25 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4671
4672         * configure: Regenerated to track ../common/aclocal.m4 changes.
4673
4674 Fri Sep 19 17:26:14 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4675
4676         * sim-config.c (sim_config): Check for default alignment.
4677
4678         * sim-options.c (standard_option_handler): Add alignment option.
4679
4680         * aclocal.m4 (sim_alignment): Allow configuration of hardwired and
4681         default alignment requirements on memory accesses.
4682         
4683 Fri Sep 19 11:51:35 1997  Jeffrey A Law  (law@cygnus.com)
4684
4685         * sim-load.c (sim_load_file): Return failure if the executable
4686         had no loadable sections.
4687
4688 Wed Sep 17 13:33:28 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4689
4690         * sim-events.c (ETRACE): Use trace_printf not sim_io_printf for
4691         trace output.
4692
4693         * sim-core.c (sim_core_signal): When bad access halt simulator
4694         SIGSEGV / SIGBUS instead of aborting.
4695         (signal.h): Include.
4696         
4697         * sim-watch.c (sim_watchpoint_install): Handler for watchpoint
4698         options was missing.
4699
4700         * sim-bits.h (MOVED): Define
4701
4702 Wed Sep 17 10:33:28 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4703
4704         * sim-alu.h (ALU32_HAD_OVERFLOW): Pacify GCC, Use MSBIT instead of
4705         BIT.
4706
4707         * sim-bits.h (LSBIT, MSBIT): Check for overflow of shift value.
4708
4709         * sim-bits.c: Add 8 bit versions of bit macros.
4710
4711         * sim-bits.h: Ditto.
4712
4713 Tue Sep 16 16:15:16 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4714
4715         * sim-bits.c (LSSEXT, MSSEXT): Replace SEXT.
4716         (LSINSERTED, MSINSERTED): Ditto for INSERTED.
4717         
4718         * sim-n-bits.h (MSSEXTn, LSSEXTn): Replace SEXTn.
4719         (LSINSERTDn, MSINSERTEDN): Ditto for INSERTEDn.
4720         
4721         * sim-bits.h (SEXT*): Define as MSEXT/LSEXT.
4722         (INSERTED*): Ditto for LSINSERTED/MSINSERTED.
4723         
4724 Mon Sep 15 17:36:15 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4725
4726         * aclocal.m4 (SIM_AC_COMMON): Add optional config.h file argument.
4727         configure.in: Output to cconfig.h instead of config.h.
4728
4729         * configure: Regenerated to track ../common/aclocal.m4 changes.
4730
4731 Mon Sep 15 15:39:28 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4732
4733         * sim-utils.c (sim_analyze_program): Set STATE_ARCHITECTURE from
4734         BFD if known.
4735
4736 Tue Sep  9 21:46:46 1997  Felix Lee  <flee@cygnus.com>
4737
4738         * callback.c (os_write): divert stdout and stderr to their
4739         respective hooks.
4740
4741 Thu Sep 11 10:08:48 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4742
4743         * sim-profile.c (profile_print_speed): Call
4744         sim_events_elapsed_time instead of PROFILE_EXEC_TIME for moment.
4745
4746         * sim-events.c (sim_events_elapsed_time): New function return nr
4747         host MS consumed by the simulator.
4748         (sim_watch_valid): Use.
4749
4750         * sim-module.c (modules): Install sim_events very very early.
4751
4752         * sim-profile.c (profile_print): Call profile_print_pc.
4753         (print_bar):
4754         (profile_pc_init): New function, set up processor for PC
4755         profiling.
4756         (profile_print_pc): New function, print a PC profile.
4757         (profile_pc_event): New function, sample PC.
4758
4759         * sim-profile.h (PROFILE_PC_COUNT, PROFILE_PC_START,
4760         PROFILE_PC_END, PROFILE_PC_SHIFT, PROFILE_PC_SAMPLE_SIZE): Add to
4761         profile struct.
4762
4763         * sim-options.c (sim_print_help): Pacify GCC.
4764
4765         * sim-n-core.h (sim_core_read_aligned_N,
4766         sim_core_write_aligned_N): Add un-conditional profile call.
4767         (sim_core_read_unaligned_N, sim_core_write_unaligned_N): Add
4768         profile call when aligned read/write isn't used.
4769
4770         * sim-base.h: Include sim-profile, sim-model after sim-core &
4771         sim-events allow sim-core to define useful values.
4772
4773         * sim-profile.c (OPTION_PROFILE_CORE): Define.
4774         (profile_option_handler, profile_options): Add support for
4775         --profile-core option.
4776         (print_bar): Include when core profiling.
4777         (profile_print_core): New function, print core profile.
4778
4779         * sim-config.c (print_sim_config): Print profile status.
4780
4781         * sim-profile.h (PROFILE_NEXT_IDX, PROFILE_core,
4782         WITH_PROFILE_PC_P): Define.
4783         (PROFILE_CORE_COUNT): Count each core-map/size separatly.
4784         (PROFILE_COUNT_CORE): Define.
4785
4786 Thu Sep 11 08:44:52 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4787
4788         * sim-watch.c (handle_watchpoint): Pass a char** index into the
4789         interrupt_names array as the data.
4790         (sim-watch.h): Document.
4791
4792 Wed Sep 10 16:15:22 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4793
4794         * sim-options.c (sim_print_help): When the doc string is to long
4795         word wrap it.
4796
4797         * sim-watch.c (sim_watchpoint_install): Use option.doc_name so
4798         that only the first few the watch options are listed.  Generate
4799         meanginful usage messages.
4800
4801         * sim-options.h (struct OPTION): Clarify use of doc_name field
4802         
4803 Wed Sep 10 13:23:24 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4804
4805         * sim-options.c (OPTION_ARCHITECTURE_INFO): New option.
4806         (standard_option_handler): Handle --architecture-info.
4807
4808 Tue Sep  9 21:46:46 1997  Felix Lee  <flee@cygnus.com>
4809
4810         * sim-core.h (sim_cpu_core): [WITH_XOR_ENDIAN + 1], to avoid
4811         illegal zero-sized array.
4812         * sim-core.c (sim_core_xor_read_buffer): same.
4813
4814 Tue Sep  9 11:20:35 1997  Doug Evans  <dje@canuck.cygnus.com>
4815
4816         * nltvals.def: Regenerate.
4817
4818 Tue Sep  9 02:10:36 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4819
4820         * sim-fpu.c (DP_FRACHIGH2): Define LL using SIGNED64.
4821
4822 Mon Sep  8 12:22:20 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4823
4824         * sim-bits.c (MASKED): Delete.
4825         (EXTRACTED): Delete.
4826         (LSEXTRACTED, MSEXTRACTED): New functions.
4827
4828         * sim-n-bits.h (MASKEDn): Delete, define as MSMASKED or LSMASKED.
4829         (MSMASKEDn, LSMASKEDn): Add last argument.
4830         (MSMASK*): Ditto.
4831         
4832         * sim-bits.h (EXTEND8, EXTEND16): Define.
4833         (EXTRACTED64): Define as 64 bit extract, not 32 bit.
4834
4835         * sim-run.c (sim_engine_run): Use CPU_CIA macro.
4836
4837         * sim-engine.h (SIM_ENGINE_HALT_HOOK): Use CPU_CIA to get at
4838         current instruction address.
4839
4840         * sim-inline.h (*_ENGINE): Define.
4841
4842 Fri Sep  5 08:39:02 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4843
4844         * sim-core.c (sim_core_attach): Fix checks of modulo/mask.
4845
4846         * sim-watch.c (delete_watchpoint): Delete by ident and type.
4847         (watch_option_handler): Call delete_watchpoint with ident or type.
4848         (sim_watchpoint_install): Create interrupt specific watchpoint
4849         commands on the fly.
4850         (do_watchpoint_create): New function, create a watch point using
4851         type/int-nr info encoded in the option nr.
4852         (do_watchpoint_info): New function.  List active watchpoints.
4853
4854         * sim-watch.h: Change data structure to a list.
4855
4856         * sim-memopt.c (memory_option_handler): Require explicit "all"
4857         before deleting all memory regions.
4858
4859         * sim-utils.c (sim_do_commandf): New function, printf version of
4860         sim_do_command.
4861
4862         * sim-basics.h (asprintf, vasprintf): Hack, define for CYGWIN32. 
4863         
4864         * sim-alu.h (ALU64_ADD): Use explicit MSEXTRACTED64, do not assume
4865         bit endianness.
4866         (SIGNED64, UNSIGNED64): Delete.
4867         (ALU64_ADD): Don't rely on bit endianness.
4868         (ALU64_BEGIN): Define.
4869
4870         * sim-n-bits.h (MSEXTRACTEDn, LSEXTRACTED): New functions.
4871         (EXTRACTEDn): Delete, define as either LSEXTRACTED or MSEXTRACTED.
4872
4873         * sim-types.h (SIGNED64, UNSIGNED64): New macros, attach relevant
4874         suffix - u64, LL - to 64 bit constants.
4875
4876 Thu Sep  4 09:27:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4877
4878         * sim-config.c (sim_config): Add assert for SIM_MAGIC_NUMBER.
4879
4880         * sim-utils.h (NZALLOC): Define - zalloc * N.
4881
4882         * sim-hrw.c (sim_read, sim_write): New file.  Provide generic
4883         implementation of read/write functions.
4884
4885         * Make-common.in (sim-hrw.o): New target.
4886
4887         * sim-base.h (STATE_MEMOPT_P): Delete, simulators _always_ add
4888         memory.
4889
4890         * sim-memopt.c (memory_option_handler): Implement memory-size
4891         command. Implement memory-alias command.  Let memory-delete delete
4892         all memory regions.
4893         (add_memopt): New function.  Add a memory region.
4894         (do_memopt_delete): New function. Delete a memory region.
4895
4896         * sim-utils.c (sim_elapsed_time_get): Never return zero.
4897
4898         * sim-core.c (sim_core_detach): New function.
4899         (sim_core_map_detach): New function. Perform the actual detach.
4900         (sim_core_init): Move initialization code from here.
4901         (sim_core_install): To here.
4902         (sim_core_uninstall): And here.
4903
4904         * sim-module.c: Add memopt module.
4905
4906         * sim-base.h (STATE_MEMOPT, STATE_MEMOPT_P): Add memopt to
4907         simulator base type.
4908
4909         * Make-common.in (sim_main_headers): Add sim-memopt.h
4910         (sim-memopt.o): New target.
4911
4912         * sim-core.c (sim_core_install): Add core_options to the option
4913         table.
4914
4915         * sim-watch.c (watch_options): Make --delete-watch a synonym for
4916         --watch-delete.
4917
4918         * sim-config.h (WITH_MODULO_MEMORY): Define as 0.  Update
4919         comments.
4920
4921         * sim-core.h (struct _sim_core_mapping): Change nr_bytes to type
4922         address_word, add mask member.
4923         
4924         * sim-core.h, sim-core.c (sim_core_attach): Make nr_bytes of type
4925         address_word, allow for 64bit targets in 32bit host. Add modulo
4926         argument.
4927         (sim_core_map_attach): Ditto.
4928         (new_sim_core_mapping): Ditto.
4929         (sim_core_translate): Mask address when modulo memory.
4930
4931 Wed Sep  3 17:32:54 1997  Doug Evans  <dje@seba.cygnus.com>
4932
4933         * sim-hload.c (sim_load): Add assert for SIM_MAGIC_NUMBER.
4934
4935         * gdbinit.in: New file.
4936         * aclocal.m4 (SIM_AC_OUTPUT): Build .gdbinit.
4937         * Make-common.in (distclean): Delete .gdbinit.
4938         (.gdbinit): Add rule for.
4939         * configure: Regenerated to track ../common/aclocal.m4 changes.
4940
4941         * Make-common.in (cgen-run.o): Add rule for.
4942
4943 Wed Sep  3 10:08:21 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4944
4945         * sim-resume.c (sim_resume): Suspend/resume the simulator.
4946
4947         * sim-events.c (sim_watch_valid): Compute total elapsed time from
4948         both resumed and previous elapsed time.
4949         (sim_events_init): Set initial_wallclock and current_wallclock to
4950         zero.
4951         (sim_events_install): Install sim_events_suspend and
4952         sim_events_resume.
4953         (sim_events_watch_clock): Allow for suspended simulator when
4954         computing the time of the clock event.
4955
4956         * sim-events.h (struct _sim_event): Add resume_wallclock, rename
4957         initial_wallclock to elapsed_wallclock, set both to zero.
4958         (sim_events_init, sim_events_uninstall): Delete prototypes.
4959
4960         * sim-module.h (MODULE_SUSPEND_FN, MODULE_RESUME_FN): Define types.
4961         
4962         * sim-module.c(sim_module_resume, sim_module_suspend): New
4963         functions.
4964
4965 Wed Sep  3 10:08:21 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4966
4967         * sim-core.c (sim_core_map_attach): Clarify memory overlap error
4968         message.
4969
4970 Tue Sep  2 14:57:06 1997  Doug Evans  <dje@canuck.cygnus.com>
4971
4972         * Makefile.in (TAGS): Add support for "/* TAGS: foo */" marker.
4973         * Make-common.in (TAGS): Likewise.
4974         * sim-n-bits.h: Add TAGS comments for all functions.
4975         * sim-n-core.h: Likewise.
4976         * sim-n-endian.h: Likewise.
4977
4978 Mon Sep  1 10:50:11 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4979
4980         * sim-utils.c (sim_state_alloc): Set CPU backlinks, callback and
4981         kind.
4982         
4983         * sim-base.h (sim_state_alloc): Add callback and kind arguments.
4984         
4985         * sim-base.h (INVALID_INSTRUCTION_ADDRESS): Add default
4986         definition.
4987
4988 Sat Aug 30 09:47:21 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4989
4990         * sim-fpu.c (DP_GARDMSB, ...): Make unsigned.
4991         (DP_FRACHIGH, DP_FRACHIGH2, ..): Use MSMASK to avoid LL.
4992
4993 Fri Aug 29 13:37:44 1997  Andrew Cagney  <cagney@b1.cygnus.com>
4994
4995         * sim-core.c (sim_core_map_attach): Cast attach enum to int.
4996         (sim_core_xor_read_buffer, sim_core_xor_write_buffer): Make
4997         nr_transfered and nr_this_transfer unsigned.
4998
4999         * sim-events.c (sim_events_tickn): N is signed, as limited to
5000         MAXINT.
5001
5002         * sim-n-endian.h (offset_N): Change size to unsigned.
5003
5004         * callback.c (os_poll_quit): Add prototypes for kbhit and getkey.
5005
5006 Fri Aug 29 10:10:53 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5007
5008         * sim-utils.c (sim_copy_argv): Delete, replaced by dupargv.
5009
5010         * sim-options.c (sim_parse_args): Use dupargv.
5011
5012 Thu Aug 28 10:36:34 1997  Doug Evans  <dje@canuck.cygnus.com>
5013
5014         * sim-options.c (standard_option_handler): Use xstrdup, not strdup.
5015
5016 Thu Aug 28 12:09:15 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5017
5018         * sim-base.h (STATE_ARCHITECTURE, STATE_TARGET): Add to simulator
5019         base type.
5020
5021         * sim-options.c (standard_options): Add --architecture=MACHINE and
5022         --target=TARGET options.
5023         (OPTION_ARCHITECTURE, OPTION_TARGET): Define.
5024         (standard_option_handler): Handle architecture and target options.
5025         (bfd.h): Include.
5026         
5027         * sim-utils.c (sim_analyze_program): Pass STATE_TARGET to
5028         bfd_openr.
5029         (sim_analyze_program): Set prog_bfd architecture from
5030         STATE_ARCHITECTURE if known.
5031
5032 Wed Aug 27 18:13:22 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5033
5034         * configure: Regenerated to track ../common/aclocal.m4 changes.
5035         * config.in: Ditto.
5036
5037 Wed Aug 27 18:11:30 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5038
5039         * aclocal.m4 (enable-sim-warnings): Remove comment stating
5040         that option does not apply to certain files.
5041
5042 Wed Aug 27 15:13:04 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5043
5044         * sim-bits.h (LSBIT8, LSBIT16, LSBIT32, LSBIT64, LSBIT, MSBIT8,
5045         MSBIT16, MSBIT32, MSBIT64, MSBIT): New macros - single bit as
5046         offset from MSB/LSB.
5047
5048         * sim-endian.h (A1_8, A2_8, A4_8, A1_4, A2_4, A1_2): New macro,
5049         access address of sub word quantity of a hosts 16, 32, 64 bit word
5050         type.
5051         (V1_2, V1_4, V2_4, V1_8, V2_8, V4_8): Ditto for values.
5052         (U8_1, U8_2, U8_4, U4_1, U4_2, U2_1): Ditto for set of values.
5053         (V2_H1, V2_L1, V4_H2, V4_L2, V8_L4, V8_H4): Given N byte argument,
5054         return N*2 byte value with argument in Hi/Lo word.  Renamed from
5055         V1_H2, V1_L2, V2_H4, V2_L4, V4_H8, V4_L8.
5056         
5057         * sim-alu.h (ALU32_HAD_OVERFLOW): Use 64 bit mask not 32bit.
5058         (ALU16_HAD_CARRY, ALU32_HAD_CARRY, ALU16_HAD_OVERFLOW): Use MSBIT
5059         so that bit offset is explicit.
5060
5061 Wed Aug 27 11:55:35 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5062
5063         * sim-utils.c (sim_analyze_program): Add prog_name argument.
5064         Update STATE_PROG_BFD when needed with a dup'd copy of the
5065         program.
5066
5067         * sim-config.c (sim_config): Delete ABFD argument, use
5068         STATE_PROG_BFD directly.
5069
5070 Tue Aug 26 12:55:26 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5071
5072         * run.c (main): Pass the open ABFD to sim_create_inferior.
5073         
5074         * nrun.c (main): Determine prog_bfd.  Pass to sim_create_inferior
5075         and sim_load.
5076         (bfd.h): Include.
5077         
5078         * sim-hload.c (sim_load): New file. Implement generic sim_load for
5079         hardware only simulator targets.
5080
5081         * Make-common.in (sim-hload.o): Add rule.
5082
5083 Wed Aug 27 09:51:42 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5084
5085         * sim-utils.c (sim_copy_argv): Rewrite to match malloc strategy
5086         used by copyargv and freeargv.
5087
5088         * sim-options.c (sim_parse_args): Save a copy of PROG-ARGS in
5089         STATE_PROG_ARGV, not just a pointer.
5090
5091 Mon Aug 25 17:50:22 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5092
5093         * configure: Regenerated to track ../common/aclocal.m4 changes.
5094         * config.in: Ditto.
5095
5096 Mon Aug 25 12:11:06 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5097
5098         * aclocal.m4 (sim-endian): Add second argument to
5099         SIM_AC_OPTION_ENDIAN.  First is hardwired endian, second is
5100         default endian when not hardwired.
5101
5102         * sim-config.h (WITH_DEFAULT_TARGET_BYTE_ORDER): New macro, if all
5103         else failes value for target byte order.
5104
5105         * sim-config.c (sim_config): Add abfd arguments. Set
5106         STATE_PROG_BFD accordingly.  Determine prefered_target_byte_order
5107         from same.
5108         (sim_config): Return SIM_RC, don't abort.
5109         (bfd.h): Include.
5110         
5111         * run.c (main): Update call to sim_open - add ABFD argument.
5112         * nrun.c (main): Add NULL ABFD argument.
5113
5114 Thu Aug 14 12:48:57 1997  Doug Evans  <dje@canuck.cygnus.com>
5115
5116         * callback.c (os_poll_quit): Make static.
5117         Call sim_cb_eprintf, not p->eprintf.
5118         (sim_cb_printf, sim_cb_eprintf): New functions.
5119         * sim-utils.h (sim_cb_printf, sim_cb_eprintf): Declare.
5120
5121         * sim-basics.h (zalloc,zfree,sim_add_commas,SIM_ELAPSED_TIME,
5122         sim_elapsed_time_get,sim_elapsed_time_since): Move decls to
5123         sim-utils.h. #include sim-utils.h.
5124         * sim-utils.h: Above decls moved here.
5125         (sim_analyze_program,sim_load_file): Use `struct _bfd', not `bfd'.
5126
5127         * sim-watch.c (action_watchpoint): Fix thinkos.
5128
5129 Thu Jul 24 08:48:05 1997  Stu Grossman  (grossman@critters.cygnus.com)
5130
5131         * sim-types.h:  Fix defs of 64 bit data types for MSVC.
5132
5133 Tue Jul 22 10:35:37 1997  Doug Evans  <dje@canuck.cygnus.com>
5134
5135         * sim-n-core.h (sim_core_write_unaligned_N): Add missing break
5136         to FORCED_ALIGNMENT case.
5137
5138 Thu Jun  5 13:48:37 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5139
5140         * callback.c (target_to_host_open): Handle hosts with O_BINARY.
5141
5142 Thu Jun  5 08:47:10 1997  Jeffrey A Law  (law@cygnus.com)
5143
5144         * Make-common.in (libsim.a): Fix typo.
5145
5146 Thu Jun  5 13:48:37 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5147
5148         * nrun.c (main): Verify the structure returned before using it.
5149
5150 Wed Jun  4 11:44:06 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5151
5152         * sim-config.h (WITH_ENGINE): Enable the sim-engine module by
5153         default.
5154
5155         * sim-engine.c (sim_engine_install): New function.  Install the
5156         engine init functions.
5157         (sim_engine_init): [Re]initialize the simulator engine.
5158         
5159         * sim-module.c: Add sim_engine to list of modules that always
5160         install.
5161
5162 Tue Jun  3 04:52:04 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5163
5164         * sim-watch.c (schedule_watchpoint): Use sim_unschedule_watchpoint
5165         to remove the old watchpoint, not delete_watchpoint.
5166         (watch_option_handler): Action the correct watchpoint, not just
5167         cycles.
5168
5169 Wed May 28 14:47:41 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5170
5171         * sim-n-core.h (sim_core_write_aligned_N): For 8byte reads, output
5172         both low and high word.
5173         (sim_core_write_aligned_N): Ditto.
5174         
5175         * sim-trace.c (set_trace_options): Delete code explicitly setting
5176         core->trace.
5177
5178         * sim-options.c (sim_print_help): Call the list commands if not a
5179         standalone simulator.
5180         (sim_print_help): Advise that some options may not be applicable.
5181         
5182         * sim-trace.c (set_trace_options): Assume core present.
5183
5184         * sim-events.c (sim_events_schedule_after_signal): Overflow signal
5185         buffer when full not almost full.
5186
5187 Tue May 27 14:32:00 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5188
5189         * sim-events.c (sim_events_process): Don't blat the event queue
5190         when processing watchpoints.
5191
5192         * sim-watch.h: Make arg unsigned long - stop sign extension.
5193
5194         * sim-events.c (sim_watch_valid): rewrite so debugable.
5195
5196         * sim-config.h (WITH_XOR_ENDIAN): Default to zero.
5197
5198         * sim-watch.c (schedule_watchpoint): Add is_within option so that
5199         inequality test is possible.
5200         (handle_watchpoint): Re-pass is_within arg.
5201         (watch_option_handler): When `!' prefix to pc-watchpoint arg pass
5202         0 to schedule_watchpoint's is_within arg.
5203         (sim_watchpoint_init): Re-pass is_within arg.
5204
5205         * sim-options.c (sim_print_help): Add is_command argument.  Don't
5206         include -- prefix when called from the command line interpreter.
5207
5208         * sim-watch.c (schedule_watchpoint): Pass true is_within argument.
5209
5210         * sim-events.c (sim_events_watch_sim): Add is_within argument,
5211         zero indicates that the test should be reversed.
5212         (sim_events_watch_core): Ditto.
5213         (WATCH_CORE): Compare range against is_within.
5214         (WATCH_SIM): Ditto.
5215
5216 Tue May 27 12:48:03 1997  Andrew Cagney  <cagney@b2.cygnus.com>
5217
5218         * sim-events.c (WATCH_CORE): Pass NULL cpu argument to
5219         sim_core_read_buffer.  Check nr-bytes transfered.
5220
5221         * sim-core.h (sim_core_common): Define a new struct that contains
5222         the common data.  to sd and cpu structures.
5223         * sim-core.c (sim_core_attach): Update.
5224         (sim_core_init): Update. Remember to copy initialized data to each
5225         cpu.
5226         (sim_core_find_mapping): Ditto.
5227
5228         * sim-core.c (sim_core_read_buffer): Add cpu argument.
5229         (sim_core_write_buffer): Ditto.
5230
5231         * sim-n-core.h (sim_core_read_unaligned_N): When mis-aligned
5232         transfer use xor version of read buffer.
5233         (sim_core_write_unaligned_N): Ditto for write.
5234         
5235         * sim-core.c (sim_core_xor_read_buffer): New function implement
5236         xor-endian data read breaking transfer up into xor-endian sized
5237         blocks.
5238         (sim_core_xor_write_buffer): Ditto for write.
5239         (reverse_n): Reverse order of arbitrary number of bytes in buffer
5240         - needed for xor-endian transfers.
5241
5242 Fri May 23 14:24:31 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5243
5244         * sim-inline.h: Review description.
5245         
5246         * sim-core.h, sim-core.c: Reduce number of functions being inlined
5247         to just those involved in data transfers and configuration.
5248         
5249         * sim-xcat.h (XSTRING): New macro, map macro definition onto
5250         string.
5251         * sim-n-core.h (sim_core_read_aligned_N): Use.
5252         (sim_core_read_unaligned_N): Ditto.
5253         (sim_core_read_unaligned_N): Ditto..
5254         (sim_core_write_unaligned_N): Ditto.
5255         
5256         * sim-core.h: Add xor endian bitmap to main structure.  *
5257         
5258         sim-n-core.h (sim_core_write_aligned_N): Add suport for xor
5259         endian.
5260         (sim_core_read_aligned_N): Ditto.
5261
5262         * sim-core.c (sim_core_set_xor_endian): New function.
5263         (sim_core_attach): Don't overwrite the per-cpu xor map when
5264         cloning the global core.
5265
5266 Fri May 23 10:53:13 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5267
5268         * sim-engine.h: Update below so that it is using an enumerated
5269         type.
5270
5271 Thu May 22 09:12:16 1997  Gavin Koch  <gavin@cygnus.com>
5272
5273         * sim-engine.c (sim_engine_restart): 
5274         * sim-resume.c (sim_resume): Change longjmp param/setjmp 
5275         return value used for simulator restart from 0 to 2.
5276
5277 Wed May 21 08:47:30 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5278
5279         * cgen-scache.c (scache_option_handler): Add is_command arg.
5280
5281         * sim-model.c (model_option_handler): Add is_command argument.
5282
5283         * sim-profile.c (profile_option_handler): Add is_command arg.
5284
5285         * sim-events.c (sim_watch_valid): Use ub64, lb64 when 64bit value
5286         involved.
5287
5288         * sim-module.c (sim_module_add_init_fn): Call init fn in the same
5289         order that they are registered.
5290
5291         * sim-options.h (OPTION_HANDLER): Add argument to differentiate
5292         between option and command line processing.
5293
5294         * sim-options.c: Include stdlib.h, ctype.h.
5295
5296         * Make-common.in (sim-watch.o): Add rule.
5297         (sim_main_headers): Assume sim-assert.h included.
5298         (sim-*.o): Simplify make rule.
5299         
5300         * sim-module.c: Add sim_watch_install to module list.
5301
5302 Tue May 20 14:15:23 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5303
5304         * sim-base.h (STATE_LOADED_P): New predicate. Set once everything
5305         has been loaded.
5306
5307         * sim-trace.c (trace_install): Check magic. Include sim-assert.h.
5308         * sim-events.c (sim_events_install): Ditto.
5309         * sim-core.c (sim_core_install): Ditto.
5310         * sim-model.c (model_install): Ditto.
5311         * sim-options.c (standard_install): Ditto.
5312         * sim-profile.c (profile_install): Ditto.
5313         * sim-reason.c (sim_stop_reason): Ditto.
5314         * sim-run.c (sim_engine_run): Ditto.
5315         * sim-utils.c (sim_analyze_program): Ditto.
5316
5317         * sim-module.c (modules): Make profile_install and trace_install
5318         optional.
5319
5320         * sim-base.h (STATE_MEM_BASE): Define for flat memory systems.
5321
5322         * sim-options.c (standard_option_handler): Set the byte order.
5323
5324         * sim-events.c (sim_events_process): Allow multi tick processing.
5325         (sim_events_tickn): New function - multi cycle tick.
5326         
5327         * sim-events.h (sim_events_tickn, sim_events_timewarp): Add
5328         prototypes.  Under development.
5329         (sim_events): Replace processing with nr_ticks_to_process.
5330
5331 Tue May 20 09:39:22 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5332
5333         * nrun.c (main): Pass callbacks to sim_open instead of using
5334         sim_set_callbacks.
5335
5336         * run.c (main): Ditto.
5337
5338 Mon May 19 12:07:22 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5339
5340         * sim-events.c (sim_events_zalloc): Signal save memory allocator -
5341         stop tk interrupting malloc calls.
5342         (sim_events_zalloc): Converse.
5343
5344         * Make-common.in (sim_main_headers): Add sim-events.h.
5345
5346         * sim-events.c (sim_events_schedule_after_signal): Change return
5347         type to void - signal events are strictly internal.
5348         (sim_events_init): Allocate a finite buffer for signal events.
5349         (sim_events_schedule_after_signal): Enter signal events into the
5350         signal buffer.
5351
5352         * sim-engine.c (sim_engine_halt): Check SIM_DESC magic.
5353         (sim_engine_restart): Ditto.
5354         (sim_engine_abort): Ditto.
5355         * sim-stop.c (sim_stop): Ditto.
5356         (control_c_simulation): Ditto.
5357         * sim-resume.c (sim_resume): Ditto.
5358         (has_stepped): Ditto.
5359         * sim-abort.c (sim_engine_abort): Ditto.
5360
5361         * sim-basics.h (transfer_type): New type.
5362
5363         * sim-core.c (sim_core_signal): New function. Print core signal
5364         information.
5365         (sim_core_find_mapping): Add transfer argument.
5366
5367         * sim-n-core.h (sim_core_{write,write}_unaligned_N): Call
5368         SIM_CORE_SIGNAL if a recoverable abort.
5369         * sim-core.c (sim_core_find_mapping): Ditto.
5370
5371 Fri May 16 15:13:21 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5372
5373         * sim-core.c (sim_core_find_mapping): Replace calls to
5374         sim_io_error to more resiliant sim_engine_abort.
5375
5376         * sim-n-core.h (sim_core_read_unaligned_N): Ditto.
5377         (sim_core_write_unaligned_N): Ditto.
5378
5379 Tue May 13 13:50:06 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5380
5381         * sim-module.c: Add sim_events_install to list.
5382         
5383         * sim-events.c (sim_events_install, sim_events_uninstall): Clonse
5384         from sim_core_*.
5385         (sim_events_init): Now returns SIG_RC.
5386
5387         * sim-run.c: New file. Generic sim_engine_run.
5388         * sim-reason.c: New file. Generic sim_stop_reason.
5389         * sim-stop.c: New file. Generic sim_stop.
5390         * sim-resume.c: New file. Generic sim_resume.
5391         
5392         * Make-common.in (sim-engine.o): Add rule.
5393         (sim-run.o, sim-reason.o, sim-stop.o, sim-resume.o): Ditto.
5394         
5395         * sim-engine.h, sim-engine.c: New file. Provide generic
5396         implementation of sim_engine_halt, sim_engine_error. et.al.
5397
5398         * sim-base.h (sim_state_base): Add member halt.
5399         (sim-engine.h): Include.
5400
5401         * sim-events.h (sim_event_handler): Always pass SIM_DESC to event
5402         handlers.
5403         * sim-events.c (sim_events_poll): Update event handler.
5404
5405 Tue May 13 09:57:49 1997  Andrew Cagney  <cagney@b2.cygnus.com>
5406
5407         * sim-events.h, sim-events.c (sim_events_watch_clock): New
5408         function.
5409         (sim_events_watch_sim): New function.
5410         (sim_events_watch_core): New function.
5411         (sim_watch_valid): New function.
5412         (sim_events_preprocess): New function.
5413         (sim_events_process): Process the watchpoints as well as the timer
5414         queue.
5415         (sim_events_tick): Check WORK_PENDING instead of the hold queue.
5416         (sim_events_deschedule): Check all the queues when removing an
5417         event.
5418         (sim_events_init): Ditto for cleaning.
5419
5420 Mon May 19 12:07:22 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5421
5422         * sim-fpu.c (is_ufpu_number): Comment out - currently unused.
5423
5424 Mon May 19 11:23:03 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5425
5426         * callback.c (os_open): Type of arg flags is int.
5427
5428 Fri May 16 22:26:43 1997  Michael Meissner  <meissner@cygnus.com>
5429
5430         * sim-fpu.c (sim_fpu_is_{eq,ne,lt,le,gt,ge}): Compare Infinities
5431         just like normal numbers as per IEEE rules.
5432
5433 Wed May 14 21:20:38 1997  Bob Manson  <manson@charmed.cygnus.com>
5434
5435         * callback.c (os_close): Mark the descriptor as being
5436         available if the close succeeded.
5437         (os_open): Pass 0644 as the mode of the file being created.
5438
5439 Thu May 15 10:58:52 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5440
5441         * sim-fpu.c (pack_fpu, unpack_fpu): New functions - decode a
5442         float.
5443
5444         * sim-inline.c (SIM_INLINE_C): Rename from _SIM_INLINE_C_.
5445         * sim-lnline.h: Update.
5446
5447         * sim-fpu.h, sim-fpu.c (sim_fpu_[iu]{32,64}to): New int2fp
5448         conversion functions.
5449         (sim_fpu_to{32,64}[iu]): New fp2int functions.
5450         
5451         * sim-fpu.h, sim-fpu.c (sim_fpu_is_{lt,le,eq,ne,ge,gt}): New fp
5452         compare functions.  Replacing.
5453         (sim_fpu_cmp): This. Delete.
5454         
5455 Mon May 12 14:49:05 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5456
5457         * sim-core.c (sim_core_find_mapping): Call engine_error not
5458         sim_io_error when possible.
5459
5460 Mon May 12 08:55:07 1997  Andrew Cagney  <cagney@b2.cygnus.com>
5461
5462         * sim-endian.h (V1_H2): Add macro's to insert a word into a
5463         high/low double word.
5464
5465         * sim-trace.h: Remove definition of attribute - defined in
5466         sim_basics.h.
5467
5468 Mon May 12 08:55:07 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5469
5470         * sim-options.h (struct OPTION): Add doc_opt as the documenting
5471         name of the option - or family of options.
5472
5473         * sim-options.c (sim_args_command): Match command `a-b c' with
5474         option `--a-b-c' from option table.
5475
5476 Thu May  8 12:40:07 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5477
5478         * sim-options.c (sim_print_help): For optional arguments, wrap
5479         them in [].
5480
5481         * sim-trace.c (set_trace_options): New function, handle optional
5482         argument and multiple assignment.
5483         (trace_option_handler): Update.
5484
5485         * sim-trace.c (trace_option_handler): Trace branch and not fpu
5486         when branch tracing selected.
5487
5488 Wed May  7 15:19:58 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5489
5490         * sim-trace.c (trace_one_insn): Make a va-args function.
5491
5492         * sim-trace.c (trace_vprintf): New function, va-arg version of
5493         trace_printf.
5494
5495 Tue May  6 16:38:16 1997  Doug Evans  <dje@canuck.cygnus.com>
5496
5497         * sim-trace.c (trace_uninstall): Don't close a file twice.
5498         * sim-profile.c (profile_uninstall): Likewise.
5499
5500 Tue May  6 06:14:01 1997  Mike Meissner  <meissner@cygnus.com>
5501
5502         * sim-trace.c (toplevel): Include bfd.h.
5503         (trace_options): Note that --trace-linenum also turns on
5504         --trace-insn.  Add --trace-{branch,semantics}.
5505         (trace_option_handler): If --trace-linenum, also turn on
5506         --trace-insn.  Add --trace-branch support.  If --trace-semantics,
5507         turn on ALU, FPU, branch, and memory tracing.
5508         (trace_one_insn): New function to trace an instruction.  Support
5509         --trace-linenum.
5510         (OPTION_TRACE_*): Use an enum, rather than lots of defines.
5511
5512         * sim-trace.h (TRACE_{SEMANTICS,BRANCH}_IDX): Add new macros.
5513         (MAX_TRACE_VALUES): Use 32, not 12 by default.
5514         (TRACE_branch): Add new mask.
5515         (TRACE_*_P): Define all possible trace_p macros.
5516         (trace_one_insn): Declare function.
5517
5518 Mon May  5 14:08:34 1997  Mike Meissner  <meissner@cygnus.com>
5519
5520         * sim-trace.h (__attribute__): Define as nothing if not GNU C or
5521         GNU C doesn't support __attributes__.
5522         ({trace,debug}_printf): Add attribute's so -Wformat can check the
5523         format strings.
5524
5525 Mon May  5 11:16:12 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5526
5527         * sim-config.h (FORCED_ALIGNMENT): New alignment option -
5528         addresses are masked forcing them to be correctly aligned.
5529         (WITH_ALIGNMENT): Make NONSTRICT_ALIGNMENT the default.
5530         * sim-config.c (config_alignment_to_a): Update.
5531
5532         * sim-core.h (sim_cpu_core): New data type contains cpu specific
5533         core data.
5534         * sim-base.h (CPU_CORE): Add cpu specific core data to cpu base
5535         type.
5536         * sim-core.c (sim_core_attach): Add CPU argument.  Ready for
5537         processor specific core maps.
5538         (sim_core_map_attach): Copy the core map data to each of the
5539         processor specific core data structures.
5540         * sim-core.c (sim_core_find_mapping): Update.
5541
5542         * sim-n-core.h (sim_core_read_N, sim_core_write_N): Rename.
5543         (sim_core_write_aligned_N, sim_core_write_aligned_N): New names.
5544         (sim_core_write_unaligned_N, sim_core_write_unaligned_N): New
5545         alternatives that handle unaligned addresses.
5546         (sim_core_{read,write}_{,un}aligned_N): Drop SIM_DESC arg, replace
5547         with just CPU arg.
5548         * cgen-utils.c (sim_disassemble_insn): Update.
5549
5550 Mon May  5 13:19:16 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5551
5552         * sim-trace.h (TRACE_FPU_IDX): Add Floating-point specific
5553         tracing.
5554
5555         * sim-fpu.h, sim-fpu.c: New files - prototype for generic target
5556         fpu support.
5557
5558         * sim-inline.h, sim-inline.c: Add support for SIM_FPU.
5559
5560 Fri May  2 17:59:42 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5561
5562         * sim-core.c (sim_core_map_to_str): New function ascii equivalent
5563         to map type.
5564         
5565         * sim-n-core.h (sim_core_read_N, sim_core_write_N): Use in trace
5566         statement.
5567
5568 Fri May  2 17:28:02 1997  Andrew Cagney  <cagney@b2.cygnus.com>
5569
5570         * cgen-trace.c: Prepend additional trace_printf argument.
5571
5572         * cgen-utils.c (sim_disassemble_insn): Add additional core
5573         arguments.
5574
5575 Fri May  2 11:40:23 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5576
5577         * nrun.c (main): Catch/report errorenous simulator states.
5578
5579         * sim-module.c: #include "libiberty.h" so that xmalloc is defined.
5580         * sim-trace.c: #include string.h/strings.h so that memset is
5581         defined.
5582         * sim-utils.c: Ditto.
5583         * sim-profile.c: Ditto. And stdlib.h.
5584         (print_bar): Only define when used by instruction or memory profiler.
5585
5586         * sim-options.c (standard_option_handler): Make ul more local.
5587         
5588         * sim-load.c (sim_load_file): Make the name constant.
5589         (sim_load_file): Passify gcc.
5590
5591         * sim-utils.h: New file, pre-declare utilites in corresponding .c
5592         file.
5593         * sim-utils.c, sim-load.c: Include sim-utils.h.
5594         
5595         * sim-base.h (sim_cpu): Pre define here so available to all.
5596
5597         * sim-core.h (DECLARE_SIM_CORE_WRITE_N, DECLARE_SIM_CORE_READ_N):
5598         Restore the sim_cpu and instruction_address arguments so that full
5599         information is available to the abort function.
5600         * sim-core.c (sim_core_find_mapping, sim_core_write_buffer): Ditto.
5601         * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
5602
5603         * sim-trace.h, sim-trace.c (trace_option_handler): Add interim
5604         tracing support for sim-events and sim-core.
5605         (trace_option_handler): Convert #if to if where possible so always
5606         compiled/checked by C compiler.
5607         * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
5608         
5609         * sim-base.h: Adjust comment documenting how to define the cpu
5610         structure.
5611         (sim_state_base): Add sim_core and sim_events to simulator base
5612         object.
5613
5614         * sim-trace.h, sim-trace.c (trace_printf): Add SIM_DESC argument.
5615         * sim-core.c (sim_core_init, sim_core_attach,
5616         sim_core_find_mapping): Update.
5617         * sim-events.c (ETRACE, sim_events_init, sim_events_time,
5618         update_time_from_event, insert_sim_event,
5619         sim_events_schedule_after_signal, sim_events_deschedule,
5620         sim_events_tick): Ditto.
5621         
5622         * sim-basics.h (sim-module.h, sim-trace.h, sim-profile.h,
5623         sim-model.h): Move #includes from here.
5624         * sim-base.h: To here.
5625         (sim-core.h, sim-events.h, sim-io.h): Include also
5626         
5627 Wed Apr 30 15:37:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5628
5629         * callback.c (default_callback): Missing initialisers.
5630
5631 Thu May  1 10:40:47 1997  Doug Evans  <dje@canuck.cygnus.com>
5632
5633         * sim-utils.c (sim_add_commas): New function.
5634         * sim-basics.h (sim_add_commas): Add prototype.
5635         * cgen-scache.c (scache_print_profile): Print commas in numbers.
5636         * sim-profile.c (COMMAS): New macro.
5637         (print_*): Use it to print commas in numbers.
5638
5639         * configure: Regenerated.
5640
5641         * cgen-sim.h (sim_signal_type): Add SIM_SIGINT.
5642         (cgen_state): New member run_fast_p.
5643         (cgen_init): Add prototype.
5644         (sim_disassemble_insn): New arg `cpu'.
5645         * cgen-trace.c (trace_insn): Update call to sim_disassemble_insn.
5646         * cgen-utils.c (cgen_init): New function.
5647         (sim_disassemble_insn): New arg `cpu'.  Rewrite fetching of insn.
5648         * genmloop.sh: Call engine_halt if loop exits.
5649
5650         * Makefile.in (sim-options_h): Define.
5651         (sim-{module,options,trace,profile,utils}.o): Clean up dependencies.
5652         (sim-model.o): Add new rule.
5653         (cgen-{scache,trace,utils}.o): Add new rules.
5654         * aclocal.m4 (SIM_AC_OPTION_{SCACHE,DEFAULT_MODEL}): Add.
5655         * cgen-scache.c (scache_print_profile): Change `sd' arg to `cpu'.
5656         Indent output by 2 spaces.
5657         * cgen-scache.h (scache_print_profile): Update.
5658         * cgen-trace.c (trace_insn_fini): Indent output by 2 spaces.
5659         Use trace_printf, not fprintf.
5660         (trace_extract): Use trace_printf, not cgen_trace_printf.
5661         * genmloop.sh (!FAST case): Increment `insn_count'.
5662         * sim-base.h (sim_state_base): Only include scache_size if WITH_SCACHE.
5663         (sim_cpu_base): Rename member `sd' to `state' to be consistent with
5664         access macro's name.
5665         * sim-core.c (sim_core_init): Use EXTERN_SIM_CORE to define it.
5666         Change return type to SIM_RC.
5667         (sim_core_{install,uninstall}): New functions.
5668         * sim-core.h (sim_core_{install,uninstall}): Declare.
5669         (sim_core_init): Use EXTERN_SIM_CORE to define it.
5670         Change return type to SIM_RC.
5671         * sim-model.h (models,machs,model_install): Declare.
5672         * sim-module.c (modules): Add scache_install, model_install.
5673         (sim_post_argv_init): Set cpu->state backlinks.
5674         * sim-options.c (standard_options): Delete --simcache-size,--max-insns.
5675         (standard_option_handler): Likewise.
5676         * sim-profile.c (PROFILE_{HISTOGRAM,LABEL}_WIDTH): Move to
5677         sim-profile.h.
5678         (*): Assume ANSI C.
5679         (profile_options): Delete --profile-simcache.
5680         (profile_option_handler): Likewise.
5681         (profile_print_insn): Change `sd' arg to `cpu'.  Indent output 2
5682         spaces.
5683         (profile_print_{memory,model}): Likewise.
5684         (profile_print_simcache): Delete.
5685         (profile_print_speed): New function.
5686         (profile_print): Rewrite.
5687         * sim-profile.h (PROFILE_scache): Renamed from PROFILE_simcache.
5688         (WITH_PROFILE_SCACHE_P): Renamed from WITH_PROFILE_SIMCACHE_P.
5689         (PROFILE_DATA): Delete members simcache_{hits,misses}.
5690         (PROFILE_COUNT_SIMCACHE_{HIT,MISS}): Delete.
5691         (PROFILE_{CALLBACK,CPU_CALLBACK}): New types.
5692         (profile_print): Update prototype.
5693
5694 Wed Apr 30 11:34:14 1997  Doug Evans  <dje@canuck.cygnus.com>
5695
5696         * cgen-scache.[ch], cgen-sim.h: New files.
5697         * cgen-trace.[ch], cgen-types.h, cgen-utils.c, genmloop.sh: New files.
5698         * sim-model.c: New file.
5699
5700         * Make-common.in (clean targets): Undo patch of Apr. 22.
5701
5702 Fri Apr 25 15:28:32 1997  Mike Meissner  <meissner@cygnus.com>
5703
5704         * sim-n-bits.h (signed): If we have a standard compiler, undef
5705         signed, so that signedN is defined correctly.
5706
5707 Thu Apr 24 00:00:07 1997  Doug Evans  <dje@canuck.cygnus.com>
5708
5709         * sim-module.h, sim-model.h, sim-profile.h: New files.
5710         * sim-module.c, sim-profile.c: New files.
5711         * Make-common.in (SIM_PROFILE): Define
5712         (CONFIG_CFLAGS): Add $(SIM_PROFILE).
5713         (sim_main_headers): Add sim-module.h, sim-model.h, sim-profile.h.
5714         (sim_module.o,sim-profile.o): Add rules for.
5715         * aclocal.m4 (--enable-sim-trace): Allow symbolic arguments.
5716         (--enable-sim-profile): Add.
5717         * configure: Regenerated.
5718         * sim-base.h (sim_state_base): New members init_list, uninstall_list,
5719         model.  Move trace and profile support to sim-{trace,profile}.h.
5720         New members trace_data, profile_data.
5721         * sim-basics.h: #include sim-module.h, sim-model.h, sim-profile.h.
5722         * sim-config.h: Provide default definition of WITH_PROFILE.
5723         (WITH_TRACE): Change default to -1.
5724         (MAX_NR_PROCESSORS): Always define.
5725         * sim-options.c: Move trace and profile support to
5726         sim-{trace,profile}.h.
5727         (sim_pre_argv_init): Moved to sim-model.c.
5728         (standard_install): New function.
5729         * sim-options.h (sim_pre_argv_init): Move decl to sim-model.c.
5730         (standard_install): Declare.
5731         * sim-trace.c: Tracing option handling moved here from sim-options.c.
5732         (trace_install, trace_uninstall): New functions.
5733         (trace_printf): Update reference to TRACE_FILE.
5734         * sim-trace.h (TRACE_FOO_IDX): Moved here from sim-base.h.
5735         (TRACE_foo): Bit masks for symbolic arguments to --enable-sim-trace.
5736         (WITH_TRACE_FOO_P): Define.
5737         (trace_install): Declare.
5738         (TRACE_DATA): New struct.
5739
5740 Wed Apr 23 17:23:15 1997  Doug Evans  <dje@canuck.cygnus.com>
5741
5742         * run.c: Undo last exec_bfd patch.
5743         (main): Only pass -E ifdef SIM_HAVE_BIENDIAN.
5744
5745 Wed Apr 23 17:54:27 1997  Mike Meissner  <meissner@cygnus.com>
5746
5747         * run.c (exec_bfd): Add back in.
5748         (main): Set exec_bfd.
5749
5750 Tue Apr 22 14:43:46 1997  Doug Evans  <dje@canuck.cygnus.com>
5751
5752         * sim-load.c (sim_load_file): #include <stdio.h> for NULL.
5753
5754 Wed Apr 23 02:55:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5755
5756         * sim-events.c (insert_sim_event): Call sim_io_error instead of
5757         less well defined engine_error.
5758         * sim-core.c: Ditto.
5759
5760 Tue Apr 22 08:48:16 1997  Stu Grossman  (grossman@critters.cygnus.com)
5761
5762         * Make-common.in:  Change clean targets to use :: so that other
5763         Makefiles can have their own clean targets.
5764         * sim-load.c (xprintf eprintf):  Use ANSI_PROTOTYPES instead of
5765         __STDC__ to control use of stdarg vs. varargs syntax.  Some
5766         systems can't use __STDC__, but require stdarg.
5767
5768 Fri Apr 18 11:14:43 1997  Doug Evans  <dje@canuck.cygnus.com>
5769
5770         * sim-options.c (standard_options): Add --endian.
5771         (standard_option_handler): Likewise.
5772
5773         * nrun.c: #include <signal.h>.
5774         (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
5775         handler that calls sim_stop ().
5776
5777 Fri Apr 18 13:11:36 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5778
5779         * run.c (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
5780         handler that calls sim_stop ().  Simulators may still be
5781         establishing their own handler.
5782
5783         * sim-events.c (sim_events_poll): Rename from
5784         sim_events_at_large_int.  Poll IO.
5785
5786         * sim-io.c (sim_io_poll_quit): New function - pass on a polling
5787         request.
5788
5789         * callback.c (os_poll_quit): New function poll for quit signal
5790         where needed.
5791         (default_callback): Include magic number.
5792
5793 Thu Apr 17 02:25:11 1997  Doug Evans  <dje@canuck.cygnus.com>
5794
5795         * aclocal.m4: Check for headers time.h, sys/time.h, sys/resource.h.
5796         Check for functions getrusage, time.
5797         * sim-basics.h (SIM_ELAPSED_TIME): New typedef.
5798         (sim_elapsed_time_get, sim_elapsed_time_since): Add prototypes.
5799         * sim-utils.c: #include time.h, sys/time.h, sys/resource.h if able.
5800         (sim_elapsed_time_get, sim_elapsed_time_since): New functions.
5801
5802         * sim-utils.c (sim_copy_argv, sim_analyze_program): New functions.
5803
5804         * sim-options.c, sim-options.h: New files.
5805         * sim-config.h (WITH_DEBUG): Provide default value of zero.
5806         * Make-common.in (nrun.o): Add rules for.
5807         * nrun.c: New file.
5808
5809         * run.c (main): Check return value of sim_open.
5810
5811         * Make-common.in (sim-options.o, sim-load.o, sim-trace.o): Add rules.
5812         (sim_main_headers): Add sim-trace.h.
5813         * run.c (exec_bfd, target_byte_order): Delete.
5814         (main): Pass -E <endian> to sim_open.  Delete code to load sections,
5815         call sim_load instead.  Check return code of sim_create_inferior.
5816         * sim-base.h (CURRENT_STATE): Define.
5817         (sim_state_base): Make typedef.  New members options, prog_argv,
5818         prog_bfd, text_{section,start,end}, start_addr, simcache_size,
5819         mem_size, memory [+ corresponding access macros].
5820         (sim_cpu_base): New typedef.
5821         * sim-trace.h: New file.
5822         * sim-trace.c: New file.
5823         * sim-basics.h: #include it.
5824         * sim-load.c: New file.
5825
5826 Tue Apr 15 15:10:13 1997  Ian Lance Taylor  <ian@cygnus.com>
5827
5828         * Make-common.in (INSTALL): Set to @INSTALL@.
5829         (INSTALL_XFORM, INSTALL_XFORM1): Remove.
5830         (install-common): Depend upon installdirs.  Use
5831         $(program_transform_name) directly, rather than using
5832         $(INSTALL_XFORM).
5833         (installdirs): New target.
5834         * Makefile.in (INSTALL): Set to @INSTALL@.
5835         (INSTALL_XFORM, INSTALL_XFORM1): Remove.
5836         (install-man): Depend upon installdirs.  Use
5837         $(program_transform_name) directly, rather than using
5838         $(INSTALL_XFORM).
5839         (installdirs): New target.
5840
5841 Tue Apr 15 15:08:12 1997  Andrew Cagney  <cagney@b1.cygnus.com>
5842
5843         * sim-assert.h (SIM_ASSERT, ASSERT): Allow these macros to
5844         be overriden.
5845
5846 Wed Apr  9 16:06:44 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5847
5848         * sim-basics.h: Only bring in config.h and tconfig.h if
5849         HAVE_CONFIG_H.
5850
5851 Mon Apr  7 11:39:45 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5852
5853         * sim-config.h (WITH_TARGET_WORD_MSB): New Macro. Define the bit
5854         numbering convention of the target.
5855         * sim-config.c (print_sim_config): Print WITH_TARGET_WORD_BITSIZE
5856         and WITH_TARGET_WORD_MSB.
5857         (sim_config): When possible, check for consistency with bitsize
5858         and msb.
5859
5860         * sim-bits.h: Allow MSB to be other than zero.
5861         * sim-bits.c: Ditto.
5862         * sim-n-bits.h: Ditto.
5863         
5864         * sim-bits.h (MSMASK*): New macros - converce to LSMASK*.
5865         * sim-n-bits.h (MSMASKEDn): Ditto.
5866
5867 Mon Apr 14 16:29:21 1997  Ian Lance Taylor  <ian@cygnus.com>
5868
5869         * Makefile.in (INSTALL): Change install.sh to install-sh.
5870
5871 Mon Apr  7 10:46:38 1997  Doug Evans  <dje@canuck.cygnus.com>
5872
5873         * sim-base.h (sim_state_base): Move `magic' to end of struct.
5874
5875 Mon Apr  7 15:53:21 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5876
5877         * run.c (main): Check that a program to run was specified.
5878
5879 Mon Apr  7 15:45:02 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5880
5881         * aclocal.m4 (AC_TYPE_SIGNAL): Add check.
5882
5883         * configure: Regenerated to track ../common/aclocal.m4 changes.
5884         * config.in: Ditto.
5885
5886 Wed Apr  2 15:06:28 1997  Doug Evans  <dje@canuck.cygnus.com>
5887
5888         * sim-endian.h: Move host {LITTLE,BIG}_ENDIAN support from here,
5889         * sim-config.h: To here.
5890
5891         * Make-common.in (SIM_EXTRA_DEPS): New config var.
5892         (sim_main_headers): Define.
5893         (sim-*.o): Depend on $(SIM_EXTRA_DEPS).
5894         (BUILT_SRC_FROM_COMMON): Move here from ../d30v/Makefile.in.
5895         (clean): Use it.
5896         (sim-utils.o): Add rule for.
5897         * sim-utils.o: New file.
5898         * sim-basics.h: #include sim-base.h.
5899         (zalloc): Make argument unsigned long.
5900         * sim-base.h: New file.
5901         * sim-inline.h (SIM_IO support): Delete.
5902         * sim-io.h: Delete inline support.
5903         * sim-io.c: Likewise.  sim-state.h renamed to sim-main.h.
5904         * sim-config.c: sim-state.h renamed to sim-main.h.
5905         * sim-core.c: Likewise.
5906         * sim-events.c: Likewise.
5907
5908         * run.c (main): Pass SIM_OPEN_STANDALONE to sim_open.
5909
5910         * aclocal.m4: Check for stdlib.h, string.h, strings.h, unistd.h.
5911         (sim-debug): Allow arguments.  Define WITH_DEBUG in addition to
5912         -DDEBUG.
5913         * configure: Regenerated to track ../common/aclocal.m4 changes.
5914
5915 Wed Apr  2 14:34:19 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
5916
5917         * configure: Regenerated to track ../common/aclocal.m4 changes.
5918
5919 Wed Apr  2 11:08:11 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5920
5921         * sim-config.h (WITH_ALIGNMENT, WITH_FLOATING_POINT,
5922         WITH_XOR_ENDIAN, WITH_SMP, WITH_RESERVED_BITS): Assume that these
5923         are defined by the configure.
5924
5925         * aclocal.m4 (sim-stdio): Add option stdio from ../ppc configure.
5926         
5927         * aclocal.m4 (floating-point, xor-endian, alignment, smp,
5928         reserved-bits): Always define.
5929         
5930         * sim-config.h, sim-config.c (sim_config): New function - and new
5931         file - co-ordinate the setting/checking of the common simulator
5932         configuration options.
5933
5934         * Make-common.in (sim-config.o): Add rule.
5935
5936 Fri Mar 28 15:32:00 1997  Mike Meissner  <meissner@cygnus.com>
5937
5938         * callback.c (os_{,e}vprintf_filtered): Change stdarg type to
5939         va_list from void *, since va_list might not be a pointer type.
5940
5941 Mon Mar 24 15:27:12 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5942
5943         * sim-n-endian.h (offset_N): Correct assertion - word and sub word
5944         in wrong order.
5945         (offset_N): Correct computation of LE offset.
5946
5947         * sim-io.c (sim_io_error): Include a new line when reporting
5948         errors.
5949
5950         * sim-assert.h (SIM_FILTER_PATH): Out by one when locating last
5951         `/'.
5952
5953 Thu Mar 20 22:31:06 1997  Jeffrey A Law  (law@cygnus.com)
5954
5955         * run.c: Include alloca-conf.h.
5956
5957         * callback.c (os_evprintf_filtered): Fix typo.
5958
5959 Fri Mar 21 13:36:20 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5960
5961         * run.c (string.h, strings.h, stdlib.h): Include.
5962
5963         * sim-events.c (sim_events_tick): Recent cleanup failed to return
5964         0 when nothing pending.
5965
5966         * run.c (sim_size, sim_trace): Plicate GCC - these two functions
5967         will soon be going away.
5968         (getopt): Plicate GCC.
5969
5970         * sim-endian.c (sim-io.h): Plicate GCC.
5971         * sim-bits.c (sim-io.h): Ditto.
5972         * sim-n-bits.h (ROTn): Ditto.
5973
5974         * sim-io.c (sim_io_error): Correct check for NULL.
5975
5976         * sim-assert.h (SIM_FILTER_PATH): Separate out the code filtering
5977         the __FILE__.
5978         * sim-events.c: Use SIM_FILTER_PATH to filter out the filename
5979         path.
5980
5981 Wed Mar 19 01:12:06 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5982
5983         * aclocal.m4 (SIM_AC_OPTION_*: Move so that they are outside of
5984         SIM_AC_COMMON - SIM_AC_COMMON was gobling arguments.
5985
5986 Tue Mar 18 20:48:12 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5987
5988         * sim-alu.h: Include sim-xcat.h.
5989         
5990 Tue Mar 18 13:58:18 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
5991
5992         * Make-common.in (sim-bits.c, sim-core.c, sim-endian.c,
5993         sim-events.c, sim-inline.c, sim-io.c): Define rules for building
5994         these.
5995
5996         * sim-events.c (sim_events_at_large_int): New function.  Just
5997         schedules an event every large-int ticks.
5998         (sim_events_init): Call.
5999         (sim_events_tick, sim_events_process): Move async handing to
6000         sim_events_process.  Move timer decrement so that it occures after
6001         events have been processed.
6002         
6003         * sim-basics.h (struct _engine): Remove declaration.
6004
6005         * sim-events.h, sim-events.c: Rename type to sim_events.  Prefix
6006         everything with same.  Rename global struct to SIM_DESC.
6007         * sim-core.h, sim-core.c, sim-n-core.c: Ditto for sim_core.
6008         * sim-io.h, sim-io.c: Ditto.
6009         
6010         * sim-assert.h: New file. Optional assertion checking macros.
6011         * sim-io.c (sim_io_error): Make just this function tolerant to
6012         null pointers.
6013         
6014         * sim-xcat.h: New file. Define concatenate macros.
6015         * sim-basics.h (XCONCAT*): Move to sim-xcat.h.
6016         * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Explicitly include
6017         concat macros.
6018         
6019
6020 Tue Mar 18 12:44:55 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6021
6022         * sim-bits.h (LSMASK): New macro. Create mask of LS bits.
6023
6024 Mon Mar 17 18:10:05 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6025
6026         * sim-inline.h: Add definitions for sim-types.
6027         (ALL_BY_MODULE): New macro, encapsulate full inlining by the
6028         module.
6029
6030 Mon Mar 17 15:38:27 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6031         
6032         * sim-events.h: Remove defunct reference to callback struct.
6033
6034 Mon Mar 17 15:10:07 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6035
6036         * configure: Re-generate.
6037
6038 Mon Mar 17 15:04:47 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6039
6040         * Make-common.in (CSEARCH): Do not include the gdb directory in
6041         the search path.
6042
6043 Mon Mar 17 13:16:26 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6044
6045         * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
6046         SIM_WARNING): Drop, requiring the simulator specific Makefile.in
6047         to explicitly incorporate these.
6048
6049         * aclocal.m4 (--enable-sim-alignment); New option. Strongly
6050         specify the alignment restrictions of the target architecture -
6051         without this option all alignment restrictions are accomodated.
6052         (--enable-sim-assert): New option.  Conditionally compile in
6053         assertion statements.
6054         (--enable-sim-float): New option. Strongly specify the target's
6055         floating point support.
6056         (--enable-sim-hardware): New option.  Specify the hardware devices
6057         included in the simulation.
6058         (--enable-sim-packages): New option.  Specify the hardware
6059         packages included in the simulation.
6060         (--enable-sim-regparm): New option.  Specify that parameters be
6061         passed in registers instead of on the stack.
6062         (--enable-sim-reserved-bits): New option. Specify that reserved
6063         bits within an instruction are are correctly set.
6064         (--enable-sim-smp): New option. Specify the level of SMP support
6065         to be included in the simulator.
6066         (--enable-sim-stdcall): New option.  Specify an alternative
6067         function call convention.
6068         (--enable-sim-xor-endian): New option.  Configure xor-endian
6069         support used by some targets to implement bi-endian support.
6070         
6071 Fri Mar 14 19:51:21 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6072
6073         * aclocal.m4 (--enable-sim-hostendian): New option.  Allow the
6074         host endianness to be overridden.
6075         (--enable-sim-endian): Allow the target platform's byte order
6076         to be overridden.
6077         (--enable-sim-inline): Control the inlining of common components.
6078         (--enable-sim-bswap): For compatibility, also define WITH_BSWAP.
6079         (--enable-sim-warnings): Enable additional GCC compiler checks.
6080         * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
6081         SIM_WARNINGS): Add.
6082         
6083         * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Rename from
6084         sim-*-n.h so that the names are uniq on dos machines
6085         * sim-core.c, sim-bits.c, sim-endian.c: Update.
6086         
6087 Thu Mar 13 12:32:42 1997  Doug Evans  <dje@canuck.cygnus.com>
6088
6089         * run.c: #include "libiberty.h".
6090         (main): New locals sd,no_args,sim_argv.
6091         Run buildargv on -a option.  Pass argv to sim_open, argv[0]
6092         is program name.  Update call to sim_set_callbacks.
6093         Record result of sim_open, pass to other sim_foo routines.
6094
6095 Thu Mar 13 10:24:05 1997  Michael Meissner  <meissner@cygnus.com>
6096
6097         * callback.c (os_printf_filtered): Do not call exit(1) or print a
6098         final newline.
6099
6100 Thu Mar  6 15:50:28 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6101
6102         * callback.c: Add os_flush_stdout and vprintf_filtered callbacks.
6103         Route stdout through buffered IO.
6104
6105         * callback.c: Add os_flush_stderr, os_write_stderr,
6106         os_evprintf_filtered functions to route error output through
6107         stderr.
6108         
6109         * sim-io.h, sim-io.c (sim_io_flush_stderr, sim_io_flush_stdout):
6110         Correct return type - should be void.
6111
6112 Fri Mar  7 20:14:37 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6113
6114         * sim-basics.h: Clean up.  Many macro's moved to sim-inline.h.
6115
6116         * sim-config.h: Ditto.  For some options - eg WITH_DEVICES - do
6117         not provide a default value as undefined indicates disable code.
6118
6119 Thu Mar  6 15:50:28 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6120
6121         * sim-core.h, sim-core-n.h, sim-core.c: Borrow code from ppc
6122         directory.
6123         * sim-events.h, sim-events.c: Ditto.
6124         * sim-io.h, sim-io.c: Ditto.
6125         
6126 Tue Mar  4 09:35:56 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6127         
6128         * sim-alu.h (ALU_SUB_CA, ALU*_SUB_CA): New alu operation.
6129
6130         * sim-bits.h, sim-bits-n.h, sim-bits.c (LSMASKED*): New macro's
6131         extract the tail or least signifiant bits from an integer of the
6132         specified size.
6133         
6134         * sim-bits.h, sim-bits.c: Clean up conditionally compiled #if
6135         WITH_TARGET_BITSIZE so that the compilation will fail when an
6136         unsupported bitsize value is defined.
6137
6138         (INSERTED*): Convert to functions.
6139         (EXTRACTED*): Ditto.
6140         
6141         (SIGN_EXTEND, SEXT): Change to more terse name.
6142         
6143 Tue Mar  4 09:35:56 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6144
6145         * sim-inline.h: Allow explicit control over which .c files will be
6146         included by their header.
6147
6148         * sim-inline.h: Allow explicit control over which .c files use the
6149         alternative - REGPARM - parameter passing mechanism.
6150         
6151         * sim-inline.h, sim-inline.c: Don't attempt to include any of
6152         icache.c, idecode.c, semantics.c or support.c.  Those names are
6153         not generally applicable.
6154         
6155 Thu Feb 27 10:17:23 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6156
6157         * sim-bits.c, sim-bits-n.h (new): Split sim-bits.c into two parts
6158         in a fashion similar to sim-endian-n.
6159
6160         * sim-endian.h: (H_word, L_word, AL_*, VL_*): Extend to include
6161         both value and address macro's.
6162
6163 Tue Feb 25 18:51:57 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
6164
6165         * sim-alu.h (ALU16_BEGIN, ALU16_SET, ...): Fill in.
6166
6167         * sim-endian.h (L_word, H_word): Replace MS2W_4, LS2W_4 with more
6168         generic L_word, H_word macro's.
6169
6170 Thu Feb 20 18:36:55 1997  Andrew Cagney  <cagney@critters.cygnus.com>
6171
6172         * sim-basics.h: Borrow code from ppc directory.
6173         * sim-bits.c: Ditto.
6174         * sim-bits.h: Ditto.
6175         * sim-config.h: Ditto.
6176         * sim-endian-n.h: Ditto.
6177         * sim-endian.c: Ditto.
6178         * sim-endian.h: Ditto.
6179         * sim-inline.c: Ditto.
6180         * sim-inline.h: Ditto.
6181         * sim-types.h: Ditto.
6182
6183 Wed Feb 19 12:40:50 1997  Andrew Cagney  <cagney@critters.cygnus.com>
6184
6185         * sim-alu.h (ALU_SET16, ALU_SET32, ALU_SET64, etc): Make available
6186         all the ALU size alternatives and then auto-configure a default.
6187         
6188         * sim-alu.h: Copy ppc/idecode_expression.h.
6189
6190 Mon Feb 17 10:44:18 1997  Andrew Cagney  <cagney@critters.cygnus.com>
6191
6192         * bits.h, bits.c (SIGN_EXTEND32, SIGN_EXTEND64): New functions,
6193         sign extend a bit within a value.
6194
6195         * sim-endian.h, sim-endian-n.h (offset_N): New functions - return
6196         a pointer into the middle of a host word.
6197         * sim-endian.h (MS2W_4, LS2W_4): Use this function.
6198         
6199 Tue Feb 11 13:46:49 1997  Michael Meissner  <meissner@tiktok.cygnus.com>
6200
6201         * callback.c: If HAVE_CONFIG_H is defined, include config.h from
6202         autoconf.  If HAVE_UNISTD_H is defined, include unistd.h to get
6203         appropriate definitions of read, write, etc.  Add prototype for
6204         system.
6205
6206 Tue Feb  4 13:24:44 1997  Doug Evans  <dje@canuck.cygnus.com>
6207
6208         * Makefile.in (libcommon.a): Delete.
6209         (callback.o,targ-map.o): Delete, moved to Make-common.in.
6210         (gentmap,targ-vals.h,targ-map.c): Likewise.
6211         (run-autoconf): Delete.
6212         * aclocal.m4 (SIM_AC_OUTPUT): Redo creation of Makefile.
6213         (common makefile fragment): Moved back into ...
6214         * Make-common.in: Resurrect.
6215         * configure.in (AC_LINK_FILES): Delete, unnecessary now.
6216         * configure: Regenerated.
6217
6218 Fri Jan 31 07:16:49 1997  Doug Evans  <dje@canuck.cygnus.com>
6219
6220         * aclocal.m4 (SIM_AC_COMMON): Move COMMON_MAKEFILE_FRAG from here.
6221         (SIM_AC_OUTPUT): To here.
6222
6223 Fri Jan 24 10:37:17 1997  Stu Grossman  (grossman@critters.cygnus.com)
6224
6225         * aclocal.m4 (COMMON_MAKEFILE_FRAG):  Quote a couple of $'s in
6226         comments and single quotes.  Fixes a problem found on hpux.
6227
6228 Thu Jan 23 13:35:03 1997  Stu Grossman  (grossman@critters.cygnus.com)
6229
6230         * aclocal.m4:  Remove Make-common.in from dependencies.
6231         * (distclean):  Remove targ-vals.def.
6232
6233         * aclocal.m4 (SIM_AC_COMMON):  Move contents of Make-common.in
6234         into here.  Makes insertion into makefiles easier.  Also, change
6235         the way that callback.o, gentmap, targ-vals.h, targ-map.c,
6236         targ-map.o, and run are built.  They are now built in the
6237         individual simulator directories, taking sources from ../common as
6238         necessary.  This replaces the merging of libcommon.a into
6239         linsim.a, which was problematic for the WinGDB build process.
6240         * run.c:  Include config.h from . instead of ../common.
6241         * Make-common.in:  Remove.  It's no longer necessary.
6242
6243 Mon Dec 16 15:02:33 1996  Ian Lance Taylor  <ian@cygnus.com>
6244
6245         * Make-common.in (ALL_CLAGS): Put CFLAGS at the end.
6246         (.c.o): Put $(ALL_CFLAGS) before the file being compiled.
6247
6248 Wed Dec 11 11:30:58 1996  Jim Wilson  <wilson@cygnus.com>
6249
6250         * run.c (main): Set target_byte_order before call to sim_open.
6251
6252 Sun Dec  8 18:22:06 1996  Doug Evans  <dje@canuck.cygnus.com>
6253
6254         * callback.c: #include <stdlib.h>
6255         (os_error): New function.
6256         (default_callback): Add os_error.
6257
6258 Mon Nov 25 19:44:35 1996  Doug Evans  <dje@canuck.cygnus.com>
6259
6260         * Make-common.in (Makefile): Set CONFIG_HEADERS="".
6261         * aclocal.m4: Mark the fact that --enable-sim-bswap isn't host
6262         specific.
6263         (SIM_AC_OUTPUT): Don't build Makefile if CONFIG_FILES="".
6264
6265 Wed Nov 20 01:11:04 1996  Doug Evans  <dje@canuck.cygnus.com>
6266
6267         * run.c: #include ../common/config.h, tconfig.h.
6268         (myname): New static global.
6269         (main): Recognize new options -a, -c.  Also recognize -h if h8/300.
6270         Only process -c ifdef SIM_HAVE_SIMCACHE.
6271         Only process -p/-s ifdef SIM_HAVE_PROFILE.
6272         Parse program name from argv[0] and use in error messages.
6273         Pass sim_args to sim_open.  Pass prog_args to sim_create_inferior.
6274         Add support for incomplete h8/300 termination indicators.
6275         (usage): Make more verbose.
6276         * aclocal.m4,config.in,tconfig.in,configure.in,configure: New files.
6277         * Makefile.in,Make-common.in,callback.c: New files.
6278         * nltvals.def,gentmap.c,gentvals.sh: New files.
6279
6280 Tue Nov 12 13:34:00 1996  Dawn Perchik  <dawn@cygnus.com>   
6281
6282         * run.c: Include stdarg.h if __STDC__.
6283
6284 Tue Oct 15 11:16:31 1996  Jeffrey A Law  (law@cygnus.com)
6285
6286         * run.c (main): Don't print out anything if the signal
6287         number is zero (ie no signal).
6288
6289 Tue Oct 15 11:20:44 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
6290
6291         * run.c (main): Print out if the program raised a signal.
6292
6293 Wed Sep 18 09:52:14 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
6294
6295         * run.c (exec_bfd): Rename from sim_bfd, to use the gdb name.
6296         (main): Ditto.
6297
6298 Tue Sep 17 11:04:50 1996  James G. Smith  <jsmith@cygnus.co.uk>
6299
6300         * run.c (main): Explicitly cast malloc() parameter.
6301
6302 Thu Sep 12 11:27:21 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
6303
6304         * run.c (sim_bfd): New global to hold the bfd pointer for the
6305         executable.
6306         (main): Initialize sim_bfd.
6307
6308 Fri Dec 15 16:27:49 1995  Ian Lance Taylor  <ian@cygnus.com>
6309
6310         * run.c (main): Use new bfd_big_endian macro.
6311
6312 Wed Nov  8 15:49:49 1995  James G. Smith  <jsmith@pasanda.cygnus.co.uk>
6313
6314         * run.c (main): Removed SH specific comments, so source is
6315         generic. Also updated to only load relevant sections. Moved
6316         sim_open() to after callback attach (to match GDB).
6317
6318         * run.1: Removed SH specific comments.
6319
6320 Sat Oct 21 12:31:01 1995  Jim Wilson  <wilson@chestnut.cygnus.com>
6321
6322         * run.c (main): Always return sigrc at end.
6323
6324 Tue Oct 10 12:03:13 1995  J.T. Conklin  <jtc@rtl.cygnus.com>
6325
6326         * run.c (main): Print error diagnostic and exit if bfd_openr() or
6327         bfd_check_format() fails.
6328
6329 Thu Sep 28 15:40:36 1995  steve chamberlain  <sac@slash.cygnus.com>
6330
6331         * run.c, run.1: From sh directory.