Treat infinities like normal numbers for purposes of comparisons
[platform/upstream/binutils.git] / sim / common / ChangeLog
1 Fri May 16 22:26:43 1997  Michael Meissner  <meissner@cygnus.com>
2
3         * sim-fpu.c (sim_fpu_is_{eq,ne,lt,le,gt,ge}): Compare Infinities
4         just like normal numbers as per IEEE rules.
5
6 Wed May 14 21:20:38 1997  Bob Manson  <manson@charmed.cygnus.com>
7
8         * callback.c (os_close): Mark the descriptor as being
9         available if the close succeeded.
10         (os_open): Pass 0644 as the mode of the file being created.
11
12 Thu May 15 10:58:52 1997  Andrew Cagney  <cagney@b1.cygnus.com>
13
14         * sim-fpu.c (pack_fpu, unpack_fpu): New functions - decode a
15         float.
16
17         * sim-inline.c (SIM_INLINE_C): Rename from _SIM_INLINE_C_.
18         * sim-lnline.h: Update.
19
20         * sim-fpu.h, sim-fpu.c (sim_fpu_[iu]{32,64}to): New int2fp
21         conversion functions.
22         (sim_fpu_to{32,64}[iu]): New fp2int functions.
23         
24         * sim-fpu.h, sim-fpu.c (sim_fpu_is_{lt,le,eq,ne,ge,gt}): New fp
25         compare functions.  Replacing.
26         (sim_fpu_cmp): This. Delete.
27         
28 Mon May 12 14:49:05 1997  Andrew Cagney  <cagney@b1.cygnus.com>
29
30         * sim-core.c (sim_core_find_mapping): Call engine_error not
31         sim_io_error when possible.
32
33 Mon May 12 08:55:07 1997  Andrew Cagney  <cagney@b2.cygnus.com>
34
35         * sim-endian.h (V1_H2): Add macro's to insert a word into a
36         high/low double word.
37
38         * sim-trace.h: Remove definition of attribute - defined in
39         sim_basics.h.
40
41 Mon May 12 08:55:07 1997  Andrew Cagney  <cagney@b1.cygnus.com>
42
43         * sim-options.h (struct OPTION): Add doc_opt as the documenting
44         name of the option - or family of options.
45
46         * sim-options.c (sim_args_command): Match command `a-b c' with
47         option `--a-b-c' from option table.
48
49 Thu May  8 12:40:07 1997  Andrew Cagney  <cagney@b1.cygnus.com>
50
51         * sim-options.c (sim_print_help): For optional arguments, wrap
52         them in [].
53
54         * sim-trace.c (set_trace_options): New function, handle optional
55         argument and multiple assignment.
56         (trace_option_handler): Update.
57
58         * sim-trace.c (trace_option_handler): Trace branch and not fpu
59         when branch tracing selected.
60
61 Wed May  7 15:19:58 1997  Andrew Cagney  <cagney@b1.cygnus.com>
62
63         * sim-trace.c (trace_one_insn): Make a va-args function.
64
65         * sim-trace.c (trace_vprintf): New function, va-arg version of
66         trace_printf.
67
68 Tue May  6 16:38:16 1997  Doug Evans  <dje@canuck.cygnus.com>
69
70         * sim-trace.c (trace_uninstall): Don't close a file twice.
71         * sim-profile.c (profile_uninstall): Likewise.
72
73 Tue May  6 06:14:01 1997  Mike Meissner  <meissner@cygnus.com>
74
75         * sim-trace.c (toplevel): Include bfd.h.
76         (trace_options): Note that --trace-linenum also turns on
77         --trace-insn.  Add --trace-{branch,semantics}.
78         (trace_option_handler): If --trace-linenum, also turn on
79         --trace-insn.  Add --trace-branch support.  If --trace-semantics,
80         turn on ALU, FPU, branch, and memory tracing.
81         (trace_one_insn): New function to trace an instruction.  Support
82         --trace-linenum.
83         (OPTION_TRACE_*): Use an enum, rather than lots of defines.
84
85         * sim-trace.h (TRACE_{SEMANTICS,BRANCH}_IDX): Add new macros.
86         (MAX_TRACE_VALUES): Use 32, not 12 by default.
87         (TRACE_branch): Add new mask.
88         (TRACE_*_P): Define all possible trace_p macros.
89         (trace_one_insn): Declare function.
90
91 Mon May  5 14:08:34 1997  Mike Meissner  <meissner@cygnus.com>
92
93         * sim-trace.h (__attribute__): Define as nothing if not GNU C or
94         GNU C doesn't support __attributes__.
95         ({trace,debug}_printf): Add attribute's so -Wformat can check the
96         format strings.
97
98 Mon May  5 11:16:12 1997  Andrew Cagney  <cagney@b1.cygnus.com>
99
100         * sim-config.h (FORCED_ALIGNMENT): New alignment option -
101         addresses are masked forcing them to be correctly aligned.
102         (WITH_ALIGNMENT): Make NONSTRICT_ALIGNMENT the default.
103         * sim-config.c (config_alignment_to_a): Update.
104
105         * sim-core.h (sim_cpu_core): New data type contains cpu specific
106         core data.
107         * sim-base.h (CPU_CORE): Add cpu specific core data to cpu base
108         type.
109         * sim-core.c (sim_core_attach): Add CPU argument.  Ready for
110         processor specific core maps.
111         (sim_core_map_attach): Copy the core map data to each of the
112         processor specific core data structures.
113         * sim-core.c (sim_core_find_mapping): Update.
114
115         * sim-n-core.h (sim_core_read_N, sim_core_write_N): Rename.
116         (sim_core_write_aligned_N, sim_core_write_aligned_N): New names.
117         (sim_core_write_unaligned_N, sim_core_write_unaligned_N): New
118         alternatives that handle unaligned addresses.
119         (sim_core_{read,write}_{,un}aligned_N): Drop SIM_DESC arg, replace
120         with just CPU arg.
121         * cgen-utils.c (sim_disassemble_insn): Update.
122
123 Mon May  5 13:19:16 1997  Andrew Cagney  <cagney@b1.cygnus.com>
124
125         * sim-trace.h (TRACE_FPU_IDX): Add Floating-point specific
126         tracing.
127
128         * sim-fpu.h, sim-fpu.c: New files - prototype for generic target
129         fpu support.
130
131         * sim-inline.h, sim-inline.c: Add support for SIM_FPU.
132
133 Fri May  2 17:59:42 1997  Andrew Cagney  <cagney@b1.cygnus.com>
134
135         * sim-core.c (sim_core_map_to_str): New function ascii equivalent
136         to map type.
137         
138         * sim-n-core.h (sim_core_read_N, sim_core_write_N): Use in trace
139         statement.
140
141 Fri May  2 17:28:02 1997  Andrew Cagney  <cagney@b2.cygnus.com>
142
143         * cgen-trace.c: Prepend additional trace_printf argument.
144
145         * cgen-utils.c (sim_disassemble_insn): Add additional core
146         arguments.
147
148 Fri May  2 11:40:23 1997  Andrew Cagney  <cagney@b1.cygnus.com>
149
150         * nrun.c (main): Catch/report errorenous simulator states.
151
152         * sim-module.c: #include "libiberty.h" so that xmalloc is defined.
153         * sim-trace.c: #include string.h/strings.h so that memset is
154         defined.
155         * sim-utils.c: Ditto.
156         * sim-profile.c: Ditto. And stdlib.h.
157         (print_bar): Only define when used by instruction or memory profiler.
158
159         * sim-options.c (standard_option_handler): Make ul more local.
160         
161         * sim-load.c (sim_load_file): Make the name constant.
162         (sim_load_file): Passify gcc.
163
164         * sim-utils.h: New file, pre-declare utilites in corresponding .c
165         file.
166         * sim-utils.c, sim-load.c: Include sim-utils.h.
167         
168         * sim-base.h (sim_cpu): Pre define here so available to all.
169
170         * sim-core.h (DECLARE_SIM_CORE_WRITE_N, DECLARE_SIM_CORE_READ_N):
171         Restore the sim_cpu and instruction_address arguments so that full
172         information is available to the abort function.
173         * sim-core.c (sim_core_find_mapping, sim_core_write_buffer): Ditto.
174         * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
175
176         * sim-trace.h, sim-trace.c (trace_option_handler): Add interim
177         tracing support for sim-events and sim-core.
178         (trace_option_handler): Convert #if to if where possible so always
179         compiled/checked by C compiler.
180         * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
181         
182         * sim-base.h: Adjust comment documenting how to define the cpu
183         structure.
184         (sim_state_base): Add sim_core and sim_events to simulator base
185         object.
186
187         * sim-trace.h, sim-trace.c (trace_printf): Add SIM_DESC argument.
188         * sim-core.c (sim_core_init, sim_core_attach,
189         sim_core_find_mapping): Update.
190         * sim-events.c (ETRACE, sim_events_init, sim_events_time,
191         update_time_from_event, insert_sim_event,
192         sim_events_schedule_after_signal, sim_events_deschedule,
193         sim_events_tick): Ditto.
194         
195         * sim-basics.h (sim-module.h, sim-trace.h, sim-profile.h,
196         sim-model.h): Move #includes from here.
197         * sim-base.h: To here.
198         (sim-core.h, sim-events.h, sim-io.h): Include also
199         
200 Wed Apr 30 15:37:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
201
202         * callback.c (default_callback): Missing initialisers.
203
204 Thu May  1 10:40:47 1997  Doug Evans  <dje@canuck.cygnus.com>
205
206         * sim-utils.c (sim_add_commas): New function.
207         * sim-basics.h (sim_add_commas): Add prototype.
208         * cgen-scache.c (scache_print_profile): Print commas in numbers.
209         * sim-profile.c (COMMAS): New macro.
210         (print_*): Use it to print commas in numbers.
211
212         * configure: Regenerated.
213
214         * cgen-sim.h (sim_signal_type): Add SIM_SIGINT.
215         (cgen_state): New member run_fast_p.
216         (cgen_init): Add prototype.
217         (sim_disassemble_insn): New arg `cpu'.
218         * cgen-trace.c (trace_insn): Update call to sim_disassemble_insn.
219         * cgen-utils.c (cgen_init): New function.
220         (sim_disassemble_insn): New arg `cpu'.  Rewrite fetching of insn.
221         * genmloop.sh: Call engine_halt if loop exits.
222
223         * Makefile.in (sim-options_h): Define.
224         (sim-{module,options,trace,profile,utils}.o): Clean up dependencies.
225         (sim-model.o): Add new rule.
226         (cgen-{scache,trace,utils}.o): Add new rules.
227         * aclocal.m4 (SIM_AC_OPTION_{SCACHE,DEFAULT_MODEL}): Add.
228         * cgen-scache.c (scache_print_profile): Change `sd' arg to `cpu'.
229         Indent output by 2 spaces.
230         * cgen-scache.h (scache_print_profile): Update.
231         * cgen-trace.c (trace_insn_fini): Indent output by 2 spaces.
232         Use trace_printf, not fprintf.
233         (trace_extract): Use trace_printf, not cgen_trace_printf.
234         * genmloop.sh (!FAST case): Increment `insn_count'.
235         * sim-base.h (sim_state_base): Only include scache_size if WITH_SCACHE.
236         (sim_cpu_base): Rename member `sd' to `state' to be consistent with
237         access macro's name.
238         * sim-core.c (sim_core_init): Use EXTERN_SIM_CORE to define it.
239         Change return type to SIM_RC.
240         (sim_core_{install,uninstall}): New functions.
241         * sim-core.h (sim_core_{install,uninstall}): Declare.
242         (sim_core_init): Use EXTERN_SIM_CORE to define it.
243         Change return type to SIM_RC.
244         * sim-model.h (models,machs,model_install): Declare.
245         * sim-module.c (modules): Add scache_install, model_install.
246         (sim_post_argv_init): Set cpu->state backlinks.
247         * sim-options.c (standard_options): Delete --simcache-size,--max-insns.
248         (standard_option_handler): Likewise.
249         * sim-profile.c (PROFILE_{HISTOGRAM,LABEL}_WIDTH): Move to
250         sim-profile.h.
251         (*): Assume ANSI C.
252         (profile_options): Delete --profile-simcache.
253         (profile_option_handler): Likewise.
254         (profile_print_insn): Change `sd' arg to `cpu'.  Indent output 2
255         spaces.
256         (profile_print_{memory,model}): Likewise.
257         (profile_print_simcache): Delete.
258         (profile_print_speed): New function.
259         (profile_print): Rewrite.
260         * sim-profile.h (PROFILE_scache): Renamed from PROFILE_simcache.
261         (WITH_PROFILE_SCACHE_P): Renamed from WITH_PROFILE_SIMCACHE_P.
262         (PROFILE_DATA): Delete members simcache_{hits,misses}.
263         (PROFILE_COUNT_SIMCACHE_{HIT,MISS}): Delete.
264         (PROFILE_{CALLBACK,CPU_CALLBACK}): New types.
265         (profile_print): Update prototype.
266
267 Wed Apr 30 11:34:14 1997  Doug Evans  <dje@canuck.cygnus.com>
268
269         * cgen-scache.[ch], cgen-sim.h: New files.
270         * cgen-trace.[ch], cgen-types.h, cgen-utils.c, genmloop.sh: New files.
271         * sim-model.c: New file.
272
273         * Make-common.in (clean targets): Undo patch of Apr. 22.
274
275 Fri Apr 25 15:28:32 1997  Mike Meissner  <meissner@cygnus.com>
276
277         * sim-n-bits.h (signed): If we have a standard compiler, undef
278         signed, so that signedN is defined correctly.
279
280 Thu Apr 24 00:00:07 1997  Doug Evans  <dje@canuck.cygnus.com>
281
282         * sim-module.h, sim-model.h, sim-profile.h: New files.
283         * sim-module.c, sim-profile.c: New files.
284         * Make-common.in (SIM_PROFILE): Define
285         (CONFIG_CFLAGS): Add $(SIM_PROFILE).
286         (sim_main_headers): Add sim-module.h, sim-model.h, sim-profile.h.
287         (sim_module.o,sim-profile.o): Add rules for.
288         * aclocal.m4 (--enable-sim-trace): Allow symbolic arguments.
289         (--enable-sim-profile): Add.
290         * configure: Regenerated.
291         * sim-base.h (sim_state_base): New members init_list, uninstall_list,
292         model.  Move trace and profile support to sim-{trace,profile}.h.
293         New members trace_data, profile_data.
294         * sim-basics.h: #include sim-module.h, sim-model.h, sim-profile.h.
295         * sim-config.h: Provide default definition of WITH_PROFILE.
296         (WITH_TRACE): Change default to -1.
297         (MAX_NR_PROCESSORS): Always define.
298         * sim-options.c: Move trace and profile support to
299         sim-{trace,profile}.h.
300         (sim_pre_argv_init): Moved to sim-model.c.
301         (standard_install): New function.
302         * sim-options.h (sim_pre_argv_init): Move decl to sim-model.c.
303         (standard_install): Declare.
304         * sim-trace.c: Tracing option handling moved here from sim-options.c.
305         (trace_install, trace_uninstall): New functions.
306         (trace_printf): Update reference to TRACE_FILE.
307         * sim-trace.h (TRACE_FOO_IDX): Moved here from sim-base.h.
308         (TRACE_foo): Bit masks for symbolic arguments to --enable-sim-trace.
309         (WITH_TRACE_FOO_P): Define.
310         (trace_install): Declare.
311         (TRACE_DATA): New struct.
312
313 Wed Apr 23 17:23:15 1997  Doug Evans  <dje@canuck.cygnus.com>
314
315         * run.c: Undo last exec_bfd patch.
316         (main): Only pass -E ifdef SIM_HAVE_BIENDIAN.
317
318 Wed Apr 23 17:54:27 1997  Mike Meissner  <meissner@cygnus.com>
319
320         * run.c (exec_bfd): Add back in.
321         (main): Set exec_bfd.
322
323 Tue Apr 22 14:43:46 1997  Doug Evans  <dje@canuck.cygnus.com>
324
325         * sim-load.c (sim_load_file): #include <stdio.h> for NULL.
326
327 Wed Apr 23 02:55:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
328
329         * sim-events.c (insert_sim_event): Call sim_io_error instead of
330         less well defined engine_error.
331         * sim-core.c: Ditto.
332
333 Tue Apr 22 08:48:16 1997  Stu Grossman  (grossman@critters.cygnus.com)
334
335         * Make-common.in:  Change clean targets to use :: so that other
336         Makefiles can have their own clean targets.
337         * sim-load.c (xprintf eprintf):  Use ANSI_PROTOTYPES instead of
338         __STDC__ to control use of stdarg vs. varargs syntax.  Some
339         systems can't use __STDC__, but require stdarg.
340
341 Fri Apr 18 11:14:43 1997  Doug Evans  <dje@canuck.cygnus.com>
342
343         * sim-options.c (standard_options): Add --endian.
344         (standard_option_handler): Likewise.
345
346         * nrun.c: #include <signal.h>.
347         (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
348         handler that calls sim_stop ().
349
350 Fri Apr 18 13:11:36 1997  Andrew Cagney  <cagney@b1.cygnus.com>
351
352         * run.c (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
353         handler that calls sim_stop ().  Simulators may still be
354         establishing their own handler.
355
356         * sim-events.c (sim_events_poll): Rename from
357         sim_events_at_large_int.  Poll IO.
358
359         * sim-io.c (sim_io_poll_quit): New function - pass on a polling
360         request.
361
362         * callback.c (os_poll_quit): New function poll for quit signal
363         where needed.
364         (default_callback): Include magic number.
365
366 Thu Apr 17 02:25:11 1997  Doug Evans  <dje@canuck.cygnus.com>
367
368         * aclocal.m4: Check for headers time.h, sys/time.h, sys/resource.h.
369         Check for functions getrusage, time.
370         * sim-basics.h (SIM_ELAPSED_TIME): New typedef.
371         (sim_elapsed_time_get, sim_elapsed_time_since): Add prototypes.
372         * sim-utils.c: #include time.h, sys/time.h, sys/resource.h if able.
373         (sim_elapsed_time_get, sim_elapsed_time_since): New functions.
374
375         * sim-utils.c (sim_copy_argv, sim_analyze_program): New functions.
376
377         * sim-options.c, sim-options.h: New files.
378         * sim-config.h (WITH_DEBUG): Provide default value of zero.
379         * Make-common.in (nrun.o): Add rules for.
380         * nrun.c: New file.
381
382         * run.c (main): Check return value of sim_open.
383
384         * Make-common.in (sim-options.o, sim-load.o, sim-trace.o): Add rules.
385         (sim_main_headers): Add sim-trace.h.
386         * run.c (exec_bfd, target_byte_order): Delete.
387         (main): Pass -E <endian> to sim_open.  Delete code to load sections,
388         call sim_load instead.  Check return code of sim_create_inferior.
389         * sim-base.h (CURRENT_STATE): Define.
390         (sim_state_base): Make typedef.  New members options, prog_argv,
391         prog_bfd, text_{section,start,end}, start_addr, simcache_size,
392         mem_size, memory [+ corresponding access macros].
393         (sim_cpu_base): New typedef.
394         * sim-trace.h: New file.
395         * sim-trace.c: New file.
396         * sim-basics.h: #include it.
397         * sim-load.c: New file.
398
399 Tue Apr 15 15:10:13 1997  Ian Lance Taylor  <ian@cygnus.com>
400
401         * Make-common.in (INSTALL): Set to @INSTALL@.
402         (INSTALL_XFORM, INSTALL_XFORM1): Remove.
403         (install-common): Depend upon installdirs.  Use
404         $(program_transform_name) directly, rather than using
405         $(INSTALL_XFORM).
406         (installdirs): New target.
407         * Makefile.in (INSTALL): Set to @INSTALL@.
408         (INSTALL_XFORM, INSTALL_XFORM1): Remove.
409         (install-man): Depend upon installdirs.  Use
410         $(program_transform_name) directly, rather than using
411         $(INSTALL_XFORM).
412         (installdirs): New target.
413
414 Tue Apr 15 15:08:12 1997  Andrew Cagney  <cagney@b1.cygnus.com>
415
416         * sim-assert.h (SIM_ASSERT, ASSERT): Allow these macros to
417         be overriden.
418
419 Wed Apr  9 16:06:44 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
420
421         * sim-basics.h: Only bring in config.h and tconfig.h if
422         HAVE_CONFIG_H.
423
424 Mon Apr  7 11:39:45 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
425
426         * sim-config.h (WITH_TARGET_WORD_MSB): New Macro. Define the bit
427         numbering convention of the target.
428         * sim-config.c (print_sim_config): Print WITH_TARGET_WORD_BITSIZE
429         and WITH_TARGET_WORD_MSB.
430         (sim_config): When possible, check for consistency with bitsize
431         and msb.
432
433         * sim-bits.h: Allow MSB to be other than zero.
434         * sim-bits.c: Ditto.
435         * sim-n-bits.h: Ditto.
436         
437         * sim-bits.h (MSMASK*): New macros - converce to LSMASK*.
438         * sim-n-bits.h (MSMASKEDn): Ditto.
439
440 Mon Apr 14 16:29:21 1997  Ian Lance Taylor  <ian@cygnus.com>
441
442         * Makefile.in (INSTALL): Change install.sh to install-sh.
443
444 Mon Apr  7 10:46:38 1997  Doug Evans  <dje@canuck.cygnus.com>
445
446         * sim-base.h (sim_state_base): Move `magic' to end of struct.
447
448 Mon Apr  7 15:53:21 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
449
450         * run.c (main): Check that a program to run was specified.
451
452 Mon Apr  7 15:45:02 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
453
454         * aclocal.m4 (AC_TYPE_SIGNAL): Add check.
455
456         * configure: Regenerated to track ../common/aclocal.m4 changes.
457         * config.in: Ditto.
458
459 Wed Apr  2 15:06:28 1997  Doug Evans  <dje@canuck.cygnus.com>
460
461         * sim-endian.h: Move host {LITTLE,BIG}_ENDIAN support from here,
462         * sim-config.h: To here.
463
464         * Make-common.in (SIM_EXTRA_DEPS): New config var.
465         (sim_main_headers): Define.
466         (sim-*.o): Depend on $(SIM_EXTRA_DEPS).
467         (BUILT_SRC_FROM_COMMON): Move here from ../d30v/Makefile.in.
468         (clean): Use it.
469         (sim-utils.o): Add rule for.
470         * sim-utils.o: New file.
471         * sim-basics.h: #include sim-base.h.
472         (zalloc): Make argument unsigned long.
473         * sim-base.h: New file.
474         * sim-inline.h (SIM_IO support): Delete.
475         * sim-io.h: Delete inline support.
476         * sim-io.c: Likewise.  sim-state.h renamed to sim-main.h.
477         * sim-config.c: sim-state.h renamed to sim-main.h.
478         * sim-core.c: Likewise.
479         * sim-events.c: Likewise.
480
481         * run.c (main): Pass SIM_OPEN_STANDALONE to sim_open.
482
483         * aclocal.m4: Check for stdlib.h, string.h, strings.h, unistd.h.
484         (sim-debug): Allow arguments.  Define WITH_DEBUG in addition to
485         -DDEBUG.
486         * configure: Regenerated to track ../common/aclocal.m4 changes.
487
488 Wed Apr  2 14:34:19 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
489
490         * configure: Regenerated to track ../common/aclocal.m4 changes.
491
492 Wed Apr  2 11:08:11 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
493
494         * sim-config.h (WITH_ALIGNMENT, WITH_FLOATING_POINT,
495         WITH_XOR_ENDIAN, WITH_SMP, WITH_RESERVED_BITS): Assume that these
496         are defined by the configure.
497
498         * aclocal.m4 (sim-stdio): Add option stdio from ../ppc configure.
499         
500         * aclocal.m4 (floating-point, xor-endian, alignment, smp,
501         reserved-bits): Always define.
502         
503         * sim-config.h, sim-config.c (sim_config): New function - and new
504         file - co-ordinate the setting/checking of the common simulator
505         configuration options.
506
507         * Make-common.in (sim-config.o): Add rule.
508
509 Fri Mar 28 15:32:00 1997  Mike Meissner  <meissner@cygnus.com>
510
511         * callback.c (os_{,e}vprintf_filtered): Change stdarg type to
512         va_list from void *, since va_list might not be a pointer type.
513
514 Mon Mar 24 15:27:12 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
515
516         * sim-n-endian.h (offset_N): Correct assertion - word and sub word
517         in wrong order.
518         (offset_N): Correct computation of LE offset.
519
520         * sim-io.c (sim_io_error): Include a new line when reporting
521         errors.
522
523         * sim-assert.h (SIM_FILTER_PATH): Out by one when locating last
524         `/'.
525
526 Thu Mar 20 22:31:06 1997  Jeffrey A Law  (law@cygnus.com)
527
528         * run.c: Include alloca-conf.h.
529
530         * callback.c (os_evprintf_filtered): Fix typo.
531
532 Fri Mar 21 13:36:20 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
533
534         * run.c (string.h, strings.h, stdlib.h): Include.
535
536         * sim-events.c (sim_events_tick): Recent cleanup failed to return
537         0 when nothing pending.
538
539         * run.c (sim_size, sim_trace): Plicate GCC - these two functions
540         will soon be going away.
541         (getopt): Plicate GCC.
542
543         * sim-endian.c (sim-io.h): Plicate GCC.
544         * sim-bits.c (sim-io.h): Ditto.
545         * sim-n-bits.h (ROTn): Ditto.
546
547         * sim-io.c (sim_io_error): Correct check for NULL.
548
549         * sim-assert.h (SIM_FILTER_PATH): Separate out the code filtering
550         the __FILE__.
551         * sim-events.c: Use SIM_FILTER_PATH to filter out the filename
552         path.
553
554 Wed Mar 19 01:12:06 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
555
556         * aclocal.m4 (SIM_AC_OPTION_*: Move so that they are outside of
557         SIM_AC_COMMON - SIM_AC_COMMON was gobling arguments.
558
559 Tue Mar 18 20:48:12 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
560
561         * sim-alu.h: Include sim-xcat.h.
562         
563 Tue Mar 18 13:58:18 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
564
565         * Make-common.in (sim-bits.c, sim-core.c, sim-endian.c,
566         sim-events.c, sim-inline.c, sim-io.c): Define rules for building
567         these.
568
569         * sim-events.c (sim_events_at_large_int): New function.  Just
570         schedules an event every large-int ticks.
571         (sim_events_init): Call.
572         (sim_events_tick, sim_events_process): Move async handing to
573         sim_events_process.  Move timer decrement so that it occures after
574         events have been processed.
575         
576         * sim-basics.h (struct _engine): Remove declaration.
577
578         * sim-events.h, sim-events.c: Rename type to sim_events.  Prefix
579         everything with same.  Rename global struct to SIM_DESC.
580         * sim-core.h, sim-core.c, sim-n-core.c: Ditto for sim_core.
581         * sim-io.h, sim-io.c: Ditto.
582         
583         * sim-assert.h: New file. Optional assertion checking macros.
584         * sim-io.c (sim_io_error): Make just this function tolerant to
585         null pointers.
586         
587         * sim-xcat.h: New file. Define concatenate macros.
588         * sim-basics.h (XCONCAT*): Move to sim-xcat.h.
589         * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Explicitly include
590         concat macros.
591         
592
593 Tue Mar 18 12:44:55 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
594
595         * sim-bits.h (LSMASK): New macro. Create mask of LS bits.
596
597 Mon Mar 17 18:10:05 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
598
599         * sim-inline.h: Add definitions for sim-types.
600         (ALL_BY_MODULE): New macro, encapsulate full inlining by the
601         module.
602
603 Mon Mar 17 15:38:27 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
604         
605         * sim-events.h: Remove defunct reference to callback struct.
606
607 Mon Mar 17 15:10:07 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
608
609         * configure: Re-generate.
610
611 Mon Mar 17 15:04:47 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
612
613         * Make-common.in (CSEARCH): Do not include the gdb directory in
614         the search path.
615
616 Mon Mar 17 13:16:26 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
617
618         * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
619         SIM_WARNING): Drop, requiring the simulator specific Makefile.in
620         to explicitly incorporate these.
621
622         * aclocal.m4 (--enable-sim-alignment); New option. Strongly
623         specify the alignment restrictions of the target architecture -
624         without this option all alignment restrictions are accomodated.
625         (--enable-sim-assert): New option.  Conditionally compile in
626         assertion statements.
627         (--enable-sim-float): New option. Strongly specify the target's
628         floating point support.
629         (--enable-sim-hardware): New option.  Specify the hardware devices
630         included in the simulation.
631         (--enable-sim-packages): New option.  Specify the hardware
632         packages included in the simulation.
633         (--enable-sim-regparm): New option.  Specify that parameters be
634         passed in registers instead of on the stack.
635         (--enable-sim-reserved-bits): New option. Specify that reserved
636         bits within an instruction are are correctly set.
637         (--enable-sim-smp): New option. Specify the level of SMP support
638         to be included in the simulator.
639         (--enable-sim-stdcall): New option.  Specify an alternative
640         function call convention.
641         (--enable-sim-xor-endian): New option.  Configure xor-endian
642         support used by some targets to implement bi-endian support.
643         
644 Fri Mar 14 19:51:21 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
645
646         * aclocal.m4 (--enable-sim-hostendian): New option.  Allow the
647         host endianness to be overridden.
648         (--enable-sim-endian): Allow the target platform's byte order
649         to be overridden.
650         (--enable-sim-inline): Control the inlining of common components.
651         (--enable-sim-bswap): For compatibility, also define WITH_BSWAP.
652         (--enable-sim-warnings): Enable additional GCC compiler checks.
653         * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
654         SIM_WARNINGS): Add.
655         
656         * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Rename from
657         sim-*-n.h so that the names are uniq on dos machines
658         * sim-core.c, sim-bits.c, sim-endian.c: Update.
659         
660 Thu Mar 13 12:32:42 1997  Doug Evans  <dje@canuck.cygnus.com>
661
662         * run.c: #include "libiberty.h".
663         (main): New locals sd,no_args,sim_argv.
664         Run buildargv on -a option.  Pass argv to sim_open, argv[0]
665         is program name.  Update call to sim_set_callbacks.
666         Record result of sim_open, pass to other sim_foo routines.
667
668 Thu Mar 13 10:24:05 1997  Michael Meissner  <meissner@cygnus.com>
669
670         * callback.c (os_printf_filtered): Do not call exit(1) or print a
671         final newline.
672
673 Thu Mar  6 15:50:28 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
674
675         * callback.c: Add os_flush_stdout and vprintf_filtered callbacks.
676         Route stdout through buffered IO.
677
678         * callback.c: Add os_flush_stderr, os_write_stderr,
679         os_evprintf_filtered functions to route error output through
680         stderr.
681         
682         * sim-io.h, sim-io.c (sim_io_flush_stderr, sim_io_flush_stdout):
683         Correct return type - should be void.
684
685 Fri Mar  7 20:14:37 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
686
687         * sim-basics.h: Clean up.  Many macro's moved to sim-inline.h.
688
689         * sim-config.h: Ditto.  For some options - eg WITH_DEVICES - do
690         not provide a default value as undefined indicates disable code.
691
692 Thu Mar  6 15:50:28 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
693
694         * sim-core.h, sim-core-n.h, sim-core.c: Borrow code from ppc
695         directory.
696         * sim-events.h, sim-events.c: Ditto.
697         * sim-io.h, sim-io.c: Ditto.
698         
699 Tue Mar  4 09:35:56 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
700         
701         * sim-alu.h (ALU_SUB_CA, ALU*_SUB_CA): New alu operation.
702
703         * sim-bits.h, sim-bits-n.h, sim-bits.c (LSMASKED*): New macro's
704         extract the tail or least signifiant bits from an integer of the
705         specified size.
706         
707         * sim-bits.h, sim-bits.c: Clean up conditionally compiled #if
708         WITH_TARGET_BITSIZE so that the compilation will fail when an
709         unsupported bitsize value is defined.
710
711         (INSERTED*): Convert to functions.
712         (EXTRACTED*): Ditto.
713         
714         (SIGN_EXTEND, SEXT): Change to more terse name.
715         
716 Tue Mar  4 09:35:56 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
717
718         * sim-inline.h: Allow explicit control over which .c files will be
719         included by their header.
720
721         * sim-inline.h: Allow explicit control over which .c files use the
722         alternative - REGPARM - parameter passing mechanism.
723         
724         * sim-inline.h, sim-inline.c: Don't attempt to include any of
725         icache.c, idecode.c, semantics.c or support.c.  Those names are
726         not generally applicable.
727         
728 Thu Feb 27 10:17:23 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
729
730         * sim-bits.c, sim-bits-n.h (new): Split sim-bits.c into two parts
731         in a fashion similar to sim-endian-n.
732
733         * sim-endian.h: (H_word, L_word, AL_*, VL_*): Extend to include
734         both value and address macro's.
735
736 Tue Feb 25 18:51:57 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
737
738         * sim-alu.h (ALU16_BEGIN, ALU16_SET, ...): Fill in.
739
740         * sim-endian.h (L_word, H_word): Replace MS2W_4, LS2W_4 with more
741         generic L_word, H_word macro's.
742
743 Thu Feb 20 18:36:55 1997  Andrew Cagney  <cagney@critters.cygnus.com>
744
745         * sim-basics.h: Borrow code from ppc directory.
746         * sim-bits.c: Ditto.
747         * sim-bits.h: Ditto.
748         * sim-config.h: Ditto.
749         * sim-endian-n.h: Ditto.
750         * sim-endian.c: Ditto.
751         * sim-endian.h: Ditto.
752         * sim-inline.c: Ditto.
753         * sim-inline.h: Ditto.
754         * sim-types.h: Ditto.
755
756 Wed Feb 19 12:40:50 1997  Andrew Cagney  <cagney@critters.cygnus.com>
757
758         * sim-alu.h (ALU_SET16, ALU_SET32, ALU_SET64, etc): Make available
759         all the ALU size alternatives and then auto-configure a default.
760         
761         * sim-alu.h: Copy ppc/idecode_expression.h.
762
763 Mon Feb 17 10:44:18 1997  Andrew Cagney  <cagney@critters.cygnus.com>
764
765         * bits.h, bits.c (SIGN_EXTEND32, SIGN_EXTEND64): New functions,
766         sign extend a bit within a value.
767
768         * sim-endian.h, sim-endian-n.h (offset_N): New functions - return
769         a pointer into the middle of a host word.
770         * sim-endian.h (MS2W_4, LS2W_4): Use this function.
771         
772 Tue Feb 11 13:46:49 1997  Michael Meissner  <meissner@tiktok.cygnus.com>
773
774         * callback.c: If HAVE_CONFIG_H is defined, include config.h from
775         autoconf.  If HAVE_UNISTD_H is defined, include unistd.h to get
776         appropriate definitions of read, write, etc.  Add prototype for
777         system.
778
779 Tue Feb  4 13:24:44 1997  Doug Evans  <dje@canuck.cygnus.com>
780
781         * Makefile.in (libcommon.a): Delete.
782         (callback.o,targ-map.o): Delete, moved to Make-common.in.
783         (gentmap,targ-vals.h,targ-map.c): Likewise.
784         (run-autoconf): Delete.
785         * aclocal.m4 (SIM_AC_OUTPUT): Redo creation of Makefile.
786         (common makefile fragment): Moved back into ...
787         * Make-common.in: Resurrect.
788         * configure.in (AC_LINK_FILES): Delete, unnecessary now.
789         * configure: Regenerated.
790
791 Fri Jan 31 07:16:49 1997  Doug Evans  <dje@canuck.cygnus.com>
792
793         * aclocal.m4 (SIM_AC_COMMON): Move COMMON_MAKEFILE_FRAG from here.
794         (SIM_AC_OUTPUT): To here.
795
796 Fri Jan 24 10:37:17 1997  Stu Grossman  (grossman@critters.cygnus.com)
797
798         * aclocal.m4 (COMMON_MAKEFILE_FRAG):  Quote a couple of $'s in
799         comments and single quotes.  Fixes a problem found on hpux.
800
801 Thu Jan 23 13:35:03 1997  Stu Grossman  (grossman@critters.cygnus.com)
802
803         * aclocal.m4:  Remove Make-common.in from dependencies.
804         * (distclean):  Remove targ-vals.def.
805
806         * aclocal.m4 (SIM_AC_COMMON):  Move contents of Make-common.in
807         into here.  Makes insertion into makefiles easier.  Also, change
808         the way that callback.o, gentmap, targ-vals.h, targ-map.c,
809         targ-map.o, and run are built.  They are now built in the
810         individual simulator directories, taking sources from ../common as
811         necessary.  This replaces the merging of libcommon.a into
812         linsim.a, which was problematic for the WinGDB build process.
813         * run.c:  Include config.h from . instead of ../common.
814         * Make-common.in:  Remove.  It's no longer necessary.
815
816 Mon Dec 16 15:02:33 1996  Ian Lance Taylor  <ian@cygnus.com>
817
818         * Make-common.in (ALL_CLAGS): Put CFLAGS at the end.
819         (.c.o): Put $(ALL_CFLAGS) before the file being compiled.
820
821 Wed Dec 11 11:30:58 1996  Jim Wilson  <wilson@cygnus.com>
822
823         * run.c (main): Set target_byte_order before call to sim_open.
824
825 Sun Dec  8 18:22:06 1996  Doug Evans  <dje@canuck.cygnus.com>
826
827         * callback.c: #include <stdlib.h>
828         (os_error): New function.
829         (default_callback): Add os_error.
830
831 Mon Nov 25 19:44:35 1996  Doug Evans  <dje@canuck.cygnus.com>
832
833         * Make-common.in (Makefile): Set CONFIG_HEADERS="".
834         * aclocal.m4: Mark the fact that --enable-sim-bswap isn't host
835         specific.
836         (SIM_AC_OUTPUT): Don't build Makefile if CONFIG_FILES="".
837
838 Wed Nov 20 01:11:04 1996  Doug Evans  <dje@canuck.cygnus.com>
839
840         * run.c: #include ../common/config.h, tconfig.h.
841         (myname): New static global.
842         (main): Recognize new options -a, -c.  Also recognize -h if h8/300.
843         Only process -c ifdef SIM_HAVE_SIMCACHE.
844         Only process -p/-s ifdef SIM_HAVE_PROFILE.
845         Parse program name from argv[0] and use in error messages.
846         Pass sim_args to sim_open.  Pass prog_args to sim_create_inferior.
847         Add support for incomplete h8/300 termination indicators.
848         (usage): Make more verbose.
849         * aclocal.m4,config.in,tconfig.in,configure.in,configure: New files.
850         * Makefile.in,Make-common.in,callback.c: New files.
851         * nltvals.def,gentmap.c,gentvals.sh: New files.
852
853 Tue Nov 12 13:34:00 1996  Dawn Perchik  <dawn@cygnus.com>   
854
855         * run.c: Include stdarg.h if __STDC__.
856
857 Tue Oct 15 11:16:31 1996  Jeffrey A Law  (law@cygnus.com)
858
859         * run.c (main): Don't print out anything if the signal
860         number is zero (ie no signal).
861
862 Tue Oct 15 11:20:44 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
863
864         * run.c (main): Print out if the program raised a signal.
865
866 Wed Sep 18 09:52:14 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
867
868         * run.c (exec_bfd): Rename from sim_bfd, to use the gdb name.
869         (main): Ditto.
870
871 Tue Sep 17 11:04:50 1996  James G. Smith  <jsmith@cygnus.co.uk>
872
873         * run.c (main): Explicitly cast malloc() parameter.
874
875 Thu Sep 12 11:27:21 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
876
877         * run.c (sim_bfd): New global to hold the bfd pointer for the
878         executable.
879         (main): Initialize sim_bfd.
880
881 Fri Dec 15 16:27:49 1995  Ian Lance Taylor  <ian@cygnus.com>
882
883         * run.c (main): Use new bfd_big_endian macro.
884
885 Wed Nov  8 15:49:49 1995  James G. Smith  <jsmith@pasanda.cygnus.co.uk>
886
887         * run.c (main): Removed SH specific comments, so source is
888         generic. Also updated to only load relevant sections. Moved
889         sim_open() to after callback attach (to match GDB).
890
891         * run.1: Removed SH specific comments.
892
893 Sat Oct 21 12:31:01 1995  Jim Wilson  <wilson@chestnut.cygnus.com>
894
895         * run.c (main): Always return sigrc at end.
896
897 Tue Oct 10 12:03:13 1995  J.T. Conklin  <jtc@rtl.cygnus.com>
898
899         * run.c (main): Print error diagnostic and exit if bfd_openr() or
900         bfd_check_format() fails.
901
902 Thu Sep 28 15:40:36 1995  steve chamberlain  <sac@slash.cygnus.com>
903
904         * run.c, run.1: From sh directory.
905
906