Define SIGNED64 and UNSIGNED64 macros - handle MSC/GCC LL issue.
[deliverable/binutils-gdb.git] / sim / common / ChangeLog
CommitLineData
30efae3a
AC
1Fri Sep 5 08:39:02 1997 Andrew Cagney <cagney@b1.cygnus.com>
2
3 * sim-alu.h (ALU64_ADD): Use explicit MSEXTRACTED64, do not assume
4 bit endianness.
5 (SIGNED64, UNSIGNED64): Delete.
6 (ALU64_ADD): Don't rely on bit endianness.
7 (ALU64_BEGIN): Define.
8
9 * sim-n-bits.h (MSEXTRACTEDn, LSEXTRACTED): New functions.
10 (EXTRACTEDn): Delete, define as either LSEXTRACTED or MSEXTRACTED.
11
12 * sim-types.h (SIGNED64, UNSIGNED64): New macros, attach relevant
13 suffix - u64, LL - to 64 bit constants.
14
a34abff8
AC
15Thu Sep 4 09:27:54 1997 Andrew Cagney <cagney@b1.cygnus.com>
16
6dbaff8f
AC
17 * sim-config.c (sim_config): Add assert for SIM_MAGIC_NUMBER.
18
19 * sim-utils.h (NZALLOC): Define - zalloc * N.
20
21 * sim-hrw.c (sim_read, sim_write): New file. Provide generic
22 implementation of read/write functions.
23
24 * Make-common.in (sim-hrw.o): New target.
25
26 * sim-base.h (STATE_MEMOPT_P): Delete, simulators _always_ add
27 memory.
28
29 * sim-memopt.c (memory_option_handler): Implement memory-size
30 command. Implement memory-alias command. Let memory-delete delete
31 all memory regions.
32 (add_memopt): New function. Add a memory region.
33 (do_memopt_delete): New function. Delete a memory region.
34
a34abff8
AC
35 * sim-utils.c (sim_elapsed_time_get): Never return zero.
36
37 * sim-core.c (sim_core_detach): New function.
38 (sim_core_map_detach): New function. Perform the actual detach.
39 (sim_core_init): Move initialization code from here.
40 (sim_core_install): To here.
41 (sim_core_uninstall): And here.
42
43 * sim-module.c: Add memopt module.
44
45 * sim-base.h (STATE_MEMOPT, STATE_MEMOPT_P): Add memopt to
46 simulator base type.
47
48 * Make-common.in (sim_main_headers): Add sim-memopt.h
49 (sim-memopt.o): New target.
50
51 * sim-core.c (sim_core_install): Add core_options to the option
52 table.
53
54 * sim-watch.c (watch_options): Make --delete-watch a synonym for
55 --watch-delete.
56
57 * sim-config.h (WITH_MODULO_MEMORY): Define as 0. Update
58 comments.
59
60 * sim-core.h (struct _sim_core_mapping): Change nr_bytes to type
61 address_word, add mask member.
62
63 * sim-core.h, sim-core.c (sim_core_attach): Make nr_bytes of type
64 address_word, allow for 64bit targets in 32bit host. Add modulo
65 argument.
66 (sim_core_map_attach): Ditto.
67 (new_sim_core_mapping): Ditto.
68 (sim_core_translate): Mask address when modulo memory.
69
88d5f8e8
DE
70Wed Sep 3 17:32:54 1997 Doug Evans <dje@seba.cygnus.com>
71
600d8331
DE
72 * sim-hload.c (sim_load): Add assert for SIM_MAGIC_NUMBER.
73
88d5f8e8
DE
74 * gdbinit.in: New file.
75 * aclocal.m4 (SIM_AC_OUTPUT): Build .gdbinit.
76 * Make-common.in (distclean): Delete .gdbinit.
77 (.gdbinit): Add rule for.
78 * configure: Regenerated to track ../common/aclocal.m4 changes.
79
80 * Make-common.in (cgen-run.o): Add rule for.
81
fdd64f95
AC
82Wed Sep 3 10:08:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
83
84 * sim-resume.c (sim_resume): Suspend/resume the simulator.
85
86 * sim-events.c (sim_watch_valid): Compute total elapsed time from
87 both resumed and previous elapsed time.
88 (sim_events_init): Set initial_wallclock and current_wallclock to
89 zero.
90 (sim_events_install): Install sim_events_suspend and
91 sim_events_resume.
92 (sim_events_watch_clock): Allow for suspended simulator when
93 computing the time of the clock event.
94
95 * sim-events.h (struct _sim_event): Add resume_wallclock, rename
96 initial_wallclock to elapsed_wallclock, set both to zero.
97 (sim_events_init, sim_events_uninstall): Delete prototypes.
98
99 * sim-module.h (MODULE_SUSPEND_FN, MODULE_RESUME_FN): Define types.
100
101 * sim-module.c(sim_module_resume, sim_module_suspend): New
102 functions.
103
80c651f0
AC
104Wed Sep 3 10:08:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
105
106 * sim-core.c (sim_core_map_attach): Clarify memory overlap error
107 message.
108
74db699d
DE
109Tue Sep 2 14:57:06 1997 Doug Evans <dje@canuck.cygnus.com>
110
111 * Makefile.in (TAGS): Add support for "/* TAGS: foo */" marker.
645ab3ec 112 * Make-common.in (TAGS): Likewise.
74db699d
DE
113 * sim-n-bits.h: Add TAGS comments for all functions.
114 * sim-n-core.h: Likewise.
115 * sim-n-endian.h: Likewise.
116
4b2a6aed
AC
117Mon Sep 1 10:50:11 1997 Andrew Cagney <cagney@b1.cygnus.com>
118
119 * sim-utils.c (sim_state_alloc): Set CPU backlinks, callback and
120 kind.
121
122 * sim-base.h (sim_state_alloc): Add callback and kind arguments.
123
124 * sim-base.h (INVALID_INSTRUCTION_ADDRESS): Add default
125 definition.
126
f90b720b
AC
127Sat Aug 30 09:47:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
128
129 * sim-fpu.c (DP_GARDMSB, ...): Make unsigned.
130 (DP_FRACHIGH, DP_FRACHIGH2, ..): Use MSMASK to avoid LL.
131
132Fri Aug 29 13:37:44 1997 Andrew Cagney <cagney@b1.cygnus.com>
133
134 * sim-core.c (sim_core_map_attach): Cast attach enum to int.
135 (sim_core_xor_read_buffer, sim_core_xor_write_buffer): Make
136 nr_transfered and nr_this_transfer unsigned.
137
138 * sim-events.c (sim_events_tickn): N is signed, as limited to
139 MAXINT.
140
141 * sim-n-endian.h (offset_N): Change size to unsigned.
142
143 * callback.c (os_poll_quit): Add prototypes for kbhit and getkey.
144
145Fri Aug 29 10:10:53 1997 Andrew Cagney <cagney@b1.cygnus.com>
146
147 * sim-utils.c (sim_copy_argv): Delete, replaced by dupargv.
148
149 * sim-options.c (sim_parse_args): Use dupargv.
150
36db8e64
DE
151Thu Aug 28 10:36:34 1997 Doug Evans <dje@canuck.cygnus.com>
152
153 * sim-options.c (standard_option_handler): Use xstrdup, not strdup.
154
18c319ae
AC
155Thu Aug 28 12:09:15 1997 Andrew Cagney <cagney@b1.cygnus.com>
156
157 * sim-base.h (STATE_ARCHITECTURE, STATE_TARGET): Add to simulator
158 base type.
159
160 * sim-options.c (standard_options): Add --architecture=MACHINE and
161 --target=TARGET options.
162 (OPTION_ARCHITECTURE, OPTION_TARGET): Define.
163 (standard_option_handler): Handle architecture and target options.
164 (bfd.h): Include.
165
166 * sim-utils.c (sim_analyze_program): Pass STATE_TARGET to
167 bfd_openr.
168 (sim_analyze_program): Set prog_bfd architecture from
169 STATE_ARCHITECTURE if known.
170
88117054
AC
171Wed Aug 27 18:13:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
172
173 * configure: Regenerated to track ../common/aclocal.m4 changes.
174 * config.in: Ditto.
175
176Wed Aug 27 18:11:30 1997 Andrew Cagney <cagney@b1.cygnus.com>
177
178 * aclocal.m4 (enable-sim-warnings): Remove comment stating
179 that option does not apply to certain files.
180
d6fea803
AC
181Wed Aug 27 15:13:04 1997 Andrew Cagney <cagney@b1.cygnus.com>
182
183 * sim-bits.h (LSBIT8, LSBIT16, LSBIT32, LSBIT64, LSBIT, MSBIT8,
184 MSBIT16, MSBIT32, MSBIT64, MSBIT): New macros - single bit as
185 offset from MSB/LSB.
186
187 * sim-endian.h (A1_8, A2_8, A4_8, A1_4, A2_4, A1_2): New macro,
188 access address of sub word quantity of a hosts 16, 32, 64 bit word
189 type.
190 (V1_2, V1_4, V2_4, V1_8, V2_8, V4_8): Ditto for values.
191 (U8_1, U8_2, U8_4, U4_1, U4_2, U2_1): Ditto for set of values.
192 (V2_H1, V2_L1, V4_H2, V4_L2, V8_L4, V8_H4): Given N byte argument,
193 return N*2 byte value with argument in Hi/Lo word. Renamed from
194 V1_H2, V1_L2, V2_H4, V2_L4, V4_H8, V4_L8.
195
196 * sim-alu.h (ALU32_HAD_OVERFLOW): Use 64 bit mask not 32bit.
197 (ALU16_HAD_CARRY, ALU32_HAD_CARRY, ALU16_HAD_OVERFLOW): Use MSBIT
198 so that bit offset is explicit.
199
fafce69a
AC
200Wed Aug 27 11:55:35 1997 Andrew Cagney <cagney@b1.cygnus.com>
201
202 * sim-utils.c (sim_analyze_program): Add prog_name argument.
203 Update STATE_PROG_BFD when needed with a dup'd copy of the
204 program.
205
206 * sim-config.c (sim_config): Delete ABFD argument, use
207 STATE_PROG_BFD directly.
208
209Tue Aug 26 12:55:26 1997 Andrew Cagney <cagney@b1.cygnus.com>
210
211 * run.c (main): Pass the open ABFD to sim_create_inferior.
212
213 * nrun.c (main): Determine prog_bfd. Pass to sim_create_inferior
214 and sim_load.
215 (bfd.h): Include.
216
217 * sim-hload.c (sim_load): New file. Implement generic sim_load for
218 hardware only simulator targets.
219
220 * Make-common.in (sim-hload.o): Add rule.
221
d07dddd2
AC
222Wed Aug 27 09:51:42 1997 Andrew Cagney <cagney@b1.cygnus.com>
223
224 * sim-utils.c (sim_copy_argv): Rewrite to match malloc strategy
225 used by copyargv and freeargv.
226
227 * sim-options.c (sim_parse_args): Save a copy of PROG-ARGS in
228 STATE_PROG_ARGV, not just a pointer.
229
247fccde
AC
230Mon Aug 25 17:50:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
231
232 * configure: Regenerated to track ../common/aclocal.m4 changes.
233 * config.in: Ditto.
234
235Mon Aug 25 12:11:06 1997 Andrew Cagney <cagney@b1.cygnus.com>
236
237 * aclocal.m4 (sim-endian): Add second argument to
238 SIM_AC_OPTION_ENDIAN. First is hardwired endian, second is
239 default endian when not hardwired.
240
241 * sim-config.h (WITH_DEFAULT_TARGET_BYTE_ORDER): New macro, if all
242 else failes value for target byte order.
243
244 * sim-config.c (sim_config): Add abfd arguments. Set
245 STATE_PROG_BFD accordingly. Determine prefered_target_byte_order
246 from same.
247 (sim_config): Return SIM_RC, don't abort.
248 (bfd.h): Include.
249
250 * run.c (main): Update call to sim_open - add ABFD argument.
251 * nrun.c (main): Add NULL ABFD argument.
252
052d7984
DE
253Thu Aug 14 12:48:57 1997 Doug Evans <dje@canuck.cygnus.com>
254
255 * callback.c (os_poll_quit): Make static.
256 Call sim_cb_eprintf, not p->eprintf.
257 (sim_cb_printf, sim_cb_eprintf): New functions.
247fccde
AC
258 * sim-utils.h (sim_cb_printf, sim_cb_eprintf): Declare.
259
260 * sim-basics.h (zalloc,zfree,sim_add_commas,SIM_ELAPSED_TIME,
261 sim_elapsed_time_get,sim_elapsed_time_since): Move decls to
262 sim-utils.h. #include sim-utils.h.
263 * sim-utils.h: Above decls moved here.
264 (sim_analyze_program,sim_load_file): Use `struct _bfd', not `bfd'.
265
266 * sim-watch.c (action_watchpoint): Fix thinkos.
052d7984
DE
267
268Thu Jul 24 08:48:05 1997 Stu Grossman (grossman@critters.cygnus.com)
269
270 * sim-types.h: Fix defs of 64 bit data types for MSVC.
271
e6609d8f
DE
272Tue Jul 22 10:35:37 1997 Doug Evans <dje@canuck.cygnus.com>
273
274 * sim-n-core.h (sim_core_write_unaligned_N): Add missing break
275 to FORCED_ALIGNMENT case.
276
84e8cd0f
AC
277Thu Jun 5 13:48:37 1997 Andrew Cagney <cagney@b1.cygnus.com>
278
279 * callback.c (target_to_host_open): Handle hosts with O_BINARY.
280
281Thu Jun 5 08:47:10 1997 Jeffrey A Law (law@cygnus.com)
282
283 * Make-common.in (libsim.a): Fix typo.
284
897f67b7
AC
285Thu Jun 5 13:48:37 1997 Andrew Cagney <cagney@b1.cygnus.com>
286
287 * nrun.c (main): Verify the structure returned before using it.
288
896eab00
AC
289Wed Jun 4 11:44:06 1997 Andrew Cagney <cagney@b1.cygnus.com>
290
291 * sim-config.h (WITH_ENGINE): Enable the sim-engine module by
292 default.
293
294 * sim-engine.c (sim_engine_install): New function. Install the
295 engine init functions.
296 (sim_engine_init): [Re]initialize the simulator engine.
297
298 * sim-module.c: Add sim_engine to list of modules that always
299 install.
300
56e7c849
AC
301Tue Jun 3 04:52:04 1997 Andrew Cagney <cagney@b1.cygnus.com>
302
303 * sim-watch.c (schedule_watchpoint): Use sim_unschedule_watchpoint
304 to remove the old watchpoint, not delete_watchpoint.
305 (watch_option_handler): Action the correct watchpoint, not just
306 cycles.
307
308Wed May 28 14:47:41 1997 Andrew Cagney <cagney@b1.cygnus.com>
309
310 * sim-n-core.h (sim_core_write_aligned_N): For 8byte reads, output
311 both low and high word.
312 (sim_core_write_aligned_N): Ditto.
313
314 * sim-trace.c (set_trace_options): Delete code explicitly setting
315 core->trace.
316
317 * sim-options.c (sim_print_help): Call the list commands if not a
318 standalone simulator.
319 (sim_print_help): Advise that some options may not be applicable.
320
321 * sim-trace.c (set_trace_options): Assume core present.
322
323 * sim-events.c (sim_events_schedule_after_signal): Overflow signal
324 buffer when full not almost full.
325
2f2e6c5d
AC
326Tue May 27 14:32:00 1997 Andrew Cagney <cagney@b1.cygnus.com>
327
1a70e182
AC
328 * sim-events.c (sim_events_process): Don't blat the event queue
329 when processing watchpoints.
330
331 * sim-watch.h: Make arg unsigned long - stop sign extension.
332
333 * sim-events.c (sim_watch_valid): rewrite so debugable.
334
335 * sim-config.h (WITH_XOR_ENDIAN): Default to zero.
336
2f2e6c5d
AC
337 * sim-watch.c (schedule_watchpoint): Add is_within option so that
338 inequality test is possible.
339 (handle_watchpoint): Re-pass is_within arg.
340 (watch_option_handler): When `!' prefix to pc-watchpoint arg pass
341 0 to schedule_watchpoint's is_within arg.
342 (sim_watchpoint_init): Re-pass is_within arg.
343
344 * sim-options.c (sim_print_help): Add is_command argument. Don't
345 include -- prefix when called from the command line interpreter.
346
347 * sim-watch.c (schedule_watchpoint): Pass true is_within argument.
348
349 * sim-events.c (sim_events_watch_sim): Add is_within argument,
350 zero indicates that the test should be reversed.
351 (sim_events_watch_core): Ditto.
352 (WATCH_CORE): Compare range against is_within.
353 (WATCH_SIM): Ditto.
354
355Tue May 27 12:48:03 1997 Andrew Cagney <cagney@b2.cygnus.com>
356
357 * sim-events.c (WATCH_CORE): Pass NULL cpu argument to
358 sim_core_read_buffer. Check nr-bytes transfered.
359
360 * sim-core.h (sim_core_common): Define a new struct that contains
361 the common data. to sd and cpu structures.
362 * sim-core.c (sim_core_attach): Update.
363 (sim_core_init): Update. Remember to copy initialized data to each
364 cpu.
365 (sim_core_find_mapping): Ditto.
366
367 * sim-core.c (sim_core_read_buffer): Add cpu argument.
368 (sim_core_write_buffer): Ditto.
369
370 * sim-n-core.h (sim_core_read_unaligned_N): When mis-aligned
371 transfer use xor version of read buffer.
372 (sim_core_write_unaligned_N): Ditto for write.
373
374 * sim-core.c (sim_core_xor_read_buffer): New function implement
375 xor-endian data read breaking transfer up into xor-endian sized
376 blocks.
377 (sim_core_xor_write_buffer): Ditto for write.
378 (reverse_n): Reverse order of arbitrary number of bytes in buffer
379 - needed for xor-endian transfers.
380
cd0d873d
AC
381Fri May 23 14:24:31 1997 Andrew Cagney <cagney@b1.cygnus.com>
382
383 * sim-inline.h: Review description.
384
385 * sim-core.h, sim-core.c: Reduce number of functions being inlined
386 to just those involved in data transfers and configuration.
387
388 * sim-xcat.h (XSTRING): New macro, map macro definition onto
389 string.
390 * sim-n-core.h (sim_core_read_aligned_N): Use.
391 (sim_core_read_unaligned_N): Ditto.
392 (sim_core_read_unaligned_N): Ditto..
393 (sim_core_write_unaligned_N): Ditto.
394
395 * sim-core.h: Add xor endian bitmap to main structure. *
396
397 sim-n-core.h (sim_core_write_aligned_N): Add suport for xor
398 endian.
399 (sim_core_read_aligned_N): Ditto.
400
401 * sim-core.c (sim_core_set_xor_endian): New function.
402 (sim_core_attach): Don't overwrite the per-cpu xor map when
403 cloning the global core.
404
8167e102
AC
405Fri May 23 10:53:13 1997 Andrew Cagney <cagney@b1.cygnus.com>
406
407 * sim-engine.h: Update below so that it is using an enumerated
408 type.
409
6e61ecfc
GRK
410Thu May 22 09:12:16 1997 Gavin Koch <gavin@cygnus.com>
411
412 * sim-engine.c (sim_engine_restart):
413 * sim-resume.c (sim_resume): Change longjmp param/setjmp
414 return value used for simulator restart from 0 to 2.
415
50a2a691
AC
416Wed May 21 08:47:30 1997 Andrew Cagney <cagney@b1.cygnus.com>
417
418 * cgen-scache.c (scache_option_handler): Add is_command arg.
419
420 * sim-model.c (model_option_handler): Add is_command argument.
421
422 * sim-profile.c (profile_option_handler): Add is_command arg.
423
424 * sim-events.c (sim_watch_valid): Use ub64, lb64 when 64bit value
425 involved.
426
427 * sim-module.c (sim_module_add_init_fn): Call init fn in the same
428 order that they are registered.
429
430 * sim-options.h (OPTION_HANDLER): Add argument to differentiate
431 between option and command line processing.
432
433 * sim-options.c: Include stdlib.h, ctype.h.
434
435 * Make-common.in (sim-watch.o): Add rule.
436 (sim_main_headers): Assume sim-assert.h included.
437 (sim-*.o): Simplify make rule.
438
439 * sim-module.c: Add sim_watch_install to module list.
440
441Tue May 20 14:15:23 1997 Andrew Cagney <cagney@b1.cygnus.com>
442
443 * sim-base.h (STATE_LOADED_P): New predicate. Set once everything
444 has been loaded.
445
446 * sim-trace.c (trace_install): Check magic. Include sim-assert.h.
447 * sim-events.c (sim_events_install): Ditto.
448 * sim-core.c (sim_core_install): Ditto.
449 * sim-model.c (model_install): Ditto.
450 * sim-options.c (standard_install): Ditto.
451 * sim-profile.c (profile_install): Ditto.
452 * sim-reason.c (sim_stop_reason): Ditto.
453 * sim-run.c (sim_engine_run): Ditto.
454 * sim-utils.c (sim_analyze_program): Ditto.
455
456 * sim-module.c (modules): Make profile_install and trace_install
457 optional.
458
459 * sim-base.h (STATE_MEM_BASE): Define for flat memory systems.
460
461 * sim-options.c (standard_option_handler): Set the byte order.
462
463 * sim-events.c (sim_events_process): Allow multi tick processing.
464 (sim_events_tickn): New function - multi cycle tick.
465
466 * sim-events.h (sim_events_tickn, sim_events_timewarp): Add
467 prototypes. Under development.
468 (sim_events): Replace processing with nr_ticks_to_process.
469
470Tue May 20 09:39:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
471
472 * nrun.c (main): Pass callbacks to sim_open instead of using
473 sim_set_callbacks.
474
475 * run.c (main): Ditto.
476
f03b093c
AC
477Mon May 19 12:07:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
478
fd76456b
AC
479 * sim-events.c (sim_events_zalloc): Signal save memory allocator -
480 stop tk interrupting malloc calls.
481 (sim_events_zalloc): Converse.
482
483 * Make-common.in (sim_main_headers): Add sim-events.h.
484
485 * sim-events.c (sim_events_schedule_after_signal): Change return
486 type to void - signal events are strictly internal.
487 (sim_events_init): Allocate a finite buffer for signal events.
488 (sim_events_schedule_after_signal): Enter signal events into the
489 signal buffer.
490
491 * sim-engine.c (sim_engine_halt): Check SIM_DESC magic.
492 (sim_engine_restart): Ditto.
493 (sim_engine_abort): Ditto.
494 * sim-stop.c (sim_stop): Ditto.
495 (control_c_simulation): Ditto.
496 * sim-resume.c (sim_resume): Ditto.
497 (has_stepped): Ditto.
498 * sim-abort.c (sim_engine_abort): Ditto.
499
f03b093c
AC
500 * sim-basics.h (transfer_type): New type.
501
502 * sim-core.c (sim_core_signal): New function. Print core signal
503 information.
504 (sim_core_find_mapping): Add transfer argument.
505
506 * sim-n-core.h (sim_core_{write,write}_unaligned_N): Call
507 SIM_CORE_SIGNAL if a recoverable abort.
508 * sim-core.c (sim_core_find_mapping): Ditto.
509
510Fri May 16 15:13:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
511
512 * sim-core.c (sim_core_find_mapping): Replace calls to
513 sim_io_error to more resiliant sim_engine_abort.
514
515 * sim-n-core.h (sim_core_read_unaligned_N): Ditto.
516 (sim_core_write_unaligned_N): Ditto.
517
518Tue May 13 13:50:06 1997 Andrew Cagney <cagney@b1.cygnus.com>
519
520 * sim-module.c: Add sim_events_install to list.
521
522 * sim-events.c (sim_events_install, sim_events_uninstall): Clonse
523 from sim_core_*.
524 (sim_events_init): Now returns SIG_RC.
525
526 * sim-run.c: New file. Generic sim_engine_run.
527 * sim-reason.c: New file. Generic sim_stop_reason.
528 * sim-stop.c: New file. Generic sim_stop.
529 * sim-resume.c: New file. Generic sim_resume.
530
531 * Make-common.in (sim-engine.o): Add rule.
532 (sim-run.o, sim-reason.o, sim-stop.o, sim-resume.o): Ditto.
533
534 * sim-engine.h, sim-engine.c: New file. Provide generic
535 implementation of sim_engine_halt, sim_engine_error. et.al.
536
537 * sim-base.h (sim_state_base): Add member halt.
538 (sim-engine.h): Include.
539
540 * sim-events.h (sim_event_handler): Always pass SIM_DESC to event
541 handlers.
542 * sim-events.c (sim_events_poll): Update event handler.
543
544Tue May 13 09:57:49 1997 Andrew Cagney <cagney@b2.cygnus.com>
545
546 * sim-events.h, sim-events.c (sim_events_watch_clock): New
547 function.
548 (sim_events_watch_sim): New function.
549 (sim_events_watch_core): New function.
550 (sim_watch_valid): New function.
551 (sim_events_preprocess): New function.
552 (sim_events_process): Process the watchpoints as well as the timer
553 queue.
554 (sim_events_tick): Check WORK_PENDING instead of the hold queue.
555 (sim_events_deschedule): Check all the queues when removing an
556 event.
557 (sim_events_init): Ditto for cleaning.
558
559Mon May 19 12:07:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
560
561 * sim-fpu.c (is_ufpu_number): Comment out - currently unused.
562
11ab132f
AC
563Mon May 19 11:23:03 1997 Andrew Cagney <cagney@b1.cygnus.com>
564
565 * callback.c (os_open): Type of arg flags is int.
566
63aa80ff
MM
567Fri May 16 22:26:43 1997 Michael Meissner <meissner@cygnus.com>
568
569 * sim-fpu.c (sim_fpu_is_{eq,ne,lt,le,gt,ge}): Compare Infinities
570 just like normal numbers as per IEEE rules.
571
248c1fb8
JL
572Wed May 14 21:20:38 1997 Bob Manson <manson@charmed.cygnus.com>
573
574 * callback.c (os_close): Mark the descriptor as being
575 available if the close succeeded.
576 (os_open): Pass 0644 as the mode of the file being created.
577
d24f06ee
AC
578Thu May 15 10:58:52 1997 Andrew Cagney <cagney@b1.cygnus.com>
579
07b4c0a6
AC
580 * sim-fpu.c (pack_fpu, unpack_fpu): New functions - decode a
581 float.
582
583 * sim-inline.c (SIM_INLINE_C): Rename from _SIM_INLINE_C_.
584 * sim-lnline.h: Update.
585
586 * sim-fpu.h, sim-fpu.c (sim_fpu_[iu]{32,64}to): New int2fp
d24f06ee 587 conversion functions.
07b4c0a6 588 (sim_fpu_to{32,64}[iu]): New fp2int functions.
d24f06ee
AC
589
590 * sim-fpu.h, sim-fpu.c (sim_fpu_is_{lt,le,eq,ne,ge,gt}): New fp
591 compare functions. Replacing.
592 (sim_fpu_cmp): This. Delete.
593
c445af5a
AC
594Mon May 12 14:49:05 1997 Andrew Cagney <cagney@b1.cygnus.com>
595
596 * sim-core.c (sim_core_find_mapping): Call engine_error not
597 sim_io_error when possible.
598
599Mon May 12 08:55:07 1997 Andrew Cagney <cagney@b2.cygnus.com>
600
601 * sim-endian.h (V1_H2): Add macro's to insert a word into a
602 high/low double word.
603
604 * sim-trace.h: Remove definition of attribute - defined in
605 sim_basics.h.
606
e05e76e8
AC
607Mon May 12 08:55:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
608
609 * sim-options.h (struct OPTION): Add doc_opt as the documenting
610 name of the option - or family of options.
611
612 * sim-options.c (sim_args_command): Match command `a-b c' with
613 option `--a-b-c' from option table.
614
43c53e07
AC
615Thu May 8 12:40:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
616
617 * sim-options.c (sim_print_help): For optional arguments, wrap
618 them in [].
619
620 * sim-trace.c (set_trace_options): New function, handle optional
621 argument and multiple assignment.
622 (trace_option_handler): Update.
623
624 * sim-trace.c (trace_option_handler): Trace branch and not fpu
625 when branch tracing selected.
626
381f42ef
AC
627Wed May 7 15:19:58 1997 Andrew Cagney <cagney@b1.cygnus.com>
628
629 * sim-trace.c (trace_one_insn): Make a va-args function.
630
631 * sim-trace.c (trace_vprintf): New function, va-arg version of
632 trace_printf.
633
ea4e4493
DE
634Tue May 6 16:38:16 1997 Doug Evans <dje@canuck.cygnus.com>
635
636 * sim-trace.c (trace_uninstall): Don't close a file twice.
bd3274c6 637 * sim-profile.c (profile_uninstall): Likewise.
ea4e4493 638
a7724171
MM
639Tue May 6 06:14:01 1997 Mike Meissner <meissner@cygnus.com>
640
641 * sim-trace.c (toplevel): Include bfd.h.
642 (trace_options): Note that --trace-linenum also turns on
7b167b09 643 --trace-insn. Add --trace-{branch,semantics}.
a7724171 644 (trace_option_handler): If --trace-linenum, also turn on
7b167b09
MM
645 --trace-insn. Add --trace-branch support. If --trace-semantics,
646 turn on ALU, FPU, branch, and memory tracing.
a7724171
MM
647 (trace_one_insn): New function to trace an instruction. Support
648 --trace-linenum.
7b167b09 649 (OPTION_TRACE_*): Use an enum, rather than lots of defines.
a7724171 650
7b167b09
MM
651 * sim-trace.h (TRACE_{SEMANTICS,BRANCH}_IDX): Add new macros.
652 (MAX_TRACE_VALUES): Use 32, not 12 by default.
653 (TRACE_branch): Add new mask.
654 (TRACE_*_P): Define all possible trace_p macros.
a7724171
MM
655 (trace_one_insn): Declare function.
656
23b04e79
MM
657Mon May 5 14:08:34 1997 Mike Meissner <meissner@cygnus.com>
658
659 * sim-trace.h (__attribute__): Define as nothing if not GNU C or
660 GNU C doesn't support __attributes__.
661 ({trace,debug}_printf): Add attribute's so -Wformat can check the
662 format strings.
663
7a418800
AC
664Mon May 5 11:16:12 1997 Andrew Cagney <cagney@b1.cygnus.com>
665
666 * sim-config.h (FORCED_ALIGNMENT): New alignment option -
667 addresses are masked forcing them to be correctly aligned.
668 (WITH_ALIGNMENT): Make NONSTRICT_ALIGNMENT the default.
669 * sim-config.c (config_alignment_to_a): Update.
670
671 * sim-core.h (sim_cpu_core): New data type contains cpu specific
672 core data.
673 * sim-base.h (CPU_CORE): Add cpu specific core data to cpu base
674 type.
675 * sim-core.c (sim_core_attach): Add CPU argument. Ready for
676 processor specific core maps.
677 (sim_core_map_attach): Copy the core map data to each of the
678 processor specific core data structures.
679 * sim-core.c (sim_core_find_mapping): Update.
680
681 * sim-n-core.h (sim_core_read_N, sim_core_write_N): Rename.
682 (sim_core_write_aligned_N, sim_core_write_aligned_N): New names.
683 (sim_core_write_unaligned_N, sim_core_write_unaligned_N): New
684 alternatives that handle unaligned addresses.
685 (sim_core_{read,write}_{,un}aligned_N): Drop SIM_DESC arg, replace
686 with just CPU arg.
687 * cgen-utils.c (sim_disassemble_insn): Update.
688
3971886a
AC
689Mon May 5 13:19:16 1997 Andrew Cagney <cagney@b1.cygnus.com>
690
691 * sim-trace.h (TRACE_FPU_IDX): Add Floating-point specific
692 tracing.
693
694 * sim-fpu.h, sim-fpu.c: New files - prototype for generic target
695 fpu support.
696
697 * sim-inline.h, sim-inline.c: Add support for SIM_FPU.
698
1fe05280
AC
699Fri May 2 17:59:42 1997 Andrew Cagney <cagney@b1.cygnus.com>
700
701 * sim-core.c (sim_core_map_to_str): New function ascii equivalent
702 to map type.
703
704 * sim-n-core.h (sim_core_read_N, sim_core_write_N): Use in trace
705 statement.
706
707Fri May 2 17:28:02 1997 Andrew Cagney <cagney@b2.cygnus.com>
708
709 * cgen-trace.c: Prepend additional trace_printf argument.
710
711 * cgen-utils.c (sim_disassemble_insn): Add additional core
712 arguments.
713
714Fri May 2 11:40:23 1997 Andrew Cagney <cagney@b1.cygnus.com>
715
716 * nrun.c (main): Catch/report errorenous simulator states.
717
718 * sim-module.c: #include "libiberty.h" so that xmalloc is defined.
719 * sim-trace.c: #include string.h/strings.h so that memset is
720 defined.
721 * sim-utils.c: Ditto.
722 * sim-profile.c: Ditto. And stdlib.h.
723 (print_bar): Only define when used by instruction or memory profiler.
724
725 * sim-options.c (standard_option_handler): Make ul more local.
726
727 * sim-load.c (sim_load_file): Make the name constant.
728 (sim_load_file): Passify gcc.
729
730 * sim-utils.h: New file, pre-declare utilites in corresponding .c
731 file.
732 * sim-utils.c, sim-load.c: Include sim-utils.h.
733
734 * sim-base.h (sim_cpu): Pre define here so available to all.
735
736 * sim-core.h (DECLARE_SIM_CORE_WRITE_N, DECLARE_SIM_CORE_READ_N):
737 Restore the sim_cpu and instruction_address arguments so that full
738 information is available to the abort function.
739 * sim-core.c (sim_core_find_mapping, sim_core_write_buffer): Ditto.
740 * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
741
742 * sim-trace.h, sim-trace.c (trace_option_handler): Add interim
743 tracing support for sim-events and sim-core.
744 (trace_option_handler): Convert #if to if where possible so always
745 compiled/checked by C compiler.
746 * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
747
748 * sim-base.h: Adjust comment documenting how to define the cpu
749 structure.
750 (sim_state_base): Add sim_core and sim_events to simulator base
751 object.
752
753 * sim-trace.h, sim-trace.c (trace_printf): Add SIM_DESC argument.
754 * sim-core.c (sim_core_init, sim_core_attach,
755 sim_core_find_mapping): Update.
756 * sim-events.c (ETRACE, sim_events_init, sim_events_time,
757 update_time_from_event, insert_sim_event,
758 sim_events_schedule_after_signal, sim_events_deschedule,
759 sim_events_tick): Ditto.
760
761 * sim-basics.h (sim-module.h, sim-trace.h, sim-profile.h,
762 sim-model.h): Move #includes from here.
763 * sim-base.h: To here.
764 (sim-core.h, sim-events.h, sim-io.h): Include also
765
766Wed Apr 30 15:37:54 1997 Andrew Cagney <cagney@b1.cygnus.com>
767
768 * callback.c (default_callback): Missing initialisers.
769
c967f187
DE
770Thu May 1 10:40:47 1997 Doug Evans <dje@canuck.cygnus.com>
771
2317a499
DE
772 * sim-utils.c (sim_add_commas): New function.
773 * sim-basics.h (sim_add_commas): Add prototype.
774 * cgen-scache.c (scache_print_profile): Print commas in numbers.
775 * sim-profile.c (COMMAS): New macro.
776 (print_*): Use it to print commas in numbers.
777
260b2c47
DE
778 * configure: Regenerated.
779
780 * cgen-sim.h (sim_signal_type): Add SIM_SIGINT.
781 (cgen_state): New member run_fast_p.
782 (cgen_init): Add prototype.
783 (sim_disassemble_insn): New arg `cpu'.
784 * cgen-trace.c (trace_insn): Update call to sim_disassemble_insn.
785 * cgen-utils.c (cgen_init): New function.
786 (sim_disassemble_insn): New arg `cpu'. Rewrite fetching of insn.
787 * genmloop.sh: Call engine_halt if loop exits.
788
c967f187
DE
789 * Makefile.in (sim-options_h): Define.
790 (sim-{module,options,trace,profile,utils}.o): Clean up dependencies.
791 (sim-model.o): Add new rule.
792 (cgen-{scache,trace,utils}.o): Add new rules.
793 * aclocal.m4 (SIM_AC_OPTION_{SCACHE,DEFAULT_MODEL}): Add.
794 * cgen-scache.c (scache_print_profile): Change `sd' arg to `cpu'.
795 Indent output by 2 spaces.
796 * cgen-scache.h (scache_print_profile): Update.
797 * cgen-trace.c (trace_insn_fini): Indent output by 2 spaces.
798 Use trace_printf, not fprintf.
799 (trace_extract): Use trace_printf, not cgen_trace_printf.
800 * genmloop.sh (!FAST case): Increment `insn_count'.
801 * sim-base.h (sim_state_base): Only include scache_size if WITH_SCACHE.
802 (sim_cpu_base): Rename member `sd' to `state' to be consistent with
803 access macro's name.
804 * sim-core.c (sim_core_init): Use EXTERN_SIM_CORE to define it.
805 Change return type to SIM_RC.
806 (sim_core_{install,uninstall}): New functions.
807 * sim-core.h (sim_core_{install,uninstall}): Declare.
808 (sim_core_init): Use EXTERN_SIM_CORE to define it.
809 Change return type to SIM_RC.
810 * sim-model.h (models,machs,model_install): Declare.
811 * sim-module.c (modules): Add scache_install, model_install.
812 (sim_post_argv_init): Set cpu->state backlinks.
813 * sim-options.c (standard_options): Delete --simcache-size,--max-insns.
814 (standard_option_handler): Likewise.
815 * sim-profile.c (PROFILE_{HISTOGRAM,LABEL}_WIDTH): Move to
816 sim-profile.h.
817 (*): Assume ANSI C.
818 (profile_options): Delete --profile-simcache.
819 (profile_option_handler): Likewise.
820 (profile_print_insn): Change `sd' arg to `cpu'. Indent output 2
821 spaces.
822 (profile_print_{memory,model}): Likewise.
823 (profile_print_simcache): Delete.
824 (profile_print_speed): New function.
825 (profile_print): Rewrite.
826 * sim-profile.h (PROFILE_scache): Renamed from PROFILE_simcache.
827 (WITH_PROFILE_SCACHE_P): Renamed from WITH_PROFILE_SIMCACHE_P.
828 (PROFILE_DATA): Delete members simcache_{hits,misses}.
829 (PROFILE_COUNT_SIMCACHE_{HIT,MISS}): Delete.
830 (PROFILE_{CALLBACK,CPU_CALLBACK}): New types.
831 (profile_print): Update prototype.
832
717dbb29
DE
833Wed Apr 30 11:34:14 1997 Doug Evans <dje@canuck.cygnus.com>
834
6475b234 835 * cgen-scache.[ch], cgen-sim.h: New files.
b9c8cd10
DE
836 * cgen-trace.[ch], cgen-types.h, cgen-utils.c, genmloop.sh: New files.
837 * sim-model.c: New file.
838
717dbb29
DE
839 * Make-common.in (clean targets): Undo patch of Apr. 22.
840
841Fri Apr 25 15:28:32 1997 Mike Meissner <meissner@cygnus.com>
842
843 * sim-n-bits.h (signed): If we have a standard compiler, undef
844 signed, so that signedN is defined correctly.
845
b320601b
DE
846Thu Apr 24 00:00:07 1997 Doug Evans <dje@canuck.cygnus.com>
847
848 * sim-module.h, sim-model.h, sim-profile.h: New files.
849 * sim-module.c, sim-profile.c: New files.
850 * Make-common.in (SIM_PROFILE): Define
851 (CONFIG_CFLAGS): Add $(SIM_PROFILE).
852 (sim_main_headers): Add sim-module.h, sim-model.h, sim-profile.h.
853 (sim_module.o,sim-profile.o): Add rules for.
854 * aclocal.m4 (--enable-sim-trace): Allow symbolic arguments.
855 (--enable-sim-profile): Add.
856 * configure: Regenerated.
857 * sim-base.h (sim_state_base): New members init_list, uninstall_list,
858 model. Move trace and profile support to sim-{trace,profile}.h.
859 New members trace_data, profile_data.
860 * sim-basics.h: #include sim-module.h, sim-model.h, sim-profile.h.
861 * sim-config.h: Provide default definition of WITH_PROFILE.
862 (WITH_TRACE): Change default to -1.
863 (MAX_NR_PROCESSORS): Always define.
864 * sim-options.c: Move trace and profile support to
865 sim-{trace,profile}.h.
866 (sim_pre_argv_init): Moved to sim-model.c.
867 (standard_install): New function.
868 * sim-options.h (sim_pre_argv_init): Move decl to sim-model.c.
869 (standard_install): Declare.
870 * sim-trace.c: Tracing option handling moved here from sim-options.c.
871 (trace_install, trace_uninstall): New functions.
872 (trace_printf): Update reference to TRACE_FILE.
873 * sim-trace.h (TRACE_FOO_IDX): Moved here from sim-base.h.
874 (TRACE_foo): Bit masks for symbolic arguments to --enable-sim-trace.
875 (WITH_TRACE_FOO_P): Define.
876 (trace_install): Declare.
877 (TRACE_DATA): New struct.
878
ef751fb0
DE
879Wed Apr 23 17:23:15 1997 Doug Evans <dje@canuck.cygnus.com>
880
881 * run.c: Undo last exec_bfd patch.
882 (main): Only pass -E ifdef SIM_HAVE_BIENDIAN.
883
e3eba3fd
MM
884Wed Apr 23 17:54:27 1997 Mike Meissner <meissner@cygnus.com>
885
886 * run.c (exec_bfd): Add back in.
887 (main): Set exec_bfd.
888
2c27ef78
DE
889Tue Apr 22 14:43:46 1997 Doug Evans <dje@canuck.cygnus.com>
890
891 * sim-load.c (sim_load_file): #include <stdio.h> for NULL.
892
15c16493
AC
893Wed Apr 23 02:55:54 1997 Andrew Cagney <cagney@b1.cygnus.com>
894
895 * sim-events.c (insert_sim_event): Call sim_io_error instead of
896 less well defined engine_error.
897 * sim-core.c: Ditto.
898
0f399b0c
SG
899Tue Apr 22 08:48:16 1997 Stu Grossman (grossman@critters.cygnus.com)
900
901 * Make-common.in: Change clean targets to use :: so that other
902 Makefiles can have their own clean targets.
903 * sim-load.c (xprintf eprintf): Use ANSI_PROTOTYPES instead of
904 __STDC__ to control use of stdarg vs. varargs syntax. Some
905 systems can't use __STDC__, but require stdarg.
906
4a6163db
DE
907Fri Apr 18 11:14:43 1997 Doug Evans <dje@canuck.cygnus.com>
908
e65bd1d8
DE
909 * sim-options.c (standard_options): Add --endian.
910 (standard_option_handler): Likewise.
911
4a6163db
DE
912 * nrun.c: #include <signal.h>.
913 (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
914 handler that calls sim_stop ().
915
8517f62b
AC
916Fri Apr 18 13:11:36 1997 Andrew Cagney <cagney@b1.cygnus.com>
917
918 * run.c (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
919 handler that calls sim_stop (). Simulators may still be
920 establishing their own handler.
921
922 * sim-events.c (sim_events_poll): Rename from
923 sim_events_at_large_int. Poll IO.
924
925 * sim-io.c (sim_io_poll_quit): New function - pass on a polling
926 request.
927
928 * callback.c (os_poll_quit): New function poll for quit signal
929 where needed.
930 (default_callback): Include magic number.
931
0f2811d1
DE
932Thu Apr 17 02:25:11 1997 Doug Evans <dje@canuck.cygnus.com>
933
63ddb6bd
DE
934 * aclocal.m4: Check for headers time.h, sys/time.h, sys/resource.h.
935 Check for functions getrusage, time.
936 * sim-basics.h (SIM_ELAPSED_TIME): New typedef.
937 (sim_elapsed_time_get, sim_elapsed_time_since): Add prototypes.
938 * sim-utils.c: #include time.h, sys/time.h, sys/resource.h if able.
939 (sim_elapsed_time_get, sim_elapsed_time_since): New functions.
940
ba65b2f4
DE
941 * sim-utils.c (sim_copy_argv, sim_analyze_program): New functions.
942
4ede3a83 943 * sim-options.c, sim-options.h: New files.
4b364b00 944 * sim-config.h (WITH_DEBUG): Provide default value of zero.
e9b2f579 945 * Make-common.in (nrun.o): Add rules for.
c95d08a8 946 * nrun.c: New file.
4ede3a83 947
f7d2f538
DE
948 * run.c (main): Check return value of sim_open.
949
e9b2f579 950 * Make-common.in (sim-options.o, sim-load.o, sim-trace.o): Add rules.
0f2811d1
DE
951 (sim_main_headers): Add sim-trace.h.
952 * run.c (exec_bfd, target_byte_order): Delete.
953 (main): Pass -E <endian> to sim_open. Delete code to load sections,
954 call sim_load instead. Check return code of sim_create_inferior.
955 * sim-base.h (CURRENT_STATE): Define.
956 (sim_state_base): Make typedef. New members options, prog_argv,
957 prog_bfd, text_{section,start,end}, start_addr, simcache_size,
958 mem_size, memory [+ corresponding access macros].
959 (sim_cpu_base): New typedef.
960 * sim-trace.h: New file.
e9b2f579 961 * sim-trace.c: New file.
0f2811d1 962 * sim-basics.h: #include it.
35c384f6 963 * sim-load.c: New file.
0f2811d1 964
6808fd61
ILT
965Tue Apr 15 15:10:13 1997 Ian Lance Taylor <ian@cygnus.com>
966
967 * Make-common.in (INSTALL): Set to @INSTALL@.
968 (INSTALL_XFORM, INSTALL_XFORM1): Remove.
969 (install-common): Depend upon installdirs. Use
970 $(program_transform_name) directly, rather than using
971 $(INSTALL_XFORM).
972 (installdirs): New target.
973 * Makefile.in (INSTALL): Set to @INSTALL@.
974 (INSTALL_XFORM, INSTALL_XFORM1): Remove.
975 (install-man): Depend upon installdirs. Use
976 $(program_transform_name) directly, rather than using
977 $(INSTALL_XFORM).
978 (installdirs): New target.
979
7ec396d2
AC
980Tue Apr 15 15:08:12 1997 Andrew Cagney <cagney@b1.cygnus.com>
981
982 * sim-assert.h (SIM_ASSERT, ASSERT): Allow these macros to
983 be overriden.
984
985Wed Apr 9 16:06:44 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
986
987 * sim-basics.h: Only bring in config.h and tconfig.h if
988 HAVE_CONFIG_H.
989
990Mon Apr 7 11:39:45 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
991
992 * sim-config.h (WITH_TARGET_WORD_MSB): New Macro. Define the bit
993 numbering convention of the target.
994 * sim-config.c (print_sim_config): Print WITH_TARGET_WORD_BITSIZE
995 and WITH_TARGET_WORD_MSB.
996 (sim_config): When possible, check for consistency with bitsize
997 and msb.
998
999 * sim-bits.h: Allow MSB to be other than zero.
1000 * sim-bits.c: Ditto.
1001 * sim-n-bits.h: Ditto.
1002
1003 * sim-bits.h (MSMASK*): New macros - converce to LSMASK*.
1004 * sim-n-bits.h (MSMASKEDn): Ditto.
1005
1006Mon Apr 14 16:29:21 1997 Ian Lance Taylor <ian@cygnus.com>
1007
1008 * Makefile.in (INSTALL): Change install.sh to install-sh.
1009
25a9c90b
DE
1010Mon Apr 7 10:46:38 1997 Doug Evans <dje@canuck.cygnus.com>
1011
1012 * sim-base.h (sim_state_base): Move `magic' to end of struct.
1013
b4d88827
AC
1014Mon Apr 7 15:53:21 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1015
1016 * run.c (main): Check that a program to run was specified.
1017
08db4a65
AC
1018Mon Apr 7 15:45:02 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1019
1020 * aclocal.m4 (AC_TYPE_SIGNAL): Add check.
1021
1022 * configure: Regenerated to track ../common/aclocal.m4 changes.
1023 * config.in: Ditto.
1024
fbda74b1
DE
1025Wed Apr 2 15:06:28 1997 Doug Evans <dje@canuck.cygnus.com>
1026
21bfad86
DE
1027 * sim-endian.h: Move host {LITTLE,BIG}_ENDIAN support from here,
1028 * sim-config.h: To here.
1029
00d74d3e
DE
1030 * Make-common.in (SIM_EXTRA_DEPS): New config var.
1031 (sim_main_headers): Define.
1032 (sim-*.o): Depend on $(SIM_EXTRA_DEPS).
1033 (BUILT_SRC_FROM_COMMON): Move here from ../d30v/Makefile.in.
1034 (clean): Use it.
1035 (sim-utils.o): Add rule for.
1036 * sim-utils.o: New file.
1037 * sim-basics.h: #include sim-base.h.
1038 (zalloc): Make argument unsigned long.
1039 * sim-base.h: New file.
1040 * sim-inline.h (SIM_IO support): Delete.
1041 * sim-io.h: Delete inline support.
1042 * sim-io.c: Likewise. sim-state.h renamed to sim-main.h.
1043 * sim-config.c: sim-state.h renamed to sim-main.h.
1044 * sim-core.c: Likewise.
1045 * sim-events.c: Likewise.
1046
bcd1475a
DE
1047 * run.c (main): Pass SIM_OPEN_STANDALONE to sim_open.
1048
fbda74b1
DE
1049 * aclocal.m4: Check for stdlib.h, string.h, strings.h, unistd.h.
1050 (sim-debug): Allow arguments. Define WITH_DEBUG in addition to
1051 -DDEBUG.
1052 * configure: Regenerated to track ../common/aclocal.m4 changes.
1053
a35e91c3
AC
1054Wed Apr 2 14:34:19 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1055
1056 * configure: Regenerated to track ../common/aclocal.m4 changes.
1057
1058Wed Apr 2 11:08:11 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1059
1060 * sim-config.h (WITH_ALIGNMENT, WITH_FLOATING_POINT,
1061 WITH_XOR_ENDIAN, WITH_SMP, WITH_RESERVED_BITS): Assume that these
1062 are defined by the configure.
1063
1064 * aclocal.m4 (sim-stdio): Add option stdio from ../ppc configure.
1065
1066 * aclocal.m4 (floating-point, xor-endian, alignment, smp,
1067 reserved-bits): Always define.
1068
1069 * sim-config.h, sim-config.c (sim_config): New function - and new
1070 file - co-ordinate the setting/checking of the common simulator
1071 configuration options.
1072
1073 * Make-common.in (sim-config.o): Add rule.
1074
1075Fri Mar 28 15:32:00 1997 Mike Meissner <meissner@cygnus.com>
1076
1077 * callback.c (os_{,e}vprintf_filtered): Change stdarg type to
1078 va_list from void *, since va_list might not be a pointer type.
1079
1080Mon Mar 24 15:27:12 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1081
1082 * sim-n-endian.h (offset_N): Correct assertion - word and sub word
1083 in wrong order.
1084 (offset_N): Correct computation of LE offset.
1085
1086 * sim-io.c (sim_io_error): Include a new line when reporting
1087 errors.
1088
1089 * sim-assert.h (SIM_FILTER_PATH): Out by one when locating last
1090 `/'.
1091
aa7cec3f
JL
1092Thu Mar 20 22:31:06 1997 Jeffrey A Law (law@cygnus.com)
1093
1094 * run.c: Include alloca-conf.h.
7c058c9e
JL
1095
1096 * callback.c (os_evprintf_filtered): Fix typo.
1097
fa21d299
AC
1098Fri Mar 21 13:36:20 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1099
1100 * run.c (string.h, strings.h, stdlib.h): Include.
1101
1102 * sim-events.c (sim_events_tick): Recent cleanup failed to return
1103 0 when nothing pending.
1104
1105 * run.c (sim_size, sim_trace): Plicate GCC - these two functions
1106 will soon be going away.
1107 (getopt): Plicate GCC.
1108
1109 * sim-endian.c (sim-io.h): Plicate GCC.
1110 * sim-bits.c (sim-io.h): Ditto.
1111 * sim-n-bits.h (ROTn): Ditto.
1112
1113 * sim-io.c (sim_io_error): Correct check for NULL.
1114
1115 * sim-assert.h (SIM_FILTER_PATH): Separate out the code filtering
1116 the __FILE__.
1117 * sim-events.c: Use SIM_FILTER_PATH to filter out the filename
1118 path.
1119
1120Wed Mar 19 01:12:06 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1121
1122 * aclocal.m4 (SIM_AC_OPTION_*: Move so that they are outside of
1123 SIM_AC_COMMON - SIM_AC_COMMON was gobling arguments.
1124
4a5fb09d
AC
1125Tue Mar 18 20:48:12 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1126
1127 * sim-alu.h: Include sim-xcat.h.
1128
d11d59ac
AC
1129Tue Mar 18 13:58:18 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1130
1131 * Make-common.in (sim-bits.c, sim-core.c, sim-endian.c,
1132 sim-events.c, sim-inline.c, sim-io.c): Define rules for building
1133 these.
1134
1135 * sim-events.c (sim_events_at_large_int): New function. Just
1136 schedules an event every large-int ticks.
1137 (sim_events_init): Call.
1138 (sim_events_tick, sim_events_process): Move async handing to
1139 sim_events_process. Move timer decrement so that it occures after
1140 events have been processed.
1141
1142 * sim-basics.h (struct _engine): Remove declaration.
1143
1144 * sim-events.h, sim-events.c: Rename type to sim_events. Prefix
1145 everything with same. Rename global struct to SIM_DESC.
1146 * sim-core.h, sim-core.c, sim-n-core.c: Ditto for sim_core.
1147 * sim-io.h, sim-io.c: Ditto.
1148
1149 * sim-assert.h: New file. Optional assertion checking macros.
1150 * sim-io.c (sim_io_error): Make just this function tolerant to
1151 null pointers.
1152
1153 * sim-xcat.h: New file. Define concatenate macros.
1154 * sim-basics.h (XCONCAT*): Move to sim-xcat.h.
1155 * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Explicitly include
1156 concat macros.
1157
1158
752517cc
AC
1159Tue Mar 18 12:44:55 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1160
1161 * sim-bits.h (LSMASK): New macro. Create mask of LS bits.
1162
86eb1e29
AC
1163Mon Mar 17 18:10:05 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1164
1165 * sim-inline.h: Add definitions for sim-types.
1166 (ALL_BY_MODULE): New macro, encapsulate full inlining by the
1167 module.
1168
231de1b8
AC
1169Mon Mar 17 15:38:27 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1170
1171 * sim-events.h: Remove defunct reference to callback struct.
1172
a77aa7ec
AC
1173Mon Mar 17 15:10:07 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1174
1175 * configure: Re-generate.
1176
1177Mon Mar 17 15:04:47 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1178
1179 * Make-common.in (CSEARCH): Do not include the gdb directory in
1180 the search path.
1181
1182Mon Mar 17 13:16:26 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1183
1184 * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
1185 SIM_WARNING): Drop, requiring the simulator specific Makefile.in
1186 to explicitly incorporate these.
1187
1188 * aclocal.m4 (--enable-sim-alignment); New option. Strongly
1189 specify the alignment restrictions of the target architecture -
1190 without this option all alignment restrictions are accomodated.
1191 (--enable-sim-assert): New option. Conditionally compile in
1192 assertion statements.
1193 (--enable-sim-float): New option. Strongly specify the target's
1194 floating point support.
1195 (--enable-sim-hardware): New option. Specify the hardware devices
1196 included in the simulation.
1197 (--enable-sim-packages): New option. Specify the hardware
1198 packages included in the simulation.
1199 (--enable-sim-regparm): New option. Specify that parameters be
1200 passed in registers instead of on the stack.
1201 (--enable-sim-reserved-bits): New option. Specify that reserved
1202 bits within an instruction are are correctly set.
1203 (--enable-sim-smp): New option. Specify the level of SMP support
1204 to be included in the simulator.
1205 (--enable-sim-stdcall): New option. Specify an alternative
1206 function call convention.
1207 (--enable-sim-xor-endian): New option. Configure xor-endian
1208 support used by some targets to implement bi-endian support.
1209
f2de7dfd
AC
1210Fri Mar 14 19:51:21 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1211
1212 * aclocal.m4 (--enable-sim-hostendian): New option. Allow the
1213 host endianness to be overridden.
1214 (--enable-sim-endian): Allow the target platform's byte order
1215 to be overridden.
1216 (--enable-sim-inline): Control the inlining of common components.
1217 (--enable-sim-bswap): For compatibility, also define WITH_BSWAP.
1218 (--enable-sim-warnings): Enable additional GCC compiler checks.
1219 * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
1220 SIM_WARNINGS): Add.
1221
1222 * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Rename from
1223 sim-*-n.h so that the names are uniq on dos machines
1224 * sim-core.c, sim-bits.c, sim-endian.c: Update.
1225
499aa792
DE
1226Thu Mar 13 12:32:42 1997 Doug Evans <dje@canuck.cygnus.com>
1227
1228 * run.c: #include "libiberty.h".
1229 (main): New locals sd,no_args,sim_argv.
1230 Run buildargv on -a option. Pass argv to sim_open, argv[0]
1231 is program name. Update call to sim_set_callbacks.
1232 Record result of sim_open, pass to other sim_foo routines.
1233
fd435e9f
MM
1234Thu Mar 13 10:24:05 1997 Michael Meissner <meissner@cygnus.com>
1235
1236 * callback.c (os_printf_filtered): Do not call exit(1) or print a
1237 final newline.
1238
1239Thu Mar 6 15:50:28 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1240
1241 * callback.c: Add os_flush_stdout and vprintf_filtered callbacks.
1242 Route stdout through buffered IO.
1243
1244 * callback.c: Add os_flush_stderr, os_write_stderr,
1245 os_evprintf_filtered functions to route error output through
1246 stderr.
1247
1248 * sim-io.h, sim-io.c (sim_io_flush_stderr, sim_io_flush_stdout):
1249 Correct return type - should be void.
1250
1251Fri Mar 7 20:14:37 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1252
1253 * sim-basics.h: Clean up. Many macro's moved to sim-inline.h.
1254
1255 * sim-config.h: Ditto. For some options - eg WITH_DEVICES - do
1256 not provide a default value as undefined indicates disable code.
1257
1258Thu Mar 6 15:50:28 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1259
1260 * sim-core.h, sim-core-n.h, sim-core.c: Borrow code from ppc
1261 directory.
1262 * sim-events.h, sim-events.c: Ditto.
1263 * sim-io.h, sim-io.c: Ditto.
1264
b3e426bc
AC
1265Tue Mar 4 09:35:56 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1266
1267 * sim-alu.h (ALU_SUB_CA, ALU*_SUB_CA): New alu operation.
1268
1269 * sim-bits.h, sim-bits-n.h, sim-bits.c (LSMASKED*): New macro's
1270 extract the tail or least signifiant bits from an integer of the
1271 specified size.
1272
1273 * sim-bits.h, sim-bits.c: Clean up conditionally compiled #if
1274 WITH_TARGET_BITSIZE so that the compilation will fail when an
1275 unsupported bitsize value is defined.
1276
1277 (INSERTED*): Convert to functions.
1278 (EXTRACTED*): Ditto.
1279
1280 (SIGN_EXTEND, SEXT): Change to more terse name.
1281
17bbcaad
AC
1282Tue Mar 4 09:35:56 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1283
1284 * sim-inline.h: Allow explicit control over which .c files will be
1285 included by their header.
1286
1287 * sim-inline.h: Allow explicit control over which .c files use the
1288 alternative - REGPARM - parameter passing mechanism.
1289
1290 * sim-inline.h, sim-inline.c: Don't attempt to include any of
1291 icache.c, idecode.c, semantics.c or support.c. Those names are
1292 not generally applicable.
1293
b3e426bc
AC
1294Thu Feb 27 10:17:23 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1295
1296 * sim-bits.c, sim-bits-n.h (new): Split sim-bits.c into two parts
1297 in a fashion similar to sim-endian-n.
1298
1299 * sim-endian.h: (H_word, L_word, AL_*, VL_*): Extend to include
1300 both value and address macro's.
1301
1302Tue Feb 25 18:51:57 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
1303
1304 * sim-alu.h (ALU16_BEGIN, ALU16_SET, ...): Fill in.
1305
1306 * sim-endian.h (L_word, H_word): Replace MS2W_4, LS2W_4 with more
1307 generic L_word, H_word macro's.
1308
17bbcaad
AC
1309Thu Feb 20 18:36:55 1997 Andrew Cagney <cagney@critters.cygnus.com>
1310
1311 * sim-basics.h: Borrow code from ppc directory.
1312 * sim-bits.c: Ditto.
1313 * sim-bits.h: Ditto.
1314 * sim-config.h: Ditto.
1315 * sim-endian-n.h: Ditto.
1316 * sim-endian.c: Ditto.
1317 * sim-endian.h: Ditto.
1318 * sim-inline.c: Ditto.
1319 * sim-inline.h: Ditto.
1320 * sim-types.h: Ditto.
1321
1322Wed Feb 19 12:40:50 1997 Andrew Cagney <cagney@critters.cygnus.com>
1323
1324 * sim-alu.h (ALU_SET16, ALU_SET32, ALU_SET64, etc): Make available
1325 all the ALU size alternatives and then auto-configure a default.
1326
1327 * sim-alu.h: Copy ppc/idecode_expression.h.
1328
1329Mon Feb 17 10:44:18 1997 Andrew Cagney <cagney@critters.cygnus.com>
1330
1331 * bits.h, bits.c (SIGN_EXTEND32, SIGN_EXTEND64): New functions,
1332 sign extend a bit within a value.
1333
1334 * sim-endian.h, sim-endian-n.h (offset_N): New functions - return
1335 a pointer into the middle of a host word.
1336 * sim-endian.h (MS2W_4, LS2W_4): Use this function.
1337
1338Tue Feb 11 13:46:49 1997 Michael Meissner <meissner@tiktok.cygnus.com>
1339
1340 * callback.c: If HAVE_CONFIG_H is defined, include config.h from
1341 autoconf. If HAVE_UNISTD_H is defined, include unistd.h to get
1342 appropriate definitions of read, write, etc. Add prototype for
1343 system.
1344
1cc9ed29
DE
1345Tue Feb 4 13:24:44 1997 Doug Evans <dje@canuck.cygnus.com>
1346
1347 * Makefile.in (libcommon.a): Delete.
1348 (callback.o,targ-map.o): Delete, moved to Make-common.in.
1349 (gentmap,targ-vals.h,targ-map.c): Likewise.
1350 (run-autoconf): Delete.
1351 * aclocal.m4 (SIM_AC_OUTPUT): Redo creation of Makefile.
1352 (common makefile fragment): Moved back into ...
1353 * Make-common.in: Resurrect.
1354 * configure.in (AC_LINK_FILES): Delete, unnecessary now.
1355 * configure: Regenerated.
1356
8cd89e77
DE
1357Fri Jan 31 07:16:49 1997 Doug Evans <dje@canuck.cygnus.com>
1358
1359 * aclocal.m4 (SIM_AC_COMMON): Move COMMON_MAKEFILE_FRAG from here.
1360 (SIM_AC_OUTPUT): To here.
1361
76e2c9ae
SG
1362Fri Jan 24 10:37:17 1997 Stu Grossman (grossman@critters.cygnus.com)
1363
1364 * aclocal.m4 (COMMON_MAKEFILE_FRAG): Quote a couple of $'s in
1365 comments and single quotes. Fixes a problem found on hpux.
1366
80b7b3a5
SG
1367Thu Jan 23 13:35:03 1997 Stu Grossman (grossman@critters.cygnus.com)
1368
e1dfb8c5 1369 * aclocal.m4: Remove Make-common.in from dependencies.
42653e99 1370 * (distclean): Remove targ-vals.def.
e1dfb8c5 1371
80b7b3a5
SG
1372 * aclocal.m4 (SIM_AC_COMMON): Move contents of Make-common.in
1373 into here. Makes insertion into makefiles easier. Also, change
1374 the way that callback.o, gentmap, targ-vals.h, targ-map.c,
1375 targ-map.o, and run are built. They are now built in the
1376 individual simulator directories, taking sources from ../common as
1377 necessary. This replaces the merging of libcommon.a into
1378 linsim.a, which was problematic for the WinGDB build process.
1379 * run.c: Include config.h from . instead of ../common.
1380 * Make-common.in: Remove. It's no longer necessary.
1381
1382Mon Dec 16 15:02:33 1996 Ian Lance Taylor <ian@cygnus.com>
1383
1384 * Make-common.in (ALL_CLAGS): Put CFLAGS at the end.
1385 (.c.o): Put $(ALL_CFLAGS) before the file being compiled.
1386
1387Wed Dec 11 11:30:58 1996 Jim Wilson <wilson@cygnus.com>
1388
1389 * run.c (main): Set target_byte_order before call to sim_open.
1390
966f47b4
DE
1391Sun Dec 8 18:22:06 1996 Doug Evans <dje@canuck.cygnus.com>
1392
1393 * callback.c: #include <stdlib.h>
1394 (os_error): New function.
1395 (default_callback): Add os_error.
1396
1397Mon Nov 25 19:44:35 1996 Doug Evans <dje@canuck.cygnus.com>
1398
1399 * Make-common.in (Makefile): Set CONFIG_HEADERS="".
1400 * aclocal.m4: Mark the fact that --enable-sim-bswap isn't host
1401 specific.
1402 (SIM_AC_OUTPUT): Don't build Makefile if CONFIG_FILES="".
1403
1404Wed Nov 20 01:11:04 1996 Doug Evans <dje@canuck.cygnus.com>
1405
1406 * run.c: #include ../common/config.h, tconfig.h.
1407 (myname): New static global.
1408 (main): Recognize new options -a, -c. Also recognize -h if h8/300.
1409 Only process -c ifdef SIM_HAVE_SIMCACHE.
1410 Only process -p/-s ifdef SIM_HAVE_PROFILE.
1411 Parse program name from argv[0] and use in error messages.
1412 Pass sim_args to sim_open. Pass prog_args to sim_create_inferior.
1413 Add support for incomplete h8/300 termination indicators.
1414 (usage): Make more verbose.
1415 * aclocal.m4,config.in,tconfig.in,configure.in,configure: New files.
1416 * Makefile.in,Make-common.in,callback.c: New files.
1417 * nltvals.def,gentmap.c,gentvals.sh: New files.
1418
1419Tue Nov 12 13:34:00 1996 Dawn Perchik <dawn@cygnus.com>
1420
1421 * run.c: Include stdarg.h if __STDC__.
1422
1423Tue Oct 15 11:16:31 1996 Jeffrey A Law (law@cygnus.com)
1424
1425 * run.c (main): Don't print out anything if the signal
1426 number is zero (ie no signal).
1427
57bc1a72
MM
1428Tue Oct 15 11:20:44 1996 Michael Meissner <meissner@tiktok.cygnus.com>
1429
1430 * run.c (main): Print out if the program raised a signal.
1431
1432Wed Sep 18 09:52:14 1996 Michael Meissner <meissner@tiktok.cygnus.com>
1433
1434 * run.c (exec_bfd): Rename from sim_bfd, to use the gdb name.
1435 (main): Ditto.
1436
3733d109
JSC
1437Tue Sep 17 11:04:50 1996 James G. Smith <jsmith@cygnus.co.uk>
1438
1439 * run.c (main): Explicitly cast malloc() parameter.
1440
9b280a86
MM
1441Thu Sep 12 11:27:21 1996 Michael Meissner <meissner@tiktok.cygnus.com>
1442
1443 * run.c (sim_bfd): New global to hold the bfd pointer for the
1444 executable.
1445 (main): Initialize sim_bfd.
1446
1447Fri Dec 15 16:27:49 1995 Ian Lance Taylor <ian@cygnus.com>
1448
1449 * run.c (main): Use new bfd_big_endian macro.
1450
1451Wed Nov 8 15:49:49 1995 James G. Smith <jsmith@pasanda.cygnus.co.uk>
1452
1453 * run.c (main): Removed SH specific comments, so source is
1454 generic. Also updated to only load relevant sections. Moved
1455 sim_open() to after callback attach (to match GDB).
1456
1457 * run.1: Removed SH specific comments.
1458
3be50301
JW
1459Sat Oct 21 12:31:01 1995 Jim Wilson <wilson@chestnut.cygnus.com>
1460
1461 * run.c (main): Always return sigrc at end.
1462
1463Tue Oct 10 12:03:13 1995 J.T. Conklin <jtc@rtl.cygnus.com>
1464
1465 * run.c (main): Print error diagnostic and exit if bfd_openr() or
1466 bfd_check_format() fails.
1467
f025d903
SC
1468Thu Sep 28 15:40:36 1995 steve chamberlain <sac@slash.cygnus.com>
1469
1470 * run.c, run.1: From sh directory.
1471
1472
This page took 0.145054 seconds and 4 git commands to generate.