* fix for minor sanitization lossage
[deliverable/binutils-gdb.git] / sim / common / ChangeLog
CommitLineData
42647d5b
FCE
1start-sanitize-gxsim
21998-11-21 Frank Ch. Eigler <fche@elastic.org>
3
4 * sim-gx.c (sim_gx_block_translate): Generate computed
5 goto for __GNUC__ instead of plain switch() for gx block
6 entry. Lose "-g" compile option for gx block.
7
8end-sanitize-gxsim
2c054438
DE
91998-11-18 Doug Evans <devans@casey.cygnus.com>
10
916b1152
DE
11 * Make-common.in (cgen-utils.o): Depend on cgen-engine.h.
12 (CGEN_ARCH_SCM): New variable.
13 * cgen-engine.h (EXTRACT_[ML]SB0_{INT,UINT}): New macros.
14 (EXTRACT_INT,EXTRACT_UINT): New macros.
15 (SEM_SEM_ARG): New macro.
16 (SEM_NEXT_VPC): New arg `pc'.
17 * cgen-sim.h (EXTRACT_SIGNED,EXTRACT_UNSIGNED): Delete.
18 (sim_disassemble_insn): Update prototype.
19 * cgen-trace.c (current_insn,insn_fields): New static locals.
20 (trace_insn): Set them.
21 * cgen-utils.scm: #include cgen-engine.h.
22 (sim_disassemble_insn): New arg insn_fields.
23 Handle variable length insns.
24 * genmloop.sh: Only emit pbb decls if -pbb.
25 (${cpu}_scache_lookup): New arg `vpc'.
26 (scache support): Fetch pc before entering loop.
27
2c054438
DE
28 * gennltvals.sh: Add fr30 support.
29 * nltvals.def: Rebuild.
30
78dee4ee
AC
31Wed Nov 18 10:22:22 1998 Andrew Cagney <cagney@b1.cygnus.com>
32
33 * sim-types.h: Re-do type system so that GCC's attribute and mode
34 are used to specify types. Handle case of ALPHA.
35
92fa4579
FCE
361998-11-13 Frank Ch. Eigler <fche@elastic.org>
37
38start-sanitize-gxsim
39 * Make-common.im: Build sim-gx.o and sim-gx-run.o.
40 * sim-gx.c: New file: target-independent gx routines.
41 * sim-gx.h: Declarations for gx structs and routines.
42 * sim-gx-run.c: New file: target-independent gx driver.
43 * sim-base.h: Add gx block vector to state struct.
44end-sanitize-gxsim
45 * aclocal.m4: Add tests for dlopen family.
46 * config.in: Regenerated.
47
847b31bd
DE
48Wed Nov 11 14:02:25 1998 Doug Evans <devans@canuck.cygnus.com>
49
50 * sim-hload.c (sim_load): Pass `prog_name' to sim_load_file, not NULL.
51
8c7dc9ff
DE
52Wed Nov 4 23:51:19 1998 Doug Evans <devans@seba.cygnus.com>
53
54 * genmloop.sh (eng.hin): Rename HAVE_PARALLEL_EXEC to
55 HAVE_PARALLEL_INSNS, define as 0 or 1. Emit decls of fns in mloop.cin.
56 * cgen-engine.h: Typedefs of IADDR,CIA,SEM_ARG,SEM_PC moved ...
57 * cgen-sim.h: ... to here.
58
b9a9cde4
AC
59Wed Oct 28 12:00:57 1998 Andrew Cagney <cagney@b1.cygnus.com>
60
61 * aclocal.m4 (enable-build-warnings): Replace
62 enable-sim-warnings. Extend =LIST syntax so that prepend and
63 append of options is possible. Drop -Werror, add
64 -Wstrict-prototypes for GDB compatibility.
65 * Make-common.in (SIM_WARNINGS): Update.
66
67Mon Oct 19 13:56:32 1998 Doug Evans <devans@seba.cygnus.com>
68
69 * Make-common.in (CGEN_INCLUDE_DEPS): Define.
70 (sim-core.o): Delete duplicate dependence on $(SIM_EXTRA_DEPS).
71 (sim-cpu.o,sim-endian.o,sim-hw.o): Ditto.
72 (cgen-run.o,cgen-scache.o,cgen-trace.o,cgen-utils.o): Delete
73 explicit cgen header dependencies, require SIM_EXTRA_DEPS to include
74 CGEN_INCLUDE_DEPS.
75 * cgen-cpu.h: New file.
76 * cgen-engine.h: New file.
77 * cgen-scache.h: New file.
78 * cgen-sim.h: Delete portions moved to new files.
79 * genmloop.sh: Generate two files eng.hin,mloop.cin explicitly,
80 rather than sending result to stdout.
81
82Fri Oct 9 14:20:22 1998 Doug Evans <devans@seba.cygnus.com>
83
84 * Make-common.in (sim-reg.o): New rule.
85 (cgen-run.o): New rule.
86 * cgen-ops.h: Delete many BI macros. Change all UBI -> BI.
87 * cgen-run.c (prime_cpu): New function.
88 * cgen-scache.c: Add pseudo-basic-block (pbb) scaching support.
89 (scache_option_handler, case OPTION_PROFILE_SCACHE): Handle explicitly
90 mentioned cpu.
91 (scache_flush_cpu,scache_lookup,scache_lookup_or_alloc): New fns.
92 * cgen-sim.h (CGEN_INSN_VIRTUAL_TYPE): New enum.
93 (CGEN_INSN_VIRTUAL_P): New macro.
94 (SEM_PC): New typedef.
95 (SEMANTIC_FN): Change type of result to SEM_PC.
96 (SEM_SET_FULL_CODE,SEM_SET_FAST_CODE,SEM_SET_CODE): New macros.
97 (IDESC_CTI_P,IDESC_SKIP_P): New macros.
98 (SCACHE_MAP): New typedef.
99 (CPU_SCACHE): Add pbb support.
100 (scace_lookup,scache_lookup_or_alloc,scache_flush_cpu): Declare.
101 (SEM_BRANCH_INIT_EXTRACT,SEM_BRANCH_INIT,SEM_BRANCH_FINI): New macros.
102 (CGEN_CPU): New members running_p,insn_count,{fast,full}_engine_fn,
103 max_slice_insns.
104 (INSN_NAME): Delete.
105 (cgen_insn_name): Declare.
106 (sim_engine_invalid_insn): Renamed from sim_engine_illegal_insn.
107 * cgen-trace.c (trace_buf): Shrink from 1024 to 256 bytes.
108 (first_insn_p): Make static.
109 (trace_insn): Handle virtual insns specially.
110 (cgen_trace_printf): Ensure we haven't overflowed the buffer.
111 * cgen-types.h (UBI): Delete.
112 (MODE_TYPE): New enum.
113 (HOSTINT,HOSTUINT,HOSTPTR): Delete.
114 * cgen-utils.c (mode_names): Delete UBI. Add INT,UINT,PTR.
115 (cgen_virtual_opcode_table): New global.
116 (cgen_insn_name): New function.
117 (sim_disassemble_insn): Ignore virtual insns.
118 * genmloop.sh: Delete top level loop generation. Add pbb support.
119 * sim-cpu.h (CPU_INSN_NAME_FN): New typedef.
120 (sim_cpu_base): New members max_insns,insn_name,model_data.
121 (CPU_PC_GET,CPU_PC_SET): New macros.
122 (sim_pc_get,sim_pc_set): Declare.
123 * sim-model.c (model_set): Call model init fn.
124 * sim-model.h (MODEL_FN): New typedef.
125 (INSN_TIMING): New member model_fn.
126 (MODEL): New members num,init.
127 * sim-profile.c (sim_profile_print_bar): Renamed from print_bar.
128 All callers updated.
129 (profile_insn_init): New fn.
130 (profile_print_insn): Update, INSN_NAME -> CPU_INSN_NAME.
131 Exit early if insn profiling not supported.
132 (profile_print_memory): Update, MAX_MODES -> MODE_TARGET_MAX.
133 (profile_install): Record profile_insn_init as init fn.
134 (profile_uninstall): Free PROFILE_INSN_COUNT if non-null.
135 * sim-profile.h: Update, MAX_MODES -> MODE_TARGET_MAX.
136 (PROFILE_DATA): Delete member exec_time.
137 Change insn_count to pointer to array, rather than the array.
138 (sim_profile_print_bar): Declare.
139
140Wed Oct 7 16:56:42 1998 Doug Evans <devans@seba.cygnus.com>
141
142 * cgen-run.c: New file.
143 * sim-reg.c: New file.
144
145Mon Sep 14 10:58:19 1998 Frank Ch. Eigler <fche@cygnus.com>
146
147 * aclocal.m4: Add checks for -lsocket and -lnsl.
148
149 * dv-sockser.c (dv_sockser_init): Use SO_REUSEADDR to
150 allow local port reuse on listening socket.
151
78b871ec
FCE
152Tue Sep 1 15:36:52 1998 Frank Ch. Eigler <fche@cygnus.com>
153
154 * sim-config.h: Remove reference to linux kernel header.
155
156Tue Aug 25 12:45:27 1998 Frank Ch. Eigler <fche@cygnus.com>
157
158 * dv-sockser.c (sockser_addr): Make variable non-static.
159
fb37fdcb
JJ
160Mon Aug 24 11:47:37 1998 Joyce Janczyn <janczyn@cygnus.com>
161
162 * sim-hw.{c,h} (sim_hw_parse): Return struct hw pointer.
163
164Tue Aug 11 18:12:19 1998 Doug Evans <devans@canuck.cygnus.com>
165
166 * sim-events.c (sim_events_elapsed_time): Fix calculation.
167
168Tue Aug 4 20:36:46 1998 Jeff Holcomb <jeffh@cygnus.com>
169
170 * Make-common.in (install-common): Add $(EXEEXT) when installing
171 run.
172
39813256
DE
173Mon Aug 3 11:46:01 1998 Doug Evans <devans@seba.cygnus.com>
174
175 * cgen-sim.h (cgen_state): New member opcode_table.
176 * cgen-utils.c (sim_disassemble_insn): Use it.
177
f3ccb5a7
DE
178Fri Jul 24 10:14:18 1998 Doug Evans <devans@canuck.cygnus.com>
179
63542cbc 180 * cgen-mem.h (DECLARE_SETT): Fix return type.
39813256
DE
181 * cgen-sim.h (sim_engine_illegal_insn): Declare.
182 * cgen-scache.c: Include stdlib.h.
183 * cgen-trace.c (trace_extract): Use %lx for PCADDR.
f3ccb5a7
DE
184 * sim-model.c (model_option_handler): Remove unused variable `n'.
185
cac4e5a4
DE
186Tue Jul 21 16:27:43 1998 Doug Evans <devans@seba.cygnus.com>
187
188 * cgen-utils.c: Include bfd.h.
189 (sim_disassemble_insn): Update call to CGEN_EXTRACT_FN.
190
191Wed Jul 8 18:24:10 1998 Jeffrey A Law (law@cygnus.com)
192
193 * sim-bits.h (EXTEND24): Fix typo.
194
9483af2c
AC
195Wed Jul 8 17:41:47 1998 Andrew Cagney <cagney@b1.cygnus.com>
196
197 * sim-events.c (ETRACE_P): New macro.
198 (struct _sim_event): Add member trace.
199 (sim_events_free): Reclaim trace message.
200
201 * sim-events.c, sim-events.h (sim_events_schedule_vtracef,
202 sim_events_schedule_tracef): New functions, include printf trace
203 information in argument list. If tracing, store asprintf'd trace
204 message in sim_event.
205
206 * hw-events.c, hw-events.h (hw_event_queue_schedule_tracef,
207 hw_event_queue_schedule_vtracef): New functions, mimic
208 sim_event_tracef.
209
658fb0c7
JL
210Mon Jul 6 15:51:14 1998 Jeffrey A Law (law@cygnus.com)
211
212 * sim-bits.h (EXTEND24): Define.
213
039fa2c8
DE
214Thu Jul 2 17:13:25 1998 Doug Evans <devans@seba.cygnus.com>
215
216 * cgen-sim.h (CPU_SCACHE): Make size unsigned.
217 (CPU_SCACHE_HASH_MASK): New macro.
218 (SCACHE_HASH_PC): Rewrite.
219 * genmloop.sh (engine_resume_{full,fast}): Move some of hash
220 computation out of main loop.
221
6de2add2
DE
222Wed Jul 1 16:44:12 1998 Doug Evans <devans@seba.cygnus.com>
223
224 * Make-common.in (SCHEME,SCHEMEFLAGS): Delete.
225 (CGENDIR,CGEN): New variables.
226 (CGEN_VERBOSE): Renamed to CGENFLAGS.
227 (cgen-arch,cgen-cpu,cgen-decode): Update.
228 (CGEN_CPU_WRITE): New variable.
229 (CGEN_CPU_SEMSW): -W -> -X.
230 (CGEN_FLAGS_TO_PASS): Delete SCHEME. Add CGEN,CGENFLAGS.
231 * cgen.sh: Delete args scheme,schemeflags. New arg cgen.
232
233 * cgen-sim.h (RECORD_IADDR): Delete.
234 * cgen-types.h (HOSTINT,HOSTUINT,HOSTPTR): New types.
235 * genmloop.sh (engine_resume_{full,fast}): Delete icount.
236
237Wed Jun 17 12:25:08 1998 Mark Alexander <marka@cygnus.com>
238
239 * gennltvals.def (mn10200): Add entry.
240 * nltvals.def: Regenerate with MN10200 additions.
241
67574b9c
AC
242Wed Jun 17 13:18:28 1998 Andrew Cagney <cagney@b1.cygnus.com>
243
244 * sim-inline.h (EXTERN_*): Replace with EXTERN_*_P. Correct
245 documentation on how it works.
246
247 * sim-core.h, sim-core.c (sim_core_install, sim_core_attach,
248 sim_core_detach, sim_core_read_buffer, sim_core_write_buffer,
249 sim_core_set_xor, sim_core_xor_read_buffer,
250 sim_core_xor_write_buffer): Update.
251
252 * sim-events.h, sim-events.c (sim_events_install,
253 sim_events_watch_clock, sim_events_schedule_after_signal,
254 sim_events_schedule, sim_events_watch_sim, sim_events_watch_core,
255 sim_events_deschedule): Update.
256
257 * sim-fpu.h, sim-fpu.c (sim_fpu_zero, sim_fpu_one, sim_fpu_two,
258 sim_fpu_max32, sim_fpu_max64): Update.
259
403bed78
DE
260Sat Jun 13 07:45:38 1998 Doug Evans <devans@fallis.cygnus.com>
261
262 * cgen-trace.c (trace_insn_fini): Redo cycle handling.
263 * sim-profile.h (PROFILE_DATA): Rename cycle handling members.
264 * sim-profile.c (profile_print_model): Update.
265
af2b0c85
DE
266Fri Jun 12 18:35:07 1998 Doug Evans <devans@seba.cygnus.com>
267
268 * gennltvals.def (m32r): Use common syscall.h now.
269 (mn10300): Add entry.
270 * nltvals.def: Regenerate.
68096722
DE
271
272 * sim-engine.c (sim_engine_get_run_state): New function.
273 * sim-engine.h (sim_engine_get_run_state): Declare it.
274
169c7476
DE
275Thu Jun 11 00:50:03 1998 Doug Evans <devans@seba.cygnus.com>
276
277 * sim-core.h (SIM_CORE_SIGNAL_FN): New typedef.
278 * sim-core.c (sim_core_signal): Make extern, always define.
279
a27a2a8d
DE
280Wed Jun 10 16:02:29 1998 Doug Evans <devans@seba.cygnus.com>
281
282 * Make-common.in (CGEN_FLAGS_TO_PASS): New variable.
283 * cgen-ops.h (ANDIF): New macro.
284 (ANDIF[BQHSD]I): Delete.
285
05f6bf9c
AC
286Thu Jun 4 13:53:54 1998 Andrew Cagney <cagney@b1.cygnus.com>
287
288 * hw-events.c (create_hw_event, delete_hw_event): Delete.
289 (hw_event_queue_schedule, hw_event_queue_deschedule,
290 bounce_hw_event): Fix hw-event memory corruptions found by Joyce
291 Janczyn.
292
293 * hw-alloc.h (HW_NZALLOC): Define.
294
295 * Make-common.in (test-hw-events): Add target for testing the
296 hw-event code.
297
298Mon May 25 21:11:26 1998 Andrew Cagney <cagney@b1.cygnus.com>
299
300 * Make-common.in (SIM_COMMON_HW_OBJS): Add hw-handles.o and
301 hw-instances.o.
302 hw-handles.c, hw-instances.c, hw-handles.h, hw-instances.h: New
303 files.
304 * hw-main.h: Include hw-handles.h, hw-instances.h.
305 * hw-base.h ({create,delete}_hw_{handles,instances}_data): Declare
306 * hw-base.c (hw_create, hw_delete): Call same.
307
48f83b1a
AC
308Mon May 25 18:55:35 1998 Andrew Cagney <cagney@b1.cygnus.com>
309
310 * dv-core.c: Include hw-main.h and sim-main.h.
311 * dv-pal.c: Include hw-main.h and sim-io.h.
312 * dv-glue.c: Include hw-main.h.
313
314 * hw-main.h: New file. Move list of includes to here.
315 * hw-base.h: From here.
316 * Make-common.in (hw_base_headers): Rename to hw_main_headers.
317 (hw-*.o, dv-*.o): Update.
318 * hw-tree.c, hw-base.c, hw-properties.c, hw-ports.c, hw-device.c,
319 hw-events.c, hw-alloc.c, sim-hw.c: Include hw-main.h instead of
320 sim-main.h.
321
322 * hw-base.h (do_hw_attach_regs, do_hw_poll_read_method,
323 do_hw_poll_read): Move declarations from here.
324 * hw-main.h: To here.
325
326 * hw-base.h (struct hw_device_descriptor, hw_finish_callback):
327 Move from here.
328 * hw-main.h (struct hw_descriptor, hw_finish_method): To here,
329 rename.
330 * Make-common.in (hw-config.h): Update
331 * hw-base.c, dv-pal.c, dv-glue.c: Update
332
333 * dv-glue.c, hw-device.h, hw-base.h, hw-ports.c: Rename
334 `*_callback' to `*_method.
335
c14db36d
AC
336Mon May 25 18:41:18 1998 Andrew Cagney <cagney@b1.cygnus.com>
337
338 * hw-base.h (set_*): Move set method macros from here.
339 * hw-device.h: To here.
340
325a1ba8
AC
341Mon May 25 18:21:38 1998 Andrew Cagney <cagney@b1.cygnus.com>
342
343 * hw-base.h (create_hw_property_data, delete_hw_property_data):
344 Declare.
c14db36d 345
325a1ba8
AC
346 * hw-base.c (hw_create, hw_delete): Call
347 * hw-properties.c (create_hw_property_data,
348 delete_hw_property_data): Define.
349
69be0d4c 350Mon May 25 17:40:46 1998 Andrew Cagney <cagney@b1.cygnus.com>
39e953a7 351
69be0d4c
AC
352 * hw-device.c, hw-properties.c: Include hw-base.h
353
354 * hw-alloc.h, hw-alloc.c: New files. Move alloc code to here.
355 * hw-device.c: From here.
356 * hw-base.h: Include "hw-events.h".
357
358 * hw-base.h (create_hw_alloc_data, delete_hw_alloc_data): Declare.
359 * hw-base.c (hw_create, hw_delete): Call.
360 * hw-alloc.c (create_hw_alloc_data, delete_hw_alloc_data): Define.
361
362 * Make-common.in (SIM_NEW_COMMON_OBJS): Add hw-alloc.o.
363 (hw-alloc.o): New target.
364
365Mon May 25 17:14:27 1998 Andrew Cagney <cagney@b1.cygnus.com>
39e953a7
AC
366
367 * hw-events.h, hw-events.c: New files. Move event code to here.
368 * sim-hw.c: From here.
369 * hw-base.h: Include "hw-events.h".
69be0d4c
AC
370 * Make-common.in (SIM_NEW_COMMON_OBJS): Add hw-events.o.
371 (hw-events.o): New target.
39e953a7
AC
372
373 * hw-device.h (struct hw): Add struct hw_event_data events_of_hw.
374 * hw-events.h (struct hw_event): Replace typedef hw_event.
375
376 * hw-base.h (create_hw_event_data, delete_hw_event_data): Declare.
377 * hw-base.c (hw_create, hw_delete): Call.
378 * hw-events.c (create_hw_event_data, delete_hw_event_data): Define.
379
69be0d4c 380 * dv-pal.c: Update.
39e953a7 381
2f06c437
AC
382Mon May 25 16:55:16 1998 Andrew Cagney <cagney@b1.cygnus.com>
383
384 * hw-base.c (panic_hw_port_event, empty_hw_ports): Move from here.
385 * hw-ports.c: To here.
386
387 * hw-base.h, hw-ports.c (create_hw_port_data,
388 delete_hw_port_data): New functions.
389 * hw-base.c (hw_delete, hw_create): Call same.
390
391 * hw-base.h (set_hw_ports, set_hw_port_event): Move set functions
392 from here.
393 * hw-ports.h: To here.
394
f6757447
AC
395Mon May 25 16:42:48 1998 Andrew Cagney <cagney@b1.cygnus.com>
396
397 * hw-device.c (hw_ioctl), hw-device.h (hw_ioctl_callback): Drop
398 PROCESSOR and CIA arguments.
399
f872d0d6
AC
400Fri May 22 12:16:27 1998 Andrew Cagney <cagney@b1.cygnus.com>
401
402 * aclocal.m4 (SIM_AC_OPTION_HW): Add enable / disable argument.
403 Move common object files from here.
404 * Make-common.in (SIM_COMMON_HW_OBJS): To here.
405
643878d0
AC
406Thu May 21 17:57:16 1998 Andrew Cagney <cagney@b1.cygnus.com>
407
408 * sim-hw.c: Include ctype.h.
409 (do_hw_poll_read): Do not assume EAGAIN.
410
6f7833f0
DE
411Wed May 20 04:37:57 1998 Doug Evans <devans@seba.cygnus.com>
412
413 * cgen-trace.c (first_insn_p): New static local.
414 (trace_insn_init): Set it.
415 (trace_insn_fini): Use TRACE_PREFIX.
416 (trace_insn): Rewrite to use trace_prefix.
417 * sim-trace.c (trace_prefix): Don't print filename arg if NULL.
418 Adjust width accordingly.
419
420 * sim-profile.h (PROFILE_DATA): New member profile_any_p.
421 (PROFILE_ANY_P,PROFILE_INSN_P,PROFILE_MEMORY): New macros.
422 (PROFILE_SCACHE_P,PROFILE_PC_P,PROFILE_CORE_P): New macros.
423 (PROFILE_COUNT_INSN,PROFILE_COUNT_READ,PROFILE_COUNT_WRITE): Simplify.
424 (PROFILE_COUNT_CORE): Simplify.
425 * sim-profile.c (profile_option_handler): Compute profile_any_p.
426
6f1cadd0
DE
427Tue May 19 23:55:30 1998 Doug Evans <devans@seba.cygnus.com>
428
429 * cgen-ops.h (ADDCFSI): Fix typo.
430
ebd58f4d
DE
431Sat May 16 12:44:52 1998 Doug Evans <devans@seba.cygnus.com>
432
991238c8
DE
433 * cgen-sim.h (CGEN_CPU): New members idesc_{read,sem}_init_p.
434 * genmloop.sh: Use them rather than static locals.
435
ebd58f4d
DE
436 * sim-engine.c (sim_engine_set_run_state): New function.
437 * sim-engine.h (sim_engine_set_run_state): Declare.
438 * genmloop.sh (pending_reason,pending_sigrc): New static locals.
439 (@cpu@_engine_stop): New args reason,sigrc. All callers updated.
440 (engine_resume): Reorganize. Allow synchronous exit from main loop.
441
bcb829fd
DE
442Fri May 15 16:06:05 1998 Doug Evans <devans@seba.cygnus.com>
443
444 * cgen-trace.c (trace_insn_init): New arg first_p.
445 All callers updated.
446 (trace_insn_fini): New arg last_p. All callers updated.
447 * cgen-trace.h (trace_insn_init,trace_insn_fini): Update.
448 (TRACE_INSN_INIT,TRACE_INSN_FINI): Update.
449 * genmloop.sh (engine_resume): Update.
450
6cad2395
JJ
451Fri May 15 15:59:00 1998 Joyce Janczyn <janczyn@cygnus.com>
452
453 * Make-common.in (install-common): Run ranlib on installed copy of
454 libsim.a.
455
08bae91b
JJ
456Fri May 15 15:03:00 1998 Joyce Janczyn <janczyn@cygnus.com>
457
458 * Make-common.in (install-common): Rename and install libsim.a.
459
460Tue May 12 15:23:57 1998 Andrew Cagney <cagney@b1.cygnus.com>
461
462 * sim-io.c (unistd.h): Include.
463
464Wed May 6 16:04:18 1998 Doug Evans <devans@seba.cygnus.com>
465
466 * Make-common (sim_main_headers): Sort.
467 (cgen-*.o): Add cgen-sim.h dependency.
468
469 * cgen-scache.c (scache_init): Only allocate space if scache element
470 size is non-zero.
471 (scache_flush,scache_print_profile): Check if scache in use first.
472
473 * cgen-sim.h (IDESC): Provide forward declaration.
474 (DECODE): Delete.
475 (CGEN_CPU): Always define scache member. New members idesc,opcode.
476 (cgen_cpu_max_extra_bytes): Declare.
477 * cgen-utils.c (cgen_cpu_max_extra_bytes): New function.
478
479 * cgen.sh: s/@arch@/${arch}/ for cpu files.
480
481 * sim-cpu.h: New file. sim_cpu_base moved here.
482 Move sim_cpu_lookup decl here.
483 * sim-base.h: #include "sim-cpu.h".
484 * sim-cpu.c: New file.
485 * Make-common (sim_main_headers): Add sim-cpu.h.
486 (sim-cpu.o): Add rule for.
487
488 * sim-model.c (set_model): Delete.
489 (sim_model_set,model_set): New functions.
490 (sim_model_install): Renamed from model_install.
491 Don't set default model here.
492 (model_option_handler): Rewrite --model processing.
493 (sim_model_lookup,sim_mach_lookup): New functions.
494 * sim-model.h (MAX_MODELS,MAX_INSNS): Delete.
495 (insn_timing): Delete.
496 (INSN_TIMING): New member `num'.
497 (IMP_PROPERTIES): Always define scache_elm_size member.
498 (MACH): New member init_cpu.
499 (sim_machs): Renamed from machs.
500 (sim_model_install): Renamed from model_install.
501 (sim_model_set,sim_model_lookup,sim_mach_lookup): Declare.
502 * sim-module.c (modules): Update.
503
504 * sim-profile.c (profile_print_insn): Add cpu arg to INSN_NAME macro.
109e6111
DE
505
506 * sim-io.c: #include <errno.h>.
507
844f40d3 508Wed May 6 12:39:15 1998 Andrew Cagney <cagney@b1.cygnus.com>
844f40d3
AC
509
510 * dv-pal.c (struct hw_pal_device): Add reader.
511 (hw_pal_finish): Initialize reader.
512 (scan_hw_pal): Use reader.
513
514 * hw-base.h, sim-hw.c (do_hw_poll_read): New function.
515 (HW_IO_EOF, HW_IO_NOT_READY): Define.
516 * dv-pal.c: Use.
517
844f40d3
AC
518 * sim-io.h, sim-io.c (sim_io_poll_read): New function. Copy from
519 ../ppc/main.c sim_io_read_stdin.
520
03f3bfdb
AC
521Fri May 1 12:11:02 1998 Andrew Cagney <cagney@b1.cygnus.com>
522
523 * hw-tree.h (hw_tree_print): Paramaterize with print and file
524 arguments.
525 * hw-tree.c: Update.
526
527 * hw-base.h (hw_port_event_callback): Delete CPU/CIA args.
528 * hw-device.h (hw_io_read_buffer, hw_io_write_buffer): Delete
529 CPU/CIA args.
530 * hw-ports.h (hw_port_event): Ditto.
531 * hw-ports.c (hw_port_event): Update.
532 * hw-base.c (panic_hw_io_read_buffer, panic_hw_io_write_buffer):
533 Update.
534 * dv-pal.c (hw_pal_io_read_buffer, hw_pal_io_write_buffer):
535 Update.
536 (hw_pal_io_write_buffer): Call hw_halt not sim_engine_halt.
537 (do_counter_event): Update.
538 * dv-glue.c (hw_glue_io_read_buffer): Update.
539 (hw_glue_port_event): Update.
540
03f3bfdb
AC
541 * hw-device.h (SIM_DESC): Replace with struct sim_state.
542 * hw-base.h (hw_create): Ditto.
543 * hw-base.c (hw_create): Ditto.
544
545 * hw-device.c (hw_abort, hw_trace, hw_hw_event_queue_schedule,
546 hw_event_queue_deschedule, hw_event_queue_time): Delete, moved
547 from here to.
548 * sim-hw.c: Here.
549 * hw-device.h (hw_system_cpu): Declare.
550 * sim-hw.c (hw_system_cpu): New function.
551
552 * sim-core.c (sim_core_map_attach, sim_core_attach): Call
553 sim_hw_abort not hw_abort.
554 (sim-hw.h): Include.
555 (sim_core_read_buffer, sim_core_write_buffer): Call
556 sim_hw_io_read_buffer and sim_hw_io_write_buffer. Do not pass CPU
557 argument.
558 (sim_core_set_xor): Do not pass CPU when aborting.
559
560 * sim-n-core.h (sim_core_read_aligned_N,
561 sim_core_write_aligned_N): Call sim_hw_abort not hw_abort.
562 (sim_core_read_aligned_N, sim_core_write_aligned_N): Call
563 sim_cpu_hw_io_read_buffer and sim_cpu_hw_io_write_buffer. Does not
564 return length.
565
566 * sim-hw.h: Declare sim_hw_io_{read,write}_buffer. Declare
567 sim_hw_print.
568 * sim-hw.c (sim_hw_io_read_buffer, sim_hw_io_write_buffer,
569 sim_cpu_hw_io_read_buffer, sim_cpu_hw_io_write_buffer): New
570 functions.
571 (sim_hw_print): New function.
844f40d3 572
03f3bfdb
AC
573 * sim-engine.h (sim_engine_vabort): Declare.
574 * sim-engine.c (sim_engine_vabort): New function.
844f40d3 575
e7439596
AC
576Wed Apr 29 23:58:52 1998 Andrew Cagney <cagney@b1.cygnus.com>
577
578 * sim-trace.c (print_data): For floating-point numbers trace raw
579 hex value.
580 (trace_result_fp2): New function.
581 * sim-trace.h (trace_result_fp2): New declaration.
582 (TRACE_FP_RESULT2): New macro.
583
9d45df1b
GN
584Tue Apr 28 18:28:58 1998 Geoffrey Noer <noer@cygnus.com>
585
586 * common/aclocal.m4: call AM_EXEEXT in SIM_AC_COMMON, define
587 AM_CYGWIN32 and AM_EXEEXT.
588 * common/Make-common.in: set EXEEXT, add missing EXEEXTs
589 to run and install-common rules.
590 * common/configure: regenerate
591
f68cdf65
AC
592Sat Apr 25 17:45:01 1998 Andrew Cagney <cagney@b1.cygnus.com>
593
594 * sim-types.h (cell_word): New type.
595 (natural_cell): Delete type.
596
56df89bc
TT
597Sun Apr 26 15:31:55 1998 Tom Tromey <tromey@creche>
598
599 * configure: Regenerated to track ../common/aclocal.m4 changes.
600 * config.in: Ditto.
601
602Sun Apr 26 15:25:07 1998 Tom Tromey <tromey@cygnus.com>
603
604 * acconfig.h (NEED_DECLARATION_PRINTF): Removed.
605
fc4198bb
TT
606Fri Apr 24 14:16:40 1998 Tom Tromey <tromey@creche>
607
608 * configure: Regenerated to track ../common/aclocal.m4 changes.
609 * config.in: Ditto.
610
611Fri Apr 24 11:38:08 1998 Tom Tromey <tromey@cygnus.com>
612
613 * acconfig.h: New file.
614 * Make-common.in (top_builddir): New macro.
615 (INTL_LIB): Removed.
616 (INTLLIBS): New macro.
617 (INTLDEPS): Likewise.
618 (LIBDEPS): Use INTLDEPS.
619 (EXTRA_LIBS): Use INTLLIBS.
620 * aclocal.m4 (SIM_AC_COMMON): Call CY_GNU_GETTEXT.
621 (CY_WITH_NLS, CY_GNU_GETTEXT, AM_PATH_PROG_WITH_TEST,
622 AM_LC_MESSAGES): New macros from GNU gettext.
623
d32658fe
AC
624Fri Apr 24 19:57:59 1998 Andrew Cagney <cagney@b1.cygnus.com>
625
626 * sim-config.h: Discard leading _ from macros.
627 * sim-types.h: Ditto.
628
3618a6e9
MM
629Wed Apr 22 14:14:19 1998 Michael Meissner <meissner@cygnus.com>
630
631 * Make-common.in (CSEARCH): Add -I to intl directories.
632 (INTL_LIB): Point to libintl.a.
633 (LIBDEPS): Add $(INTL_LIB).
634 (EXTRA_LIBS): Ditto.
635
404d4ee1
DE
636Tue Apr 21 12:44:27 1998 Doug Evans <devans@canuck.cygnus.com>
637
638 * cgen-types.h (GETHIDI,MAKEDI): Tweak.
639
8bb5064e
DE
640 * cgen-ops.h (ADDCFSI): Fix.
641 (SUBCFSI): Tweak.
642
97f4d183
AC
643Tue Apr 21 13:18:41 1998 Andrew Cagney <cagney@b1.cygnus.com>
644
645 * sim-types.h (signed_address, unsigned_address): Define.
646
647Mon Apr 20 21:47:54 1998 Andrew Cagney <cagney@b1.cygnus.com>
648
649 * sim-fpu.c (sim_fpu_2d): Don't return an SNaN, convert it into a
650 QNaN.
651
7d93d538
AC
652Thu Apr 16 10:30:14 1998 Andrew Cagney <cagney@b1.cygnus.com>
653
654 * sim-fpu.c, sim-fpu.h (sim_fpu_fractionto, sim_fpu_tofraction):
655 New functions, pack / unpack sim_fpu struct using raw values.
656 (sim_fpu_is): Differentiate between negative and positive
657 infinity.
658
93f96715
AC
659Tue Apr 14 18:49:31 1998 Andrew Cagney <cagney@b1.cygnus.com>
660
661 * sim-bits.h (EXTEND4): Define.
ea5d84f5 662 (EXTEND4, EXTEND15, EXTEND11): Ditto.
7acc4e98 663
5d71b4bc
JM
664Tue Apr 14 16:31:35 1998 John Metzler <jmetzler@cygnus.com>
665
eeb89805 666 * sim-memopt.c (parse_addr): Sunos 4.5 does not have strtol
5d71b4bc
JM
667 declared so we need this cast to prevent long long addresses
668 from being misconfigures. Results in access to unmapped memory.
669
b42e7eb3
DE
670Tue Apr 14 13:19:14 1998 Doug Evans <devans@canuck.cygnus.com>
671
672 * Make-common.in (RUNTESTFLAGS): Define.
673 (check): Pass RUNTESTFLAGS to recursive make.
674
7bf341f4
AC
675Tue Apr 14 15:09:19 1998 Andrew Cagney <cagney@b1.cygnus.com>
676
677 * sim-info.c (sim_info): Be verbose when either VERBOSE or
678 STATE_VERBOSE_P.
679
64ed8b6a
AC
680Sat Apr 4 23:24:17 1998 Andrew Cagney <cagney@b1.cygnus.com>
681
682 * aclocal.m4 (sim-inline): By default, disable sim-inline when
683 cross compiling.
684
278bda40
AC
685Sat Apr 4 20:36:25 1998 Andrew Cagney <cagney@b1.cygnus.com>
686
687 * aclocal.m4 (sim-cflags): Add -fomit-frame-pointer to defaults.
688 (sim-inline): Update to match sim-inline.[hc]
278bda40
AC
689 * configure: Regenerated to track ../common/aclocal.m4 changes.
690
691 * Make-common.in (sim_main_headers): Add sim-inline.h
692
693 * sim-bits.h (sim-bits.c): Include when H_REVEALS_MODULE_P.
694 selected.
695 * sim-endian.h (sim-endian.c): Ditto.
696
697 * sim-events.h (_SIM_EVENTS_H_): Replace with SIM_EVENTS_H.
698 (sim_events_set_trace): Delete unused prototype.
699
700 * sim-core.h (_SIM_CORE_H_): Replace with SIM_CORE_H.
701 * sim-core.c (_SIM_CORE_C_): Ditto for SIM_CORE_C.
702
703 * sim-fpu.h (sim-fpu.c): Include when H_REVEALS_MODULE_P.
704 (sim_fpu_to232i, sim_fpu_to232u, sim_fpu_i232to, sim_fpu_u232to):
705 Comment out, not yet implemented in sim-fpu.c.
706 (sim_fpu_zero, sim_fpu_one, sim_fpu_two, sim_fpu_qnan,
707 sim_fpu_max32, sim_fpu_max64): Mark as EXTERN_SIM_FPU.
708
709 * sim-inline.h: Rewrite description.
710 (H_REVEALS_MODULE_P, C_REVEALS_MODULE_P): Define.
711 (SIM_MAIN_INLINE): Add inline option.
712
713 * sim-inline.c (semantics.c, idecode.c, engine.c, ...): Do not
714 include generated files. Handled by generator directly.
715
72a08ce5
AC
716Sat Apr 4 01:07:06 1998 Andrew Cagney <cagney@b1.cygnus.com>
717
718 * sim-trace.c (set_trace_option_mask): Keep TRACE_ANY_P
719 up-to-date.
720
721 * sim-trace.h (TRACE_ANY_P): Define.
722 (struct _trace_data): Add trace_any_p.
723
a1e4dc0d
AC
724Mon Mar 30 17:11:55 1998 Andrew Cagney <cagney@b1.cygnus.com>
725
726 * run.c (main): Handle all alternatives of enum sim_stop.
727 (main): Delete unused `asection *s'.
728
d8f53049
AC
729Fri Mar 27 16:15:52 1998 Andrew Cagney <cagney@b1.cygnus.com>
730
731 * hw-tree.h, hw-tree.c (hw_tree_vparse): New function
732
733 * configure: Regenerated to track ../common/aclocal.m4 changes.
734
735 * sim-hw.c: New file.
736 * sim-hw.h (sim_hw_parse): Declare function.
737 (hw-tree.h): Do not include.
738
739 * sim-base.h (STATE_HW): Define.
740 (struct sim_state_base): Add member struct *hw.
741
742 * sim-module.c (sim-hw.h): Include.
743 (modules): Add sim_hw_install.
744
745 * aclocal.m4 (sim_hw_obj): Add sim-hw.o
746
82ea14fd
AC
747Fri Mar 27 14:55:06 1998 Andrew Cagney <cagney@b1.cygnus.com>
748
749 * sim-base.h (CPU_INDEX): Define.
750
751 * sim-utils.c (sim_state_alloc): Initialize.
752 * sim-module.c (sim_post_argv_init): Ditto.
753
6d133cc9
AC
754Thu Mar 26 10:07:57 1998 Stu Grossman <grossman@bhuna.cygnus.co.uk>
755
756 * aclocal.m4 (sim_hw_obj): Fix sed expression to generate
757 properly formatted lists.
758
98f1f62c
AC
759Thu Mar 26 10:37:22 1998 Andrew Cagney <cagney@b1.cygnus.com>
760
761 * dv-pal.c (enum hw_pal_address_mask): From Stu Grossman, was
762 0x2f needs to be 0x3f.
763
04cdafa7
AC
764Thu Mar 26 09:10:56 1998 Andrew Cagney <cagney@b1.cygnus.com>
765
766 * hw-tree.c (hw_tree_find_property): Return NULL when device is
767 not found.
768 (hw_tree_find_*_property): Clean up error message when property is
769 not found.
770
771 * dv-pal.c (hw_pal_io_read_buffer): Check the smp property is
772 present before looking for it.
773
8d0bd988
IC
774Wed Mar 25 16:17:38 1998 Ian Carmichael <iancarm@cygnus.com>
775
776 * aclocal.m4 (AC_CHECK_HEADERS): Add check for fpu_control.h.
777 (AC_CHECK_FUNCS): Add check for __setfpucw.
778 * configure: Regenerated.
779
05d7918e
AC
780Wed Mar 25 09:18:34 1998 Andrew Cagney <cagney@b1.cygnus.com>
781
782 * dv-pal.c (hw_pal_countdown, hw_pal_countdown_value,
783 hw_pal_timer, hw_pal_timer_value): Define.
784 (hw_pal_io_read_buffer, hw_pal_io_write_buffer): Add timer support
785 (do_counter_event, do_counter_read, do_counter_value,
786 do_counter_write): new functions.
787
788Tue Mar 24 12:24:24 1998 Andrew Cagney <cagney@b1.cygnus.com>
789
790 * hw-tree.c (hw_printf): Send tree dump to stderr, same as other
791 trace output.
792
793 * hw-base.c (hw_create): Stop searching for a device when one is
794 found.
795
d89fa2d8
AC
796Wed Mar 25 12:35:29 1998 Andrew Cagney <cagney@b1.cygnus.com>
797
798 * configure: Regenerated to track ../common/aclocal.m4 changes.
799
800Mon Mar 23 10:25:08 1998 Andrew Cagney <cagney@b1.cygnus.com>
801
802 * aclocal.m4 (SIM_AC_OPTION_HARDWARE): Add second argument,
803 appends extra devices.
804 (SIM_AC_OPTION_HARDWARE): Substute sim_hw, a non-duplicate list of
805 the device names.
806
807 * Make-common.in (hw-config.h): New target, create hw-config.h
808 file.
809 (SIM_HW): Definition from @sim_hw@.
810 (hw-base.o): Depend on hw-config.h
811
63330b2e
SG
812Tue Mar 24 17:41:35 1998 Stu Grossman <grossman@bhuna.cygnus.co.uk>
813
814 * Make-common.in: Get SHELL from configure.
815 * (stamp-tvals sim-inline.c): Use $(SHELL) when invoking
816 move-if-change. Fixes NT native build problem.
817 * Makefile.in (nltvals.def): Use $(SHELL) when invoking
818 move-if-change. Fixes NT native build problem.
819 * configure: Regenerate with autoconf 2.12.1 to fix shell issues for
820 NT native builds.
821
822Sun Mar 22 16:54:40 1998 Andrew Cagney <cagney@b1.cygnus.com>
823
824 * hw-device.h, hw-device.c (hw_strdup): New function.
825
826 * hw-base.c (hw_create): Use hw_strdup when saving a copy of the
827 strings name, family and args.
828 (full_name_of_hw): Use hw_strdup when returning the full path.
829
830 * hw-properties.c: Clean up property not found / wrong type error
831 messages.
832
833 * hw-tree.c (hw_tree_parse): Finish a devices initialization
834 before attaching any ports.
835
836 * hw-base.c (hw-config.): Include. Replace hardwired table.
837
838 * dv-glue.c: Copy over ../ppc/hw_glue.c. Update to new framework.
839
840 * Make-common.in: Add rule for dv-glue.o.
841
775b309a
AC
842Sun Mar 22 16:45:54 1998 Andrew Cagney <cagney@b1.cygnus.com>
843
b2846e63
AC
844 * hw-base.c (hw_finish): Move setting of trace level to here.
845 (hw_create): From here.
846
775b309a
AC
847 * hw-base.h, hw-base.c (do_hw_attach_regs): Copy function from
848 ../ppc/device_table.c.
849
850 * dv-pal.c (hw_pal_finish): Attach PAL device to parent bus.
851
852 * hw-tree.c (print_properties): Supress path when printing
853 properties of root node.
854
937a4bdc
AC
855Sun Mar 22 16:21:15 1998 Andrew Cagney <cagney@b1.cygnus.com>
856
857 * hw-device.h (HW_TRACE): Define.
858 (hw_trace): Declare.
859 * hw-device.c (hw_trace): Implement function.
860
861 * hw-base.c (hw_create): Set hw trace level from "trace?"
862 property.
863
864 * dv-core.c (dv_core_attach_address_callback): Add trace.
865
866 * dv-pal.c: Replace DTRACE with HW_TRACE.
867
e5f0d498
AC
868Sun Mar 22 15:23:35 1998 Andrew Cagney <cagney@b1.cygnus.com>
869
870 * hw-device.h (HW_ZALLOC, HW_MALLOC): New macros.
871 (hw_alloc_data): Delcare.
872 (struct hw): Add member alloc_of_hw.
873
874 * hw-device.c (hw_zalloc, hw_malloc, hw_free, hw_free_all): New
875 functions. Assocate memory with a device.
876 (stdlib.h): Include.
877
878 * hw-base.h (set_hw_delete): Define.
879 (hw_delete_callback): Declare.
880 (hw_delete): Declare.
881
882 * hw-base.c (hw_delete): Implement function.
883 (struct hw_base_data): Add member to_delete.
884 (ignore_hw_delete): New function, does nothing.
885 (hw_create): Set the hw_delete method.
886 (hw_create): Allocate the base type using HW_ZALLOC before setting
887 any methods.
888
775b309a
AC
889 * hw-tree.h, hw-tree.c (hw_tree_delete): New function.
890
e5f0d498
AC
891 * hw-properties.c: Replace zalloc/zfree with hw_zalloc/hw_free.
892
893 * hw-ports.c: Replace zalloc/zfree with hw_zalloc/hw_free.
894 (attach_hw_port_edge): Add struct hw argument
895
896 * dv-pal.c (hw_pal_finish): Replace zalloc/zfree with
897 hw_zalloc/hw_free.
898
b1e9223c
AC
899Sun Mar 22 15:09:52 1998 Andrew Cagney <cagney@b1.cygnus.com>
900
901 * hw-device.h (hw_attach_address_callback,
902 hw_detach_address_callback): Attach to a single space not a space
903 mask. Clarify interpretation of SPACE:ADDR parameters.
904
905 * hw-base.c (passthrough_hw_attach_address,
906 passthrough_hw_detach_address): Update.
907 * dv-core.c (dv_core_attach_address_callback): Ditto.
908 * dv-pal.c (hw_pal_attach_address): Ditto.
909
910Thu Mar 19 00:41:00 1998 Andrew Cagney <cagney@b1.cygnus.com>
911
912 * sim-options.h: Document additional CPU arg to OPTION_HANDLER.
913
ae7c3446
AC
914Wed Mar 18 14:13:02 1998 Andrew Cagney <cagney@b1.cygnus.com>
915
916 * Make-common.in (SIM_HW_OBJS, SIM_HW_SRC, SIM_DV_OBJS): Define.
917 (hw-base_h, hw-device_h, hw-handles_h, hw-instances_h, hw_ports_h,
918 hw-properties_h, hw-tree_h): Define, point at corresponding
919 header.
920 (hw_base_headers): Define list of headers included by hw-base.h
921 (hw-base.o, hw-device.o, hw-instances.o, hw-handles.o, hw-ports.o,
922 hw-properties.o, hw-tree.o): Specify dependencies.
923 (dv-core.o, dv-pal.o): Ditto.
924
925 * sim-hw.h: New file.
926
927 * hw-device.h, hw-device.c, hw-properties.h, hw-properties.c,
928 hw-ports.h, hw-ports.c: New files. Copied from ../ppc/device.[ch].
929
930 * hw-tree.h, hw-tree.c: New files. Copied from ../ppc/tree.[hc].
931
932 * hw-base.h, hw-base.c: new files. Copied from
933 ../ppc/device_table.[hc].
934
935 * dv-core.c, dv-pal.c: New files. Copied from
936 ../ppc/hw_{core,pal}.c
937
938 * sim-basics.h (struct hw): Declare.
939 (enum port_direction, enum object_disposition): Declare.
940
9a8e61f1
AC
941Wed Mar 18 12:38:12 1998 Andrew Cagney <cagney@b1.cygnus.com>
942
943 * aclocal.m4 (SIM_AC_OPTION_HARDWARE): Set sim_hw_obj, sim_dv_obj,
944 sim_dv_src in Makefile. Take list of devices as parameter to m4
945 macro..
946
947 * configure: Regenerated to track ../common/aclocal.m4 changes.
948
a8ff5026
AC
949Mon Mar 16 12:37:33 1998 Andrew Cagney <cagney@b1.cygnus.com>
950
951 * sim-trace.h, sim-trace.c (trace_prefix): Pass in sim_cia so that
952 trace_prefix can abort cleanly.
953
84c6d152
DE
954Sat Mar 14 18:36:12 1998 Doug Evans <devans@seba.cygnus.com>
955
956 * dv-sockser.c, dv-sockser.h: New files.
957 * Make-common.in (dv-sockser.o): Add rule for.
958 * aclocal.m4: Check for fcntl.h.
959 * config.h: Add HAVE_FCNTL_H.
960
961 * sim-break.c (remove_breakpoint): Fix thinko.
962
963 * sim-hload.c (sim_load): Provide default value of SIM_HANDLES_LMA.
964 Use SIM_HANDLES_LMA for lma_p arg to sim_load_file.
965
93f75411
FF
9661998-03-13 Fred Fish <fnf@cygnus.com>
967
968 * sim-base.h (struct sim_state_base): Add prog_syms and
969 define macro STATE_PROG_SYMS.
a8ff5026 970 * sim-trace.c (trace_prefix): Add variables abfd, symsize,
93f75411
FF
971 symbol_count, and asymbols. Call bfd_get_symtab_upper_bound
972 and bfd_canonicalize_symtab, to get symbol table on first use
973 and preserve it via STATE_PROG_SYMS for future calls to
974 bfd_find_nearest_line.
975
976Wed Mar 11 14:02:47 1998 Andrew Cagney <cagney@b1.cygnus.com>
977
978 * sim-core.h, sim-core.c (sim_core_map_to_str): Delete.
979
980 * sim-core.c (sim_core_attach): Handle a generic number of maps -
981 up to nr_maps, not just access_* maps.
982
983 * sim-profile.h (struct PROFILE_DATA): Track nr_maps different
984 maps.
985
986 * sim-profile.c (profile_print_core): Make map unsigned. Iterate
987 over nr_maps not sim_core_nr_maps.
988
989 * sim-events.h, sim-events.c (sim_events_watch_core): Change
990 core_map argument to unsigned.
991 (struct _sim_core): Ditto for struct member core_map.
992
993 * sim-core.h (nr_sim_core_maps, sim_core_*_map): Delete
994
995 * sim-basics.h (access_io, access_*_io): Define.
996 (map_read, map_write, map_exec, map_io): Define.
997
998 * sim-core.c, sim-core.h (sim_core_attach): Replace argument
999 attach with more generic mapmask.
1000 (sim_core_{read,write}_*): Change map argument to unsigned.
1001
1002 * sim-core.c (sim_core_uninstall, sim_core_attach,
1003 sim_core_detach): Iterate over nr_maps instead of
1004 sim_core_nr_maps.
1005
1006 * sim-break.c (insert_breakpoint): Write breakpoints to exec_map
1007 instead of the write_map.
1008 (remove_breakpoint): Ditto.
1009
1010 * genmloop.sh (engine_resume_full): Replace sim_core_*_map
1011 with read_map, write_map, exec_map resp.
1012
1013 * cgen-mem.h (DECLARE_GETMEM, DECLARE_SETMEM, DECLARE_GETIMEM):
1014 Ditto.
1015
1016 * cgen-utils.c (sim_disassemble_insn): Ditto.
1017
1018 * sim-hrw.c (sim_write, sim_write): Ditto.
1019
1020 * sim-utils.h, sim-utils.c (access_to_str, map_to_str,
1021 transfer_to_str): New functions.
1022
bda9d8a3
DE
1023Mon Mar 9 12:50:59 1998 Doug Evans <devans@seba.cygnus.com>
1024
1025 * sim-base.h (sim_state_base): New member environment.
1026 (STATE_ENVIRONMENT): New macro.
1027 * sim-config.c (current_environment): Delete.
1028 (sim_config_default): New function.
1029 (sim_config): Set STATE_ENVIRONMENT, not current_environment.
1030 * sim-config.h (current_environment,CURRENT_ENVIRONMENT): Delete.
1031 (sim_config_default): Add prototype.
1032 * sim-module.c (sim_pre_argv_init): Call sim_config_default.
1033 * sim-options.c (standard_option_handler, case OPTION_ENVIRONMENT):
1034 Set STATE_ENVIRONMENT, not current_environment.
1035
c391655e
JW
1036Mon Mar 9 11:59:03 1998 Jim Wilson <wilson@cygnus.com>
1037
1038 * sim-fpu.c (NR_GUARDS64): Change NR_PAD32 to NR_PAD64.
1039
3cdda79a
AC
1040Tue Mar 3 10:53:05 1998 Andrew Cagney <cagney@b1.cygnus.com>
1041
1042 * sim-types.h (SIGNED32, SIGNED64): Pacify GCC.
1043
1044 * sim-alu.h (ALU64_BEGIN): Make alu64_r unsigned.
1045
de13b4cb
DE
1046Mon Mar 2 10:20:06 1998 Doug Evans <devans@seba.cygnus.com>
1047
3d4e3414 1048 * Make-common.in (TAGS): Make smarter.
40d160dd 1049 * Makefile.in (TAGS): Ditto.
3d4e3414 1050
b0df95bb
DE
1051Fri Feb 27 19:09:57 1998 Doug Evans <devans@canuck.cygnus.com>
1052
1053 * sim-module.c (*): Fix typos in assertion tests.
1054
baf8377d
AC
1055Sat Feb 28 13:54:10 1998 Andrew Cagney <cagney@b1.cygnus.com>
1056
1057 * sim-module.c (sim_pre_argv_init): String passed to asprintf
1058 can't be constant.
1059
1060 * sim-options.c (sim_parse_args): Ditto.
1061 (sim_args_command): Return OK, instead of nothing, for an empty
1062 command.
1063
0e701ac3
AC
1064Fri Feb 27 13:29:13 1998 Andrew Cagney <cagney@b1.cygnus.com>
1065
1066 * sim-profile.c (profile_info): Rename from profile_print. Drop
1067 misc and misc_cpu callback arguments. Use
1068 PROFILE_INFO_CPU_CALLBACK and STATE_PROFILE_INFO_CALLBACK instead.
1069 (profile_install): Install profile_info function.
1070
1071 * sim-profile.h (PROFILE_INFO_CPU_CALLBACK,
1072 STATE_PROFILE_INFO_CALLBACK): Define.
1073 (struct PROFILE_DATA): Add field info_cpu_callback.
1074 (profile_print): Delete function.
1075
1076 * sim-base.h (STATE_MODULES): Define. Replace individual
1077 STATE_*_LIST with single struct module_list.
1078
1079 * sim-module.h (MODULE_INFO_FN, MODULE_INFO_LIST): Declare.
1080 (struct module_list): Declare.
1081
1082 * sim-module.h, sim-module.c (sim_module_add_info_fn,
1083 sim_module_info): New functions.
1084 (sim_module_install): Clean up module data structures.
1085
1086 * sim-info.c (sim_info): New file. New function. Call
1087 sim_module_info.
1088
1089 * Make-common.in (sim-info.o): Define rule.
1090 (SIM_NEW_COMMON_OBJS): Add sim-info.o.
1091
1092
966df580
DE
1093Fri Feb 27 18:26:16 1998 Doug Evans <devans@canuck.cygnus.com>
1094
1095 * sim-base.h (sim_cpu_base): New members name, options.
1096 (sim_cpu_lookup): Add prototype.
1097 * sim-module.c (sim_pre_argv_init): Provide default names for cpus.
1098 * sim-options.h (DECLARE_OPTION_HANDLER): New argument `cpu'.
1099 (sim_add_option_table): Update prototype.
1100 * sim-options.c (sim_add_option_table): New argument `cpu'.
1101 (standard_option_handler,standard_install): Update.
1102 (sim_parse_args): Handle cpu specific options.
1103 (print_help): New static function.
1104 (sim_print_help): Call it. Print cpu specific options.
1105 (find_match): New static function.
1106 (sim_args_command): Call it. Handle cpu specific options.
1107 * sim-utils.c (sim_cpu_lookup): New function.
1108 * sim-memopt.c (memory_option_handler): Update.
1109 (sim_memopt_install): Update.
1110 * sim-model.c (model_option_handler): Update.
1111 (model_install): Update.
1112 * sim-profile.c (profile_option_handler): Update.
1113 (profile_install): Update.
1114 * sim-trace.c (trace_option_handler): Update.
1115 (trace_install): Update.
1116 * sim-watch.c (watchpoint_option_handler): Update.
1117 (sim_watchpoint_install): Update.
1118 * cgen-scache.c (scache_option_handler): Update.
1119 (scache_install): Update.
1120
6cd37f15
DE
1121Wed Feb 25 11:00:26 1998 Doug Evans <devans@canuck.cygnus.com>
1122
1123 * Make-common.in (check): Run `make check' in testsuite dir.
1124
390ffa89
AC
1125Wed Feb 25 14:40:24 1998 Andrew Cagney <cagney@b1.cygnus.com>
1126
1127 * sim-trace.c (trace_result0): New function.
1128
1129 * sim-trace.h (TRACE_FP_*, TRACE_FPU_*): Rename TRACE_FPU_*
1130 macro's to TRACE_FP_*. TRACE_FPU_* should be defined and used when
1131 tracing sim_fpu variables.
1132 (TRACE_ALU_RESULT0): Define.
1133 (TRACE_FP_RESULT_WORD): Define.
1134 (TRACE_FP_INPUT_WORD1): Define.
1135
1136 * sim-fpu.c, sim-fpu.h (sim_fpu_max32, sim_fpu_max64, sim_fpu_one,
1137 sim_fpu_two): New constants.
1138 (sim_fpu_op1, sim_fpu_op2): New types.
1139 (struct _sim_fpu): Delete member result. Re-order other members.
1140 (sim_fpu_sign, sim_fpu_exp): New functions.
1141 (sim_fpu_max, sim_fpu_min): new functions.
1142 (EXPMAX32, EXPMAX64, NR_PAD32, NR_PAD64, NR_GUARDS32, NR_GUARDS64,
1143 NORMAL_EXPMAX32, NORMAL_EXPMAX64): Define.
1144
3910fb4a
DE
1145Tue Feb 24 22:45:39 1998 Doug Evans <devans@seba.cygnus.com>
1146
1147 * sim-profile.c (profile_print): Delete duplicate test of
1148 PROFILE_INSN_IDX.
1149 (profile_print_pc): Exit early if data collection not set up.
ab062d22
DE
1150 (profile_print_core): Simplify by calling sim_core_map_to_str.
1151 * sim-core.h (sim_core_map_to_str): Declare.
1152 * sim-core.c (sim_core_map_to_str): Make non-static.
3910fb4a 1153
b500809f
DE
1154 * genmloop.sh (engine_resume): Update insn_count before exiting.
1155 (engine_resume_full): Keep accurate core profile data.
1156
1157 * cgen-utils.c (sim_disassemble_insn): Don't use
1158 sim_core_read_aligned_N, it messes up profiling results.
1159
845a5917
MA
1160Mon Feb 23 20:45:57 1998 Mark Alexander <marka@cygnus.com>
1161
1162 * nltvals.def: Regenerate with MN10300 additions.
1163
d3e1d594
AC
1164Tue Feb 24 13:18:42 1998 Andrew Cagney <cagney@b1.cygnus.com>
1165
1166 * sim-trace.h (TRACE_ALU_RESULT2): Define.
1167
1168 * sim-trace.h, sim-trace.c (trace_result_word2,
1169 trace_input_word4, trace_result_word4): New function.
1170
36dbc8bb
DE
1171Mon Feb 23 13:08:35 1998 Doug Evans <devans@canuck.cygnus.com>
1172
93f34464
DE
1173 * cgen-sim.h (SEM_NEXT_PC): New arg `len'.
1174
36dbc8bb
DE
1175 * sim-xcat.h: Delete.
1176 * cgen-mem.h: Delete inclusion of sim-xcat.h.
1177 * cgen-sim.h: Ditto.
1178 * sim-alu.h: Replace sim-xcat.h with symcat.h.
1179 * sim-n-bits.h: Ditto.
1180 * sim-n-core.h: Ditto.
1181 * sim-n-endian.h: Ditto.
1182
3aeca462
MM
1183Mon Feb 23 13:19:58 1998 Michael Meissner <meissner@cygnus.com>
1184
1185 * syscall.c (cb_syscall): Handle short reads, and EOF.
1186
0325f2dc
AC
1187Tue Feb 24 00:29:57 1998 Andrew Cagney <cagney@b1.cygnus.com>
1188
1189 * sim-trace.c (print_data): case trace_fmt_fp missing break. Use
1190 sim_fpu to safely print fp_word values.
1191 (print_data): Add trace_fmt_bool and trace_fmt_addr.
1192 (trace_result_bool1, trace_result_addr1): New functions.
1193 (trace_input_bool1, trace_input_addr1): New functions.
1194
1195 * sim-trace.h (TRACE_FPU_*): Define.
1196
bdfe5c04
AC
1197Mon Feb 23 13:24:54 1998 Andrew Cagney <cagney@b1.cygnus.com>
1198
1199 * sim-fpu.h (enum sim_fpu_class): Add sim_fpu_class_denorm.
1200 (sim_fpu_fpto, sim_fpu_tofp): Define.
1201
9655c439
AC
1202Fri Feb 20 18:08:51 1998 Andrew Cagney <cagney@b1.cygnus.com>
1203
1204 * sim-fpu.c (sim_fpu_cmp): New function.
1205
1206Wed Feb 18 16:29:21 1998 Doug Evans <devans@canuck.cygnus.com>
1207
1208 * cgen-utils.h (sim_disassemble_insn): Use CGEN_INSN_BITSIZE
1209 instead of abuf->length.
1210 * sim-trace.c (trace_options): Have -t only trace a few useful things.
1211 (set_trace_option_mask): Renamed from set_trace_options.
1212 (set_trace_option): New function.
1213 (trace_option_handler): Update calls to set_trace_option{,_mask}.
1214 * sim-trace.h (TRACE_USEFUL_MASK): New macro.
1215
8dcc896d
AC
1216Wed Feb 18 12:42:15 1998 Andrew Cagney <cagney@b1.cygnus.com>
1217
1218 * sim-basics.h: Declare struct _sim_fpu.
1219
1220Tue Feb 17 16:27:46 1998 Andrew Cagney <cagney@b1.cygnus.com>
1221
1222 * sim-trace.h (TRACE_ALU_INPUT*, TRACE_ALU_RESULT): Define.
1223 (trace_prefix, trace_input*, trace_result*): Declare.
1224 (trace_one_insn): Change declaration, assume trace_prefix called.
1225 (trace_generic): Like trace_one_insn.
1226 (TRACE_ALU_IDX, TRACE_*_IDX): Change #define's to enum.
1227 (TRACE_alu, TRACE_[a-z]*): Update.
1228
1229 * sim-trace.c (trace_prefix, trace_input*, trace_result*,
1230 trace_insn, save_data, trace_idx_to_str, print_data): New
1231 functions.
1232 (trace_one_insn): Rewrite.
1233 (trace_generic): New function.
1234
4f071e30
DE
1235Tue Feb 17 17:27:30 1998 Doug Evans <devans@seba.cygnus.com>
1236
5bd0ca86
DE
1237 * Make-common.in (CGEN_MAIN_SCM): Update.
1238 * aclocal.m4 (USE_MAINTAINER_MODE): New variable.
1239
4f071e30
DE
1240 * cgen-sim.h (SEMANTIC_CACHE_FN): Delete.
1241 (SEMANTIC_FN): Rewrite declaration.
1242 (DECODE): Update type of semantic_fast member.
1243 ({EX,SEM}_FN_NAME): Have only one version.
1244 * cgen.sh: Support building cpu.c.
1245 * sim-base.h (sim_state_base): Delete conditionals surrounding
1246 member scache_size.
1247
e0deacd2
AC
1248Tue Feb 10 18:31:49 1998 Andrew Cagney <cagney@b1.cygnus.com>
1249
1250 * sim-load.c (sim_load_file): Print LMA/VMA according to value
1251 used.
1252
1253Tue Feb 10 14:56:23 1998 Ian Carmichael <iancarm@cygnus.com>
1254
1255 * sim-core.c: Add missing prototypes for WITH_DEVICES.
1256 Add missing parameters to device_io calls.
1257 * sim-core.h: Add missing parameters to device_io calls.
1258
dde54cb8
DE
1259Mon Feb 9 14:48:37 1998 Doug Evans <devans@canuck.cygnus.com>
1260
e61871ce 1261 * cgen-sim.h (DECODE): Always use switch for `read' for now.
6b373fab
DE
1262 (PAREXEC): Renamed from PARALLEL_EXEC. All uses updated.
1263 (SEMANTIC{,_CACHE}_FN): Fix return type.
e61871ce 1264 * cgen.sh (decode): Add s/@arch@/$arch/.
dde54cb8
DE
1265 * genmloop.sh (@cpu@_engine_run): Delete `current_state'.
1266 (engine_resume): Likewise. Make `engine' volatile. Save copy
e61871ce
DE
1267 of cpu pointer in volatile object. Initialize read switch if
1268 -parallel.
dde54cb8 1269
61b62559
DE
1270Thu Feb 5 13:27:04 1998 Doug Evans <devans@seba.cygnus.com>
1271
1272 * cgen-sim.h (EX_FN_NAME): _exc_ -> _ex_.
1273 (SEM_INSN): New macro.
1274
37379a25
AC
1275Tue Feb 3 16:31:56 1998 Andrew Cagney <cagney@b1.cygnus.com>
1276
1277 * sim-run.c (sim_engine_run): Assume IMEM is 32 bit.
1278
a97f304b
AC
1279Sun Feb 1 16:47:51 1998 Andrew Cagney <cagney@b1.cygnus.com>
1280
1281 * configure: Regenerated to track ../common/aclocal.m4 changes.
1282
1283Sun Feb 1 16:16:57 1998 Andrew Cagney <cagney@b1.cygnus.com>
1284
1285 * sim-types.h (fp_word): New type, define according to
1286 WITH_TARGET_FLOATING_POINT_BITSIZE.
1287
1288 * aclocal.m4 (default_sim_floating_point_bitsize): Add
1289 configuration of size of floating point registers.
1290
01737f42
AC
1291Sun Feb 1 14:02:31 1998 Andrew Cagney <cagney@b1.cygnus.com>
1292
1293 * sim-profile.c (profile_print): Only print CPU <N> if other
1294 output is going to appear.
1295
412c4e94
AC
1296Sat Jan 31 18:15:41 1998 Andrew Cagney <cagney@b1.cygnus.com>
1297
1298 * configure: Regenerated to track ../common/aclocal.m4 changes.
1299
1300Sat Jan 31 18:03:55 1998 Andrew Cagney <cagney@b1.cygnus.com>
1301
1302 * sim-types.h (address_word): Typedef according to
1303 WITH_TARGET_ADDRESS_BITSIZE.
1304 (signed_cell, unsigned_cell, natural_cell): Ditto using
1305 WITH_TARGET_CELL_BITSIZE.
1306
1307 * sim-config.h (WITH_TARGET_ADDRESS_BITSIZE): Define.
1308 (WITH_TARGET_CELL_BITSIZE): Define.
1309 (WITH_HOST_WORD_BITSIZE): Delete.
1310
1311 * sim-config.c (print_sim_config): Update.
1312
1313 * aclocal.m4 (SIM_AC_OPTION_BITSIZE): Add support for
1314 configuration of address and OpenFirmware cell sizes.
1315
9ec6741b
AC
1316Fri Jan 30 09:36:33 1998 Andrew Cagney <cagney@b1.cygnus.com>
1317
1318 * sim-engine.h (sim_engine_run): Add argument nr_cpus.
1319 * sim-run.c (sim_engine_run): Update.
1320
1321 * sim-engine.h (SIM_ENGINE_HALT_HOOK): Use SET_CPU_CIA instead of
1322 CPU_CIA.
1323 * sim-run.c (sim_engine_run): Ditto.
1324
1325 * sim-resume.c (sim_resume): Obtain nr_cpus from sim_engine.
1326 (sim_resume): Pass nr_cpus to sim_engine_run.
1327
1328 * sim-engine.h (struct _sim_engine): Add member nr_cpus.
1329
1330 * sim-engine.c (sim_engine_init): Hardwire nr_cpus to
1331 MAX_NR_PROCESSORS.
1332 (sim_engine_nr_cpus) sim-engine.c, sim-engine.h: New function
1333
7caebec6
DE
1334Thu Jan 29 12:13:01 1998 Doug Evans <devans@canuck.cygnus.com>
1335
1336 * cgen.sh: Portably read parms past $9.
1337
ed6f1471
DE
1338Fri Jan 23 14:20:54 1998 Doug Evans <devans@seba.cygnus.com>
1339
1340 * Make-common.in (stamp-tvals): New rule.
1341 (targ-vals.h,targ-map.c): Depend on it.
1342 (clean): Remove stamp-tvals.
1343
e9ae18ef
MM
1344Tue Jan 20 21:35:13 1998 Michael Meissner <meissner@cygnus.com>
1345
1346 * sim-utils.c (sim_state_alloc): #if 0 variable that is only used
1347 in code also #if 0'ed.
1348
462cfbc4
DE
1349Mon Jan 19 22:26:29 1998 Doug Evans <devans@seba>
1350
1351 * configure: Regenerated to track ../common/aclocal.m4 changes.
1352 * aclocal.m4: Recognize --enable-maintainer-mode.
1353
189e2694
DE
1354Mon Jan 19 12:45:45 1998 Doug Evans <devans@seba.cygnus.com>
1355
36de6f40 1356start-sanitize-cygnus
189e2694
DE
1357 * Make-common.in (cgen-{arch,cpu,decode}): New targets.
1358 * cgen.sh: New file.
36de6f40 1359end-sanitize-cygnus
189e2694 1360 * cgen-scache.h: Deleted.
4a44afd5 1361 * Make-common.in (cgen-run.o,cgen-scache.o): Delete cgen-scache.h dep.
462cfbc4 1362 (CGEN_CPU_SCM): Add sim-model.scm.
189e2694
DE
1363 * cgen-scache.c: Only compile contents if WITH_SCACHE.
1364 (scache_init): Use runtime computed size of SCACHE.
1365 (scache_flush): Likewise.
1366 * cgen-mem.h (GETIMEMU[QHSD]I): Declare.
1367 ([GS]ETT{QI,UQI,HI,UHI,SI,USI,DI,UDI}): Declare.
1368 * cgen-sim.h: Scache support moved here.
1369 (PC): Redo definition.
1370 (ARGBUF,SCACHE,PARALLEL_EXEC): Provide forward decls.
1371 (DECODE): Add parallel execution support.
1372 Only include semantic label members if using switch.
1373 (SWITCH,CASE,BREAK,DEFAULT,ENDSWITCH): Portable computed goto support.
1374 (CGEN_CPU): Delete members exec_state, halt_sigrc, halt_jmp_buf.
1375 (IADDR,CIA,SEM_ARG,EX_FN_NAME,SEM_FN_NAME,RECORD_IADDR,SEM_ARGBUF,
1376 SEM_NEXT_PC,SEM_BRANCH_VIA_{CACHE,ADDR},SEM_NEW_PC_ADDR): Moved here
1377 from cgen-types.h.
1378 (engine_{stop,run,resume,halt,signal}): Delete decls.
1379 * cgen-types.h (CGEN_{XCAT3,CAT3}): Delete.
1380 (argbuf,scache): Delete forward decls.
1381 (STATE): Delete decl.
1382 * cgen-utils.c: Don't include decode.h, mem-ops.h, sem-ops.h.
1383 Include cgen-mem.h, cgen-ops.h.
1384 (engine_halt,engine_signal): Delete.
1385 ({ex,exc,sem,semc}_illegal): Delete.
1386 (sim_disassemble_insn): Result of extract fn is in bits.
1387 * genmloop.sh: Rewrite.
1388
1389 * cgen-trace.c (trace_insn): Set printed_result_p=0 if not tracing
1390 line numbers.
1391
1392 * sim-base.h (sim_state_base): Delete member `model'.
1393 (sim_cpu_base): Add member `model'.
1394 * sim-model.h (IMP_PROPERTIES): New type.
1395 (MACH): New members imp_props, models.
1396 (models): Delete decl.
1397 * sim-model.c (set_model): Update.
1398 * sim-profile.c (profile_print_model): Update.
1399
1400 * sim-utils.c (sim_state_alloc): Delete setting of cpu backlink here.
1401
ef13d3e3
NC
1402Fri Jan 16 12:33:09 1998 Nick Clifton <nickc@cygnus.com>
1403
1404 * cgen-trace.c (trace_insn): Call CGEN_INSN_MNEMONIC() rather than
1405 CGEN_INSN_SYNTAX().
1406
1407Mon Dec 15 23:17:11 1997 Andrew Cagney <cagney@b1.cygnus.com>
1408
1409 * configure: Regenerated to track ../common/aclocal.m4 changes.
1410 * config.in: Ditto.
1411
1412Mon Dec 15 23:16:03 1997 Andrew Cagney <cagney@b1.cygnus.com>
1413
1414 * aclocal.m4 (AR): Check for sigaction.
1415
6e51f990
DE
1416Thu Dec 4 09:21:05 1997 Doug Evans <devans@canuck.cygnus.com>
1417
9bb68e20
DE
1418 * Make-common.in (sim-core.o): Depend on $(sim_main_headers).
1419
1420 * sim-config.h (WITH_TREE_PROPERTIES): Define as 0.
1421 * sim-config.c (sim_config): Replace WITH_DEVICES with
1422 WITH_TREE_PROPERTIES.
1423
6e51f990
DE
1424 * configure: Regenerated to track ../common/aclocal.m4 changes.
1425
22469a10
DE
1426Wed Dec 3 17:56:02 1997 Doug Evans <devans@canuck.cygnus.com>
1427
1428 * Make-common.in (SIM_ENVIRONMENT): New variable.
1429 (CONFIG_CFLAGS): Add it.
1430 * aclocal.m4 (SIM_AC_OPTION_ENVIRONMENT): Handle
1431 --enable-sim-environment option.
1432 * configure: Regenerated.
1433 * sim-config.h (environment support): Rewrite.
1434 * sim-config.c (current_environment): Define as enum, unconditionally.
1435 (current_alignment): Define unconditionally.
1436 (config_environment_to_a): Update.
1437 (config_alignment_to_a): Fix type of argument. Define unconditionally.
1438 (sim_config): Handle environment and alignment determination
1439 unconditionally. Delete sanity checks of current_environment,
1440 unnecessary.
1441 (print_sim_config): Update.
1442 * sim-options.c (STANDARD_OPTIONS enum): Add OPTION_ENVIRONMENT.
1443 (standard_options): Add --environment.
1444 (standard_option_handler): Likewise.
1445
1446Fri Nov 28 12:21:25 1997 Andrew Cagney <cagney@b1.cygnus.com>
1447
1448 * sim-alu.h: Add notes on carry vs borrow for subtraction.
1449 (ALU{,8,16,32,64}ADD): Redefine ADD macro as add overflowing.
1450 (ALU{,8,16,32,64}ADDC): Define - add carrying.
1451 (ALU{,8,16,32,64}SUB): Redefine SUB macro as subtract overflowing.
1452 (ALU{,8,16,32,64}SUBB): Define - subtract borrowing.
1453 (ALU{,8,16,32,64}SUBC): Define - tract carrying.
1454 (ALU{,8,16,32,64}ADD_CA, ALU{,8,16,32,64}ADDC_C): Replace single
1455 argument ADD_CA macro with two argument ADDC_C - add carrying with
1456 carry in.
1457 (ALU{,8,16,32,64}SUB_CA, ALU{,8,16,32,64}SUBC_X): Replace single
1458 argument SUB_CA macro with two argument SUBC_X - subtract
1459 carrying, extended.
1460 (ALU{,8,16,32,64}SUBB_B): Define - subtract borrowing with
1461 borrow-in.
1462 (ALU{,8,16,32,64}NEGC, ALU{,8,16,32,64}NEGB): Define.
1463
97b25f99
MM
1464Sun Nov 30 17:40:57 1997 Michael Meissner <meissner@cygnus.com>
1465
1466 * sim-io.c (sim_io_{syscalls,getstring}): Delete. No longer used.
1467 * sim-io.h (sim_io_syscalls): Delete.
1468
465db791
MM
1469Fri Nov 28 20:10:09 1997 Michael Meissner <meissner@cygnus.com>
1470
f2907f74
MM
1471 * syscall.c (cb_syscall): Add missing else, so write to stdout
1472 isn't doubled.
1473
465db791
MM
1474 * sim-alu.h (ALU{,8,16,32,64}_SET_CARRY): Provide macros to import
1475 the carry bit from the CPU's psw.
1476
1294727e
DE
1477Fri Nov 28 11:15:05 1997 Doug Evans <devans@canuck.cygnus.com>
1478
ef13d3e3 1479 * gennltvals.sh: Redo syscall support.
1294727e
DE
1480 * nltvals.def: Regenerated.
1481
ac070413
MM
1482Wed Nov 26 16:49:38 1997 Michael Meissner <meissner@cygnus.com>
1483
1484 * syscall.c (cb_syscall): If writing to stdout or stderr, flush
1485 the stream immediately.
1486
3885125c
AC
1487Wed Nov 26 12:32:11 1997 Andrew Cagney <cagney@b1.cygnus.com>
1488
1489 * sim-io.c (sim_io_getstring): Delete unused len2.
1490 (sim_io_syscalls): Ditto for sys_errno.
1491
fc63d75a
DE
1492Wed Nov 26 11:18:40 1997 Doug Evans <devans@canuck.cygnus.com>
1493
4123aca8 1494 * syscall.c (cb_syscall): Test CB_SYSCALL struct magic number.
fc63d75a 1495
6be03509
DE
1496 * Make-common.in (run.o): Depend on remote-sim.h.
1497 (nrun.o,sim-hload.o,sim-hrw.o): Likewise.
1498 (sim-io.o,sim-reason.o,sim-resume.o): Likewise.
1499
69628a60
MM
1500Tue Nov 25 20:12:46 1997 Michael Meissner <meissner@cygnus.com>
1501
1502 * sim-io.c (sim_io_syscalls): Disable lseek.
1503
c76e6683
DE
1504Tue Nov 25 00:12:38 1997 Doug Evans <devans@seba.cygnus.com>
1505
1506 * gennltvals.sh: Generate syscall values for d30v.
965f5327 1507
1294727e 1508 * gennltvals.sh: Use libgloss/syscall.h for sparc.
c76e6683
DE
1509 * nltvals.def: Regenerate.
1510
f3367306
DE
1511 * callback.c (os_stat): Make 3rd arg a host struct stat ptr.
1512 (os_fstat): Likewise. Validate fd argument.
1513 (cb_host_to_target_stat): Delete big_p arg. If HS arg is NULL,
1514 just compute target stat struct length.
1515 * syscall.c: #include "libiberty.h", <sys/types.h>, <sys/stat.h>.
1516 (ENOSYS,ENAMETOOLONG): Provide definitions if missing.
1517 (get_string): Return host errno values so they can be properly
1518 translated later.
1519 (cb_syscall): Likewise.
1520 (cb_syscall, cases open,unlink): Use get_path instead of get_string.
1521 (cb_syscall, case read): Use read_stdin for file descriptor 0.
1522 (cb_syscall, case write): Use write_stderr for file descriptor 2.
1523 (cb_syscall): Add cases for lseek, unlink, stat, fstat, time.
1524 (get_path): New function.
1525
3445e1ce
MM
1526Mon Nov 24 18:56:07 1997 Michael Meissner <meissner@cygnus.com>
1527
1528 * sim-io.c (sim_io_syscalls): New function to provide system call
1529 emulation. Provide exit, open, close, read, write, lseek, and
1530 unlink.
1531 (sim_io_getstring): New function to return a string from a
1532 simulated memory location.
1533
1534 * sim-io.h (sim_io_syscalls): Add declaration.
1535
f2ea8913
DE
1536Mon Nov 24 12:09:59 1997 Doug Evans <devans@seba.cygnus.com>
1537
1538 * sim-core.c (sim_core_signal): Fix spelling error in message.
1539
1540 * sim-hrw.c (sim_read): Use read map, not write map.
1541
f375dd7d
DE
1542 * Make-common.in (all): Add .gdbinit.
1543 * gdbinit.in: Add dump command.
1544
4b5545c9
DE
1545 * sim-model.c (model_options): Use '\0' for `shortopt'.
1546
091521c4
DE
1547 * sim-trace.c (trace_option_handler): Set state trace file
1548 for --trace-file in addition to cpu's values.
1549 (trace_vprintf): If cpu == NULL, try state's trace file.
c76e6683 1550 (trace_options): Reorganize table, reword some descriptions.
8f3cfc0e 1551
4ba8d09f
AC
1552Sun Nov 23 10:57:00 1997 Andrew Cagney <cagney@b1.cygnus.com>
1553
1554 * sim-fpu.c (sim_fpu_abs, sim_fpu_neg, sim_fpu_inv), sim-fpu.h:
1555 New functions.
1556
aaa11abe
AC
1557Sat Nov 22 19:16:54 1997 Andrew Cagney <cagney@b1.cygnus.com>
1558
4ba8d09f 1559 * sim-reason.c (sim_stop_reason): For sim_signalled, return the
aaa11abe
AC
1560 signal untranslated, document problem with this.
1561
1562 * nrun.c (main): Check for a prog name of `*step'. If present,
1563 step the simulator instead of allowing it to run free.
1564
1565 * sim-signal.c (SIGQUIT): Define on _MSC_VER hosts.
1566
1567 * Make-common.in (sim_main_headers): Add sim-signal.h.
1568
a1cf18dc
AC
1569Fri Nov 21 09:32:32 1997 Andrew Cagney <cagney@b1.cygnus.com>
1570
1571 * sim-signal.c (sim_signal_to_host): Return 0 for SIM_SIGNONE.
1572
232156de
AC
1573Thu Nov 20 20:35:20 1997 Andrew Cagney <cagney@b1.cygnus.com>
1574
1575 * sim-signal.h: Start simulator signals at 64 so that host signal
1576 numbers can be detected and reported.
1577
1578 * sim-signal.h (SIM_SIGFPE), sim-signal.h: Add signal.
1579
398057b7
DE
1580Wed Nov 19 12:02:41 1997 Doug Evans <devans@seba.cygnus.com>
1581
ac1d2660
DE
1582 * callback.c (cb_host_to_target_stat): Fix return values.
1583
998d2c82
DE
1584 * cgen-sim.h (enum_signal_type): Delete.
1585 (engine_signal): Update prototype.
1586 * cgen-utils.c: Don't include <signal.h>.
1587 (sim_signal_to_host): Delete, lives in sim-signal.c now.
1588 (engine_signal): Update.
1589
398057b7
DE
1590 * sim-utils.c (sim_state_alloc): Call SIM_STATE_ALLOC if defined.
1591 (sim_state_free): Call SIM_STATE_FREE if defined.
1592
1593 * sim-module.c (sim_module_install): Don't leave any modules
1594 installed if one fails to install.
1595
eb5f3fcd
MM
1596Wed Nov 19 13:25:48 1997 Michael Meissner <meissner@cygnus.com>
1597
e163bbbf
MM
1598 * sim-options.c: Don't include ../libiberty/alloca-conf.h any
1599 more, since alloca is not used in this file.
1600
eb5f3fcd
MM
1601 * sim-alu.h (ALU{32,64}_*): Rewrite 32 and 64 bit ALU support to
1602 correctly set the carry and overflow bits for those types.
1603 (ALU{8,16,32,64}_{ADD,SUB}_CA): Take VAL argument to add along
1604 with carry, so carry is correct after doing both adds.
1605 (ALU*): Space out '\' to make it easier to read.
1606
e5ce1670
DE
1607Tue Nov 18 15:53:45 1997 Doug Evans <devans@canuck.cygnus.com>
1608
a4b44a2b
DE
1609 * sim-core.c (sim_core_signal): Use sim_stopped instead of
1610 sim_signalled.
1611
1ebc7e0e
DE
1612 * sim-signal.c, sim-signal.h: New files.
1613 * Make-common.in (sim-signal.o): Add rule for.
1614 (SIM_NEW_COMMON_OBJS): Add sim-signal.o.
1615 * sim-abort.c: Don't include <signal.h>.
1616 * sim-basics.h: #include "sim-signal.h".
1617 * sim-break.c: Don't include <signal.h>.
1618 (sim_handle_breakpoint): Replace SIGTRAP with SIM_SIGTRAP.
1619 * sim-core.c: Don't include <signal.h>.
1620 (SIGBUS): Delete definition.
1621 (sim_core_signal): Replace SIGSEGV,SIGBUS with SIM_SIGSEGV,SIM_SIGBUS.
1622 * sim-engine.c: Don't include <signal.h>.
1623 (sim_engine_abort): Replace SIGABRT with SIM_SIGABRT.
1624 * sim-reason.c (sim_stop_reason): Call sim_signal_to_host.
1625 * sim-resume.c: Don't include <signal.h>.
1626 (SIGTRAP): Delete definition.
1627 (has_stepped): Replace SIGTRAP with SIM_SIGTRAP.
1628 * sim-stop.c: Don't include <signal.h>.
1629 (control_c_simulation): Replace SIGINT with SIM_SIGINT.
1630 * sim-watch.c: Don't include <signal.h>.
1631 (handle_watchpoint): Replace SIGINT with SIM_SIGINT.
1632
e5ce1670
DE
1633 * Make-common.in (SIM_NEW_COMMON_OBJS): New variable.
1634
1635 * sim-base.h (CIA_ADDR): Provide default definition.
340d8e20 1636 * sim-core.c (sim_core_signal): Use CIA_ADDR to fetch value.
13c9499d 1637 * sim-break.c (sim_handle_breakpoint): Likewise.
e5ce1670 1638
f7abc1ca
DE
1639Mon Nov 17 14:15:31 1997 Doug Evans <devans@seba.cygnus.com>
1640
38377b3a
DE
1641 * Make-common.in (srccom): New variable.
1642
f7abc1ca
DE
1643 * Make-common.in (DEP, COMMON_DEP_CFLAGS): Define.
1644 (LIB_OBJS): Add syscall.o.
1645 (gentmap): Pass $(NL_TARGET) to $(CC).
1646 (syscall.o): Add rule for.
1647 (sim_main_headers): Add $(SIM_EXTRA_DEPS).
1648 (sim-bits.o): Depend on $(sim-n-bits_h).
1649 (sim-load.o): Depend on callback.h.
1650
1651 * Make-common.in (cgen-*.o): Update dependencies, mem-ops.h renamed to
1652 cgen-mem.h, sem-ops.h renamed to cgen-ops.h.
1653 * cgen-mem.h, cgen-ops.h: New files.
1654
1655 * aclocal.m4 (--enable-sim-scache): Pass -DWITH_SCACHE=0 for "=no".
1656
1657 * Makefile.in (nltvals.def): Depend on gennltvals.sh.
1658 Rewrite build rule.
1659 * callback.c: #include string.h or strings.h.
1660 #include sys/types.h and sys/stat.h.
1661 (cb_init_syscall_map,cb_init_errno_map,cb_init_open_map): Declare.
f7abc1ca
DE
1662 (os_get_errno,os_open): Update.
1663 (os_stat,os_fstat): New functions.
1664 (os_init): Initialize syscall_map, errno_map, open_map.
1665 (default_callback): Add entries for os_stat, os_fstat, syscall_map,
1666 errno_map, open_map, signal_map, stat_map.
1667 (cb_read_target_syscall_maps): New function.
1668 (cb_target_to_host_syscall): New function.
1669 (cb_host_to_target_errno): Renamed from host_to_target_errno.
1670 (cb_target_to_host_open): Renamed from target_to_host_open.
1671 (store): New function.
1672 (cb_host_to_target_stat): New function.
1673 * syscall.c: New file.
1674 * gentmap.c (sys_tdefs): New global.
1675 (gen_targ_vals_h): Output target syscall numbers.
1676 (gen_targ_map_c): Update. Output target syscall translation map.
1677 * gentvals.sh: New first argument `target'. Preface table with
1678 #ifdef NL_TARGET_$target if non-null target passed.
1679 * gennltvals.sh: New file.
1680 * nltvals.def: Regenerated.
1681
1682Fri Nov 14 11:33:34 1997 Andrew Cagney <cagney@b1.cygnus.com>
1683
1684 * sim-n-core.h (sim_core_read_unaligned_N): Return static
1685 sim_core_dummy_M.
1686 (sim_core_dummy_M): Declare.
1687
1688Wed Nov 12 18:16:15 1997 Andrew Cagney <cagney@b1.cygnus.com>
1689
1690 * sim-core.c (sim_core_signal): Print the address of the
1691 instruction.
1692
9e8a900a
DE
1693Thu Nov 13 11:49:41 1997 Doug Evans <devans@seba.cygnus.com>
1694
1695 * sim-base.h (sim_state_base): Move `magic' to end of struct.
1696
1697 * sim-base.h (sim_state_base): Add member trace_data.
1698 (STATE_TRACE_DATA): New macro.
1699 * sim-trace.h (TRACE_DEBUG_IDX,TRACE_debug): New macros.
1700 ({WITH_,}TRACE_DEBUG_P): New macros.
1701 (STATE_TRACE_FLAGS,STRACE_P,STRACE_DEBUG_P): New macros.
1702 (_sim_cpu): Delete forward reference.
1703 (debug_printf): Update.
1704 * sim-trace.c (OPTION_TRACE_DEBUG): Define.
1705 (trace_options): Add --trace-debug.
1706 (set_trace_options): Handle it.
1707 (trace_option_handler): Likewise.
1708 (trace_install): Init state trace_data struct.
1709 (trace_uninstall): Close state trace file.
1710 * sim-events.c (ETRACE): Only print source file and line number if
1711 --trace-debug.
1712 * sim-n-core.h (sim_core_trace_M): Likewise.
1713
1714 * sim-core.c (sim_core_signal): Add missing "\n" in message.
1715
c7e3f734
FL
17161997-11-13 Felix Lee <flee@cygnus.com>
1717
1718 * sim-n-core.h (sim_core_read_unaligned_N): illegal empty
1719 initializer.
1720 * sim-types.h (unsigned128,signed128): fix typo for MSVC.
1721
15f5035c
DE
1722Wed Nov 12 12:18:08 1997 Doug Evans <devans@canuck.cygnus.com>
1723
1724 * aclocal.m4 (SIM_AC_OPTION_SCACHE): Fix typo.
1725
5dcf955d
DE
1726 * Make-common.in (BUILT_SRC_FROM_COMMON): Remove files no longer
1727 built this way.
1728 (sim-config.o): Remove non-existent $(sim-nconfig_h) dependency.
1729 (clean): Don't delete $(BUILT_SRC_FROM_COMMON) if building in
1730 source tree.
1731
f445a890
AC
1732Tue Nov 11 13:28:02 1997 Andrew Cagney <cagney@b1.cygnus.com>
1733
1734 * sim-events.c (sim_events_process): Re-compute the time -
1735 update_time_from_event - as each event is processed. Reverses
1736 previous change.
1737
8cb060b6
AC
1738Fri Nov 7 00:37:36 1997 Andrew Cagney <cagney@b1.cygnus.com>
1739
1740 * callback.c (os_poll_quit): Replace _WIN32 with _MSC_VER.
1741
549bf950
AC
1742Fri Nov 7 00:37:36 1997 Andrew Cagney <cagney@b1.cygnus.com>
1743
1744 * sim-events.c (sim_events_process): Delete redundant call to
1745 update_time_from_event.
1746 (sim_events_slip): Always decrement time_from_event.
1747 (sim_events_tick, sim_events_deschedule, update_time_from_event):
1748 Delete assertion that time_from_event >=0 when work in queue, no
1749 longer applicable.
1750
864519b9
AC
1751Thu Nov 6 12:06:46 1997 Andrew Cagney <cagney@b1.cygnus.com>
1752
1753 * sim-options.c (STANDARD_OPTIONS): Change OPTION_* to an enum.
1754 (standard_option_handler): Update.
1755
1756 * sim-options.h: Clarify documentation.
1757 (OPTION_LONG_ONLY_P): Delete definition.
1758 (OPTION_VALID_P): Define.
1759
1760 * sim-options.c (sim_print_help): Allow short only options.
1761 (sim_parse_args): Ditto.
1762 (sim_args_command): Skip short only options.
1763 (sim_parse_args): Allocate space for NUM_OPTS not just 256. Make
1764 separate entries for short and long options in the HANDLERS and
1765 ORIG_VAL tables.
1766 (sim_parse_args): Disable argument permutation.
1767
63be8feb
AC
1768Wed Nov 5 13:40:31 1997 Andrew Cagney <cagney@b1.cygnus.com>
1769
1770 * sim-core.h (DECLARE_SIM_CORE_WRITE_N. DECLARE_SIM_CORE_READ_N):
1771 Add argument M, size of data type.
1772 (sim_core_read_misaligned_3, sim_core_write_misaligned_3):
1773 Declare, ditto for 5, 6 & 7 byte transfers.
1774 (sim_core_write_unaligned_1, sim_core_write_unaligned_1): Define
1775 as aligned variant.
1776
1777 * sim-n-core.h (sim_core_trace_M): Rename from
1778 sim_core_trace_N. Add nr_bytes argument. Replace transfer argument
1779 with transfer type. Print transfer direction. Handle 1 and 2 byte
1780 transfers.
1781 (sim_core_read_unaligned_N, sim_core_write_unaligned_N): Trace
1782 unaligned accesses.
1783 (unsigned_M, T2H_M, H2T_M): Rename from unsigned_N, T2H_N, H2T_N.
1784 Update all functions.
1785
1786 * sim-core.c: Generate functions starting with 16 not 1.
1787 (sim_core_read_unaligned_3): Generate. Ditto for 3 byte write and
1788 all 5, 6 & 7 byte transfers.
1789
1790 * sim-n-core.h (sim_core_read_misaligned_N,
1791 sim_core_write_misaligned_N): Implement.
1792
a26ecda4
AC
1793Mon Nov 3 15:03:04 1997 Andrew Cagney <cagney@b1.cygnus.com>
1794
1795 * sim-endian.h (U16_8): Implement
1796
1797 * sim-endian.c (sim_endian_split_16, sim_endian_join_16): New functions
1798
1799 * sim-endian.h (VL8_16, VH8_16): Implement.
1800
1801 * sim-memopt.c (memory_option_handler): Typecast 64bit value to
1802 long in printf.
1803 (memory_option_handler): Only zalloc modulo bytes when non-zero.
1804 (memory_option_handler): Skip comma in alias address list
1805
fcc86d82
AC
1806Fri Oct 31 13:03:33 1997 Andrew Cagney <cagney@b1.cygnus.com>
1807
1808 * sim-memopt.c (do_memopt_add, do_memopt_delete): Add level and
1809 space params.
1810 (parse_size, parse_addr): New functions
1811 (memory_option_handler, memory_options): Parse address & size
1812 using new functions. Pass level, space, modulo to do_memopt_add &
1813 do_memopt_del.
1814
1815 * sim-memopt.h (struct _sim_memopt): Add level & space fields.
1816
1817 * sim-core.h (sim_core_arrach, sim_core_detach): Replace
1818 `attach_type attach' argument with `unsigned level' argument.
1819 Document.
1820
1821 * sim-core.c (new_sim_core_mapping, sim_core_map_attach,
1822 sim_core_attach): Replace argument attach with level. Update
1823 verification of arguments.
1824 (sim_core_map_detach, sim_core_detach): Replace argument attach
1825 with level.
1826
1827 * sim-basics.h (enum _attach_type): Delete.
1828
d048b52d
DE
1829Thu Oct 30 13:45:00 1997 Doug Evans <devans@seba.cygnus.com>
1830
1831 * sim-core.h (sim_core_write_8): Define.
1832
a86809d3
AC
1833Tue Oct 28 12:29:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
1834
01b9cd49
AC
1835 * sim-bits.h: Document ROTn macro.
1836
89d09738
AC
1837 * sim-endian.h (H2T): Handle 16 byte variables.
1838
1839 * sim-n-core.h (sim_core_read_unaligned_N): Return a dummy when an
1840 error.
1841
a86809d3
AC
1842 * sim-core.c: Do not generate sim_core_*_word.
1843
1844 * sim-n-core.h (sim_core_trace_N): Add line_nr argument.
1845 (sim_core_write_aligned_N, sim_core_read_aligned_N): Update.
1846
1847 * sim-core.h (sim_core_read_unaligned_word,
1848 sim_core_read_aligned_word, sim_core_read_word,
1849 sim_core_write_unaligned_word, sim_core_write_aligned_word,
1850 sim_core_write_word): Change to macros that map onto sim_core_*_N.
1851
374b95c1
DE
1852Mon Oct 27 11:25:10 1997 Doug Evans <devans@canuck.cygnus.com>
1853
1854 * sim-n-endian.h: Add TAGS entrys for 16 byte versions.
1855
c3e3e4ad
DE
1856 * sim-endian.h: Disable 16 byte support.
1857
f45dd42b
AC
1858Mon Oct 27 12:00:48 1997 Andrew Cagney <cagney@b1.cygnus.com>
1859
1860 * sim-endian.c (_SWAP_16): Define. Generate 126 bit swap code.
1861
1862 * sim-n-core.h (sim_core_trace_N): New function.
1863 (sim_core_read_aligned_N, sim_core_write_aligned_N): Use,
1864 (sim_core_read_unaligned_N): Do not retyrn bogus value wden error.
1865
1866 * sim-endian.h: Add 128 bit variant.
1867
1868 * sim-core.h, sim-core.c: Add 128 bit variant.
1869
1870 * sim-types.h: Add signed128 and unsigned128 types using a struct.
1871
4a203fba
AC
1872Fri Oct 24 11:33:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
1873
1874 * sim-events.c (sim_events_process): Clear events->work_pending.
1875 (sim_events_tickn, sim_events_tick): Accumulate, instead of
1876 setting, nr_ticks_to_process.
1877 (sim_events_preprocess): Allow nr_ticks_to_process to be non-zero
1878 when the event queue isn't next.
1879
1880 * sim-events.h, sim-events.c (sim_events_slip): New function.
1881
9e03a68f
AC
1882Wed Oct 22 14:18:38 1997 Andrew Cagney <cagney@b1.cygnus.com>
1883
1884 * sim-hload.c (sim_load): Pass lma_p==0 and do_load=sim_load.
1885
1886 * sim-utils.h, sim-load.c (sim_load_file): Add lma_p and do_load
1887 arguments.
1888
897a1d78
DE
1889Tue Oct 21 18:37:57 1997 Doug Evans <devans@canuck.cygnus.com>
1890
1891 * nrun.c (main): Remove useless test of name != NULL.
2328ef1c 1892 Exit if bfd_openr fails. Call bfd_check_format after bfd_openr.
897a1d78 1893
b7432f0f
AC
1894Tue Oct 21 10:42:38 1997 Andrew Cagney <cagney@b1.cygnus.com>
1895
1896 * sim-fpu.c (EXPMAX): Type is unsigned.
1897 (MIN_INT, MAX_INT): Type is signed64.
1898 (i2fpu): Type of val is signed64.
1899
e2f8ffb7
AC
1900Tue Oct 21 10:42:38 1997 Andrew Cagney <cagney@b1.cygnus.com>
1901
1902 * sim-profile.h (PROFILE_PC_BUCKET_SIZE): Treat a shift of zero as
1903 a bucket size of zero.
1904
1905 * sim-profile.c (OPTION_PROFILE_PC_GRANULARITY,
1906 OPTION_PROFILE_PC): Define.
1907 (profile_option_handler): Add support for --profile-pc and
1908 --profile-pc-granularity options.
1909 (profile_pc_init): When possible, compute nr buckets from bucket
1910 size.
1911
1912 * sim-profile.c (profile_pc_init): Align the profile-pc end
1913 address with the profile-pc bucket size.
1914
1915 * sim-profile.h (PROFILE_PC_NR_BUCKETS): Rename PROFILE_PC_SIZE to
1916 something less ambiguous.
1917 (PROFILE_PC_BUCKET_SIZE): Ditto for PROFILE_PC_SAMPLE_SIZE.
1918
1919 * sim-profile.c (profile_pc_cleanup): New function. Move
1920 profile_pc_uninstall code to here.
1921 (profile_pc_uninstall): Call.
1922 (profile_pc_init): Call.
1923
293a0876
AC
1924Mon Oct 20 17:23:58 1997 Andrew Cagney <cagney@b1.cygnus.com>
1925
e2f8ffb7
AC
1926 * sim-profile.c (profile_print_pc): Dump pc profile to dmon.out
1927 file using BSD gprof format.
1928
293a0876
AC
1929 * sim-bits.h (LSBIT, MSBIT, BIT): Force result to type
1930 unsigned_word.
1931 (LSBIT8, LSBIT16, LSBIT32, LSBIT64, MSBIT8, MSBIT16, MSBIT32,
1932 MSBIT64): Force result to unsignedN.
1933
0a0ecb21
AC
1934Thu Oct 16 11:38:56 1997 Andrew Cagney <cagney@b1.cygnus.com>
1935
1936 * sim-alu.h (ALU16_BEGIN, ALU32_BEGIN, ALU64_BEGIN): Drop opening
1937 brace from macro.
1938 (ALU8_BEGIN, ALU8_SET, ALU8_ADD, ALU8_SUB, ALU8_NEGATE): Define.
1939 (ALU16_ADD, ALU16_SUB, ALU16_NEGATE): Simplify arrithmetic.
1940 (ALU32_ADD, ALU32_SUB, ALU32_NEGATE): Simplify arrithmetic.
1941 (ALU64_ADD, ALU64_SUB, ALU64_NEGATE): Simplify arrithmetic.
1942
fd89abc2
AC
1943Wed Oct 15 09:24:19 1997 Andrew Cagney <cagney@b1.cygnus.com>
1944
1945 * sim-core.h (struct _sim_core_mapping): Change free_buffer to
1946 type void*.
1947
1948 * sim-core.c (sim_core_uninstall, new_sim_core_mapping,
1949 sim_core_map_attach, sim_core_map_detach): Change free_buffer to
1950 type void*.
1951 (sim_core_attach): Rename buffer_freed to free_buffer, type
1952 void*. Ensure that allocated buffer is alligned according to
1953 region's address.
1954
7456a10d
AC
1955Mon Oct 13 11:34:50 1997 Andrew Cagney <cagney@b1.cygnus.com>
1956
1957 * sim-alu.h (ALU64_HAD_OVERFLOW): Define.
1958 (ALU64_SUB): Define.
1959
1960 * Make-common.in (all): Build SIM_EXTRA_ALL first.
1961 (.gdbinit): Remove dependencies, generate once per build.
1962
1b217de0
AC
1963Tue Oct 14 19:20:09 1997 Andrew Cagney <cagney@b1.cygnus.com>
1964
1965 * sim-n-core.h (sim_core_read_aligned_N,
1966 sim_core_write_aligned_N): Make xaddr param type address_word not
1967 unsigned_word.
1968
1969Fri Oct 3 09:49:18 1997 Andrew Cagney <cagney@b1.cygnus.com>
1970
1971 * sim-fpu.h, sim-fpu.c: Rewrite. Change sim_fpu object to an
1972 unpacked floating point struct. Pass sim_fpu object by reference.
1973 Add preliminary support for rounding modes.
1974
63fe2cc7
AC
1975Fri Oct 3 09:28:00 1997 Andrew Cagney <cagney@b1.cygnus.com>
1976
1977 * configure: Regenerated to track ../common/aclocal.m4 changes.
1978
1979Thu Oct 2 19:43:52 1997 Andrew Cagney <cagney@b1.cygnus.com>
1980
1981 * aclocal.m4 (sim-bitsize): Fix typo, WITH_TARGET_WORD_BITSIZE not
1982 WITH_TARGET_BITSIZE.
1983
1984Thu Sep 25 23:20:20 1997 Felix Lee <flee@yin.cygnus.com>
1985
1986 * sim-profile.c (profile_print_core): label needs empty statement.
1987
1988Thu Sep 25 11:20:47 1997 Stu Grossman <grossman@babylon-5.cygnus.com>
1989
1990 * sim-break.c (sim_set_breakpoint sim_clear_breakpoint): Use ZALLOC
1991 and zfree instead of xmalloc and free. Prevents warnings.
1992
af51b8d5
AC
1993Wed Sep 24 17:38:57 1997 Andrew Cagney <cagney@b1.cygnus.com>
1994
1995 * configure: Regenerated to track ../common/aclocal.m4 changes.
1996
1997Wed Sep 24 17:23:31 1997 Andrew Cagney <cagney@b1.cygnus.com>
1998
1999 * Make-common.in (SIM_BITSIZE): Assign from configured value.
2000 (CONFIG_CFLAGS): Add SIM_BITSIZE.
2001
2002 * aclocal.m4 (--enable-sim-bitsize): Developer option for
2003 controling the bitsize/msb of the target.
2004
b9d580a4
SG
2005Wed Sep 24 17:41:40 1997 Stu Grossman <grossman@babylon-5.cygnus.com>
2006
2007 * Make-common.in: New files sim-break.c, sim-break.h.
2008 * sim-base.h: Add point to breakpoint list to sim_state_base.
2009 * sim-break.c sim-break.h: New modules that implement intrinsic
2010 breakpoint support.
2011 * sim-module.c: Add breakpoint module.
2012
34d07b78
FL
2013Tue Sep 23 00:26:39 1997 Felix Lee <flee@yin.cygnus.com>
2014
2015 * sim-events.c (SIM_EVENTS_POLL_RATE): poll more often than once
2016 an hour.
2017 * sim-n-core.h (WITH_XOR_ENDIAN): MSVC barfs on
2018 if (0) { 1 % 0; }
2019 * sim-core.c (sim_core_xor_write_buffer): WITH_XOR_ENDIAN + 1.
2020 (SIGBUS) define for Windows.
2021 * sim-trace.c (trace_printf,debug_printf): added ALMOST_STDC.
2022 * sim-resume.c: define SIGTRAP for windows.
2023 * sim-xcat.h: use token pasting if ALMOST_STDC.
2024
4141b1c6
AC
2025Tue Sep 23 11:04:38 1997 Andrew Cagney <cagney@b1.cygnus.com>
2026
2027 * Make-common.in (SIM_SCACHE, SIM_DEFAULT_MODEL): Assign
2028 configured values.
2029 (CONFIG_CFLAGS): Add same.
2030
9f4fd823
FL
2031Mon Sep 22 17:20:27 1997 Felix Lee <flee@cygnus.com>
2032
2033 * sim-types.h (SIGNED64): ##i64 when _MSC_VER, not _WIN32.
2034 (SIGNED32): use ##i32.
2035
92f91d1f
AC
2036Tue Sep 23 11:04:38 1997 Andrew Cagney <cagney@b1.cygnus.com>
2037
2038 * configure: Regenerated to track ../common/aclocal.m4 changes.
2039
2040Tue Sep 23 10:07:47 1997 Andrew Cagney <cagney@b1.cygnus.com>
2041
2042 * aclocal.m4 (sim-endian): Simplify logic determining [default]
2043 endian of target.
2044
2045 * Make-common.in (SIM_WARNINGS, SIM_ALIGNMENT, SIM_ENDIAN,
2046 SIM_HOSTENDIAN, SIM_RESERVED_BITS, SIM_ASSERT, SIM_FLOAT,
2047 SIM_HARDWARE, SIM_INLINE, SIM_PACKAGES, SIM_REGPARM, SIM_SMP,
2048 SIM_STDCALL, SIM_XOR_ENDIAN): Assign configured values.
2049 (CONFIG_CFLAGS): Add same.
2050
2051 * aclocal.m4: Perform AC_SUBST on optional options.
2052
4ca7d6d2
AC
2053Mon Sep 22 11:46:20 1997 Andrew Cagney <cagney@b1.cygnus.com>
2054
8d332f9c
AC
2055 * sim-config.h (WITH_DEFAULT_ALIGNMENT): Don't hardwire any alignment.
2056
2057 * sim-options.c (standard_option_handler): Typo in warning message.
2058
4ca7d6d2
AC
2059 * sim-base.h (STATE_MODEL): Make conditional on SIM_HAVE_MODEL.
2060
2061 * sim-profile.c (profile_print_insn): Check 0 .. MAX_INSN for any
2062 insn count. Make count conditional on there being a valid
2063 INSN_NAME.
2064 (profile_pc_init): Make default PC profile frequency an arbitrary
2065 256.
2066
2067 * sim-base.h: Ditto.
2068
2069 * sim-profile.h (WITH_PROFILE_MODEL_P): Only enable modeling when
2070 SIM_HAVE_MODEL.
2071
2072 * sim-model.h (struct MACH): Depreciate, to be replaced by bfd
2073 archure struct.
2074
794e9ac9
AC
2075Mon Sep 22 11:46:20 1997 Andrew Cagney <cagney@b1.cygnus.com>
2076
2077 * configure: Regenerated to track ../common/aclocal.m4 changes.
2078
2079Mon Sep 22 11:45:00 1997 Andrew Cagney <cagney@b1.cygnus.com>
2080
2081 * aclocal.m4 (sim_alignment): Simplify logic for selecting the
2082 configured alignment.
2083
b45caf05
AC
2084Fri Sep 19 17:45:25 1997 Andrew Cagney <cagney@b1.cygnus.com>
2085
2086 * configure: Regenerated to track ../common/aclocal.m4 changes.
2087
2088Fri Sep 19 17:26:14 1997 Andrew Cagney <cagney@b1.cygnus.com>
2089
2090 * sim-config.c (sim_config): Check for default alignment.
2091
2092 * sim-options.c (standard_option_handler): Add alignment option.
2093
2094 * aclocal.m4 (sim_alignment): Allow configuration of hardwired and
2095 default alignment requirements on memory accesses.
2096
2097Fri Sep 19 11:51:35 1997 Jeffrey A Law (law@cygnus.com)
2098
2099 * sim-load.c (sim_load_file): Return failure if the executable
2100 had no loadable sections.
2101
dfa5c0ca
AC
2102Wed Sep 17 13:33:28 1997 Andrew Cagney <cagney@b1.cygnus.com>
2103
175c6fd3
AC
2104 * sim-events.c (ETRACE): Use trace_printf not sim_io_printf for
2105 trace output.
2106
2107 * sim-core.c (sim_core_signal): When bad access halt simulator
2108 SIGSEGV / SIGBUS instead of aborting.
2109 (signal.h): Include.
2110
2111 * sim-watch.c (sim_watchpoint_install): Handler for watchpoint
2112 options was missing.
2113
dfa5c0ca
AC
2114 * sim-bits.h (MOVED): Define
2115
b52e58c2
AC
2116Wed Sep 17 10:33:28 1997 Andrew Cagney <cagney@b1.cygnus.com>
2117
2118 * sim-alu.h (ALU32_HAD_OVERFLOW): Pacify GCC, Use MSBIT instead of
2119 BIT.
2120
2121 * sim-bits.h (LSBIT, MSBIT): Check for overflow of shift value.
2122
2123 * sim-bits.c: Add 8 bit versions of bit macros.
2124
2125 * sim-bits.h: Ditto.
2126
aa5e6a5a
AC
2127Tue Sep 16 16:15:16 1997 Andrew Cagney <cagney@b1.cygnus.com>
2128
2129 * sim-bits.c (LSSEXT, MSSEXT): Replace SEXT.
2130 (LSINSERTED, MSINSERTED): Ditto for INSERTED.
2131
2132 * sim-n-bits.h (MSSEXTn, LSSEXTn): Replace SEXTn.
2133 (LSINSERTDn, MSINSERTEDN): Ditto for INSERTEDn.
2134
2135 * sim-bits.h (SEXT*): Define as MSEXT/LSEXT.
2136 (INSERTED*): Ditto for LSINSERTED/MSINSERTED.
2137
08547b1f
AC
2138Mon Sep 15 17:36:15 1997 Andrew Cagney <cagney@b1.cygnus.com>
2139
2140 * aclocal.m4 (SIM_AC_COMMON): Add optional config.h file argument.
2141 configure.in: Output to cconfig.h instead of config.h.
2142
2143 * configure: Regenerated to track ../common/aclocal.m4 changes.
2144
2145Mon Sep 15 15:39:28 1997 Andrew Cagney <cagney@b1.cygnus.com>
2146
2147 * sim-utils.c (sim_analyze_program): Set STATE_ARCHITECTURE from
2148 BFD if known.
2149
4bdab45a
AC
2150Tue Sep 9 21:46:46 1997 Felix Lee <flee@cygnus.com>
2151
2152 * callback.c (os_write): divert stdout and stderr to their
2153 respective hooks.
2154
93e7a1b5
AC
2155Thu Sep 11 10:08:48 1997 Andrew Cagney <cagney@b1.cygnus.com>
2156
2157 * sim-profile.c (profile_print_speed): Call
2158 sim_events_elapsed_time instead of PROFILE_EXEC_TIME for moment.
2159
2160 * sim-events.c (sim_events_elapsed_time): New function return nr
2161 host MS consumed by the simulator.
2162 (sim_watch_valid): Use.
2163
2164 * sim-module.c (modules): Install sim_events very very early.
2165
2166 * sim-profile.c (profile_print): Call profile_print_pc.
2167 (print_bar):
2168 (profile_pc_init): New function, set up processor for PC
2169 profiling.
2170 (profile_print_pc): New function, print a PC profile.
2171 (profile_pc_event): New function, sample PC.
2172
2173 * sim-profile.h (PROFILE_PC_COUNT, PROFILE_PC_START,
2174 PROFILE_PC_END, PROFILE_PC_SHIFT, PROFILE_PC_SAMPLE_SIZE): Add to
2175 profile struct.
2176
2177 * sim-options.c (sim_print_help): Pacify GCC.
2178
2179 * sim-n-core.h (sim_core_read_aligned_N,
2180 sim_core_write_aligned_N): Add un-conditional profile call.
2181 (sim_core_read_unaligned_N, sim_core_write_unaligned_N): Add
2182 profile call when aligned read/write isn't used.
2183
2184 * sim-base.h: Include sim-profile, sim-model after sim-core &
2185 sim-events allow sim-core to define useful values.
2186
2187 * sim-profile.c (OPTION_PROFILE_CORE): Define.
2188 (profile_option_handler, profile_options): Add support for
2189 --profile-core option.
2190 (print_bar): Include when core profiling.
2191 (profile_print_core): New function, print core profile.
2192
2193 * sim-config.c (print_sim_config): Print profile status.
2194
2195 * sim-profile.h (PROFILE_NEXT_IDX, PROFILE_core,
2196 WITH_PROFILE_PC_P): Define.
2197 (PROFILE_CORE_COUNT): Count each core-map/size separatly.
2198 (PROFILE_COUNT_CORE): Define.
2199
cad7297e
AC
2200Thu Sep 11 08:44:52 1997 Andrew Cagney <cagney@b1.cygnus.com>
2201
2202 * sim-watch.c (handle_watchpoint): Pass a char** index into the
2203 interrupt_names array as the data.
2204 (sim-watch.h): Document.
2205
2206Wed Sep 10 16:15:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
2207
2208 * sim-options.c (sim_print_help): When the doc string is to long
2209 word wrap it.
2210
2211 * sim-watch.c (sim_watchpoint_install): Use option.doc_name so
2212 that only the first few the watch options are listed. Generate
2213 meanginful usage messages.
2214
2215 * sim-options.h (struct OPTION): Clarify use of doc_name field
2216
d0b59aa5
AC
2217Wed Sep 10 13:23:24 1997 Andrew Cagney <cagney@b1.cygnus.com>
2218
2219 * sim-options.c (OPTION_ARCHITECTURE_INFO): New option.
2220 (standard_option_handler): Handle --architecture-info.
2221
31dda65a
FL
2222Tue Sep 9 21:46:46 1997 Felix Lee <flee@cygnus.com>
2223
2224 * sim-core.h (sim_cpu_core): [WITH_XOR_ENDIAN + 1], to avoid
2225 illegal zero-sized array.
2226 * sim-core.c (sim_core_xor_read_buffer): same.
2227
7b4aeeba
DE
2228Tue Sep 9 11:20:35 1997 Doug Evans <dje@canuck.cygnus.com>
2229
2230 * nltvals.def: Regenerate.
2231
75b3697d
AC
2232Tue Sep 9 02:10:36 1997 Andrew Cagney <cagney@b1.cygnus.com>
2233
2234 * sim-fpu.c (DP_FRACHIGH2): Define LL using SIGNED64.
2235
2236Mon Sep 8 12:22:20 1997 Andrew Cagney <cagney@b1.cygnus.com>
2237
2238 * sim-bits.c (MASKED): Delete.
2239 (EXTRACTED): Delete.
2240 (LSEXTRACTED, MSEXTRACTED): New functions.
2241
2242 * sim-n-bits.h (MASKEDn): Delete, define as MSMASKED or LSMASKED.
2243 (MSMASKEDn, LSMASKEDn): Add last argument.
2244 (MSMASK*): Ditto.
2245
2246 * sim-bits.h (EXTEND8, EXTEND16): Define.
2247 (EXTRACTED64): Define as 64 bit extract, not 32 bit.
2248
2249 * sim-run.c (sim_engine_run): Use CPU_CIA macro.
2250
2251 * sim-engine.h (SIM_ENGINE_HALT_HOOK): Use CPU_CIA to get at
2252 current instruction address.
2253
2254 * sim-inline.h (*_ENGINE): Define.
2255
30efae3a
AC
2256Fri Sep 5 08:39:02 1997 Andrew Cagney <cagney@b1.cygnus.com>
2257
1bba340a
AC
2258 * sim-core.c (sim_core_attach): Fix checks of modulo/mask.
2259
2260 * sim-watch.c (delete_watchpoint): Delete by ident and type.
2261 (watch_option_handler): Call delete_watchpoint with ident or type.
2262 (sim_watchpoint_install): Create interrupt specific watchpoint
2263 commands on the fly.
2264 (do_watchpoint_create): New function, create a watch point using
2265 type/int-nr info encoded in the option nr.
2266 (do_watchpoint_info): New function. List active watchpoints.
2267
2268 * sim-watch.h: Change data structure to a list.
2269
2270 * sim-memopt.c (memory_option_handler): Require explicit "all"
2271 before deleting all memory regions.
2272
1b465b54
AC
2273 * sim-utils.c (sim_do_commandf): New function, printf version of
2274 sim_do_command.
2275
2276 * sim-basics.h (asprintf, vasprintf): Hack, define for CYGWIN32.
2277
30efae3a
AC
2278 * sim-alu.h (ALU64_ADD): Use explicit MSEXTRACTED64, do not assume
2279 bit endianness.
2280 (SIGNED64, UNSIGNED64): Delete.
2281 (ALU64_ADD): Don't rely on bit endianness.
2282 (ALU64_BEGIN): Define.
2283
2284 * sim-n-bits.h (MSEXTRACTEDn, LSEXTRACTED): New functions.
2285 (EXTRACTEDn): Delete, define as either LSEXTRACTED or MSEXTRACTED.
2286
2287 * sim-types.h (SIGNED64, UNSIGNED64): New macros, attach relevant
2288 suffix - u64, LL - to 64 bit constants.
2289
a34abff8
AC
2290Thu Sep 4 09:27:54 1997 Andrew Cagney <cagney@b1.cygnus.com>
2291
6dbaff8f
AC
2292 * sim-config.c (sim_config): Add assert for SIM_MAGIC_NUMBER.
2293
2294 * sim-utils.h (NZALLOC): Define - zalloc * N.
2295
2296 * sim-hrw.c (sim_read, sim_write): New file. Provide generic
2297 implementation of read/write functions.
2298
2299 * Make-common.in (sim-hrw.o): New target.
2300
2301 * sim-base.h (STATE_MEMOPT_P): Delete, simulators _always_ add
2302 memory.
2303
2304 * sim-memopt.c (memory_option_handler): Implement memory-size
2305 command. Implement memory-alias command. Let memory-delete delete
2306 all memory regions.
2307 (add_memopt): New function. Add a memory region.
2308 (do_memopt_delete): New function. Delete a memory region.
2309
a34abff8
AC
2310 * sim-utils.c (sim_elapsed_time_get): Never return zero.
2311
2312 * sim-core.c (sim_core_detach): New function.
2313 (sim_core_map_detach): New function. Perform the actual detach.
2314 (sim_core_init): Move initialization code from here.
2315 (sim_core_install): To here.
2316 (sim_core_uninstall): And here.
2317
2318 * sim-module.c: Add memopt module.
2319
2320 * sim-base.h (STATE_MEMOPT, STATE_MEMOPT_P): Add memopt to
2321 simulator base type.
2322
2323 * Make-common.in (sim_main_headers): Add sim-memopt.h
2324 (sim-memopt.o): New target.
2325
2326 * sim-core.c (sim_core_install): Add core_options to the option
2327 table.
2328
2329 * sim-watch.c (watch_options): Make --delete-watch a synonym for
2330 --watch-delete.
2331
2332 * sim-config.h (WITH_MODULO_MEMORY): Define as 0. Update
2333 comments.
2334
2335 * sim-core.h (struct _sim_core_mapping): Change nr_bytes to type
2336 address_word, add mask member.
2337
2338 * sim-core.h, sim-core.c (sim_core_attach): Make nr_bytes of type
2339 address_word, allow for 64bit targets in 32bit host. Add modulo
2340 argument.
2341 (sim_core_map_attach): Ditto.
2342 (new_sim_core_mapping): Ditto.
2343 (sim_core_translate): Mask address when modulo memory.
2344
88d5f8e8
DE
2345Wed Sep 3 17:32:54 1997 Doug Evans <dje@seba.cygnus.com>
2346
600d8331
DE
2347 * sim-hload.c (sim_load): Add assert for SIM_MAGIC_NUMBER.
2348
88d5f8e8
DE
2349 * gdbinit.in: New file.
2350 * aclocal.m4 (SIM_AC_OUTPUT): Build .gdbinit.
2351 * Make-common.in (distclean): Delete .gdbinit.
2352 (.gdbinit): Add rule for.
2353 * configure: Regenerated to track ../common/aclocal.m4 changes.
2354
2355 * Make-common.in (cgen-run.o): Add rule for.
2356
fdd64f95
AC
2357Wed Sep 3 10:08:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
2358
2359 * sim-resume.c (sim_resume): Suspend/resume the simulator.
2360
2361 * sim-events.c (sim_watch_valid): Compute total elapsed time from
2362 both resumed and previous elapsed time.
2363 (sim_events_init): Set initial_wallclock and current_wallclock to
2364 zero.
2365 (sim_events_install): Install sim_events_suspend and
2366 sim_events_resume.
2367 (sim_events_watch_clock): Allow for suspended simulator when
2368 computing the time of the clock event.
2369
2370 * sim-events.h (struct _sim_event): Add resume_wallclock, rename
2371 initial_wallclock to elapsed_wallclock, set both to zero.
2372 (sim_events_init, sim_events_uninstall): Delete prototypes.
2373
2374 * sim-module.h (MODULE_SUSPEND_FN, MODULE_RESUME_FN): Define types.
2375
2376 * sim-module.c(sim_module_resume, sim_module_suspend): New
2377 functions.
2378
80c651f0
AC
2379Wed Sep 3 10:08:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
2380
2381 * sim-core.c (sim_core_map_attach): Clarify memory overlap error
2382 message.
2383
74db699d
DE
2384Tue Sep 2 14:57:06 1997 Doug Evans <dje@canuck.cygnus.com>
2385
2386 * Makefile.in (TAGS): Add support for "/* TAGS: foo */" marker.
645ab3ec 2387 * Make-common.in (TAGS): Likewise.
74db699d
DE
2388 * sim-n-bits.h: Add TAGS comments for all functions.
2389 * sim-n-core.h: Likewise.
2390 * sim-n-endian.h: Likewise.
2391
4b2a6aed
AC
2392Mon Sep 1 10:50:11 1997 Andrew Cagney <cagney@b1.cygnus.com>
2393
2394 * sim-utils.c (sim_state_alloc): Set CPU backlinks, callback and
2395 kind.
2396
2397 * sim-base.h (sim_state_alloc): Add callback and kind arguments.
2398
2399 * sim-base.h (INVALID_INSTRUCTION_ADDRESS): Add default
2400 definition.
2401
f90b720b
AC
2402Sat Aug 30 09:47:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
2403
2404 * sim-fpu.c (DP_GARDMSB, ...): Make unsigned.
2405 (DP_FRACHIGH, DP_FRACHIGH2, ..): Use MSMASK to avoid LL.
2406
2407Fri Aug 29 13:37:44 1997 Andrew Cagney <cagney@b1.cygnus.com>
2408
2409 * sim-core.c (sim_core_map_attach): Cast attach enum to int.
2410 (sim_core_xor_read_buffer, sim_core_xor_write_buffer): Make
2411 nr_transfered and nr_this_transfer unsigned.
2412
2413 * sim-events.c (sim_events_tickn): N is signed, as limited to
2414 MAXINT.
2415
2416 * sim-n-endian.h (offset_N): Change size to unsigned.
2417
2418 * callback.c (os_poll_quit): Add prototypes for kbhit and getkey.
2419
2420Fri Aug 29 10:10:53 1997 Andrew Cagney <cagney@b1.cygnus.com>
2421
2422 * sim-utils.c (sim_copy_argv): Delete, replaced by dupargv.
2423
2424 * sim-options.c (sim_parse_args): Use dupargv.
2425
36db8e64
DE
2426Thu Aug 28 10:36:34 1997 Doug Evans <dje@canuck.cygnus.com>
2427
2428 * sim-options.c (standard_option_handler): Use xstrdup, not strdup.
2429
18c319ae
AC
2430Thu Aug 28 12:09:15 1997 Andrew Cagney <cagney@b1.cygnus.com>
2431
2432 * sim-base.h (STATE_ARCHITECTURE, STATE_TARGET): Add to simulator
2433 base type.
2434
2435 * sim-options.c (standard_options): Add --architecture=MACHINE and
2436 --target=TARGET options.
2437 (OPTION_ARCHITECTURE, OPTION_TARGET): Define.
2438 (standard_option_handler): Handle architecture and target options.
2439 (bfd.h): Include.
2440
2441 * sim-utils.c (sim_analyze_program): Pass STATE_TARGET to
2442 bfd_openr.
2443 (sim_analyze_program): Set prog_bfd architecture from
2444 STATE_ARCHITECTURE if known.
2445
88117054
AC
2446Wed Aug 27 18:13:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
2447
2448 * configure: Regenerated to track ../common/aclocal.m4 changes.
2449 * config.in: Ditto.
2450
2451Wed Aug 27 18:11:30 1997 Andrew Cagney <cagney@b1.cygnus.com>
2452
2453 * aclocal.m4 (enable-sim-warnings): Remove comment stating
2454 that option does not apply to certain files.
2455
d6fea803
AC
2456Wed Aug 27 15:13:04 1997 Andrew Cagney <cagney@b1.cygnus.com>
2457
2458 * sim-bits.h (LSBIT8, LSBIT16, LSBIT32, LSBIT64, LSBIT, MSBIT8,
2459 MSBIT16, MSBIT32, MSBIT64, MSBIT): New macros - single bit as
2460 offset from MSB/LSB.
2461
2462 * sim-endian.h (A1_8, A2_8, A4_8, A1_4, A2_4, A1_2): New macro,
2463 access address of sub word quantity of a hosts 16, 32, 64 bit word
2464 type.
2465 (V1_2, V1_4, V2_4, V1_8, V2_8, V4_8): Ditto for values.
2466 (U8_1, U8_2, U8_4, U4_1, U4_2, U2_1): Ditto for set of values.
2467 (V2_H1, V2_L1, V4_H2, V4_L2, V8_L4, V8_H4): Given N byte argument,
2468 return N*2 byte value with argument in Hi/Lo word. Renamed from
2469 V1_H2, V1_L2, V2_H4, V2_L4, V4_H8, V4_L8.
2470
2471 * sim-alu.h (ALU32_HAD_OVERFLOW): Use 64 bit mask not 32bit.
2472 (ALU16_HAD_CARRY, ALU32_HAD_CARRY, ALU16_HAD_OVERFLOW): Use MSBIT
2473 so that bit offset is explicit.
2474
fafce69a
AC
2475Wed Aug 27 11:55:35 1997 Andrew Cagney <cagney@b1.cygnus.com>
2476
2477 * sim-utils.c (sim_analyze_program): Add prog_name argument.
2478 Update STATE_PROG_BFD when needed with a dup'd copy of the
2479 program.
2480
2481 * sim-config.c (sim_config): Delete ABFD argument, use
2482 STATE_PROG_BFD directly.
2483
2484Tue Aug 26 12:55:26 1997 Andrew Cagney <cagney@b1.cygnus.com>
2485
2486 * run.c (main): Pass the open ABFD to sim_create_inferior.
2487
2488 * nrun.c (main): Determine prog_bfd. Pass to sim_create_inferior
2489 and sim_load.
2490 (bfd.h): Include.
2491
2492 * sim-hload.c (sim_load): New file. Implement generic sim_load for
2493 hardware only simulator targets.
2494
2495 * Make-common.in (sim-hload.o): Add rule.
2496
d07dddd2
AC
2497Wed Aug 27 09:51:42 1997 Andrew Cagney <cagney@b1.cygnus.com>
2498
2499 * sim-utils.c (sim_copy_argv): Rewrite to match malloc strategy
2500 used by copyargv and freeargv.
2501
2502 * sim-options.c (sim_parse_args): Save a copy of PROG-ARGS in
2503 STATE_PROG_ARGV, not just a pointer.
2504
247fccde
AC
2505Mon Aug 25 17:50:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
2506
2507 * configure: Regenerated to track ../common/aclocal.m4 changes.
2508 * config.in: Ditto.
2509
2510Mon Aug 25 12:11:06 1997 Andrew Cagney <cagney@b1.cygnus.com>
2511
2512 * aclocal.m4 (sim-endian): Add second argument to
2513 SIM_AC_OPTION_ENDIAN. First is hardwired endian, second is
2514 default endian when not hardwired.
2515
2516 * sim-config.h (WITH_DEFAULT_TARGET_BYTE_ORDER): New macro, if all
2517 else failes value for target byte order.
2518
2519 * sim-config.c (sim_config): Add abfd arguments. Set
2520 STATE_PROG_BFD accordingly. Determine prefered_target_byte_order
2521 from same.
2522 (sim_config): Return SIM_RC, don't abort.
2523 (bfd.h): Include.
2524
2525 * run.c (main): Update call to sim_open - add ABFD argument.
2526 * nrun.c (main): Add NULL ABFD argument.
2527
052d7984
DE
2528Thu Aug 14 12:48:57 1997 Doug Evans <dje@canuck.cygnus.com>
2529
2530 * callback.c (os_poll_quit): Make static.
2531 Call sim_cb_eprintf, not p->eprintf.
2532 (sim_cb_printf, sim_cb_eprintf): New functions.
247fccde
AC
2533 * sim-utils.h (sim_cb_printf, sim_cb_eprintf): Declare.
2534
2535 * sim-basics.h (zalloc,zfree,sim_add_commas,SIM_ELAPSED_TIME,
2536 sim_elapsed_time_get,sim_elapsed_time_since): Move decls to
2537 sim-utils.h. #include sim-utils.h.
2538 * sim-utils.h: Above decls moved here.
2539 (sim_analyze_program,sim_load_file): Use `struct _bfd', not `bfd'.
2540
2541 * sim-watch.c (action_watchpoint): Fix thinkos.
052d7984
DE
2542
2543Thu Jul 24 08:48:05 1997 Stu Grossman (grossman@critters.cygnus.com)
2544
2545 * sim-types.h: Fix defs of 64 bit data types for MSVC.
2546
e6609d8f
DE
2547Tue Jul 22 10:35:37 1997 Doug Evans <dje@canuck.cygnus.com>
2548
2549 * sim-n-core.h (sim_core_write_unaligned_N): Add missing break
2550 to FORCED_ALIGNMENT case.
2551
84e8cd0f
AC
2552Thu Jun 5 13:48:37 1997 Andrew Cagney <cagney@b1.cygnus.com>
2553
2554 * callback.c (target_to_host_open): Handle hosts with O_BINARY.
2555
2556Thu Jun 5 08:47:10 1997 Jeffrey A Law (law@cygnus.com)
2557
2558 * Make-common.in (libsim.a): Fix typo.
2559
897f67b7
AC
2560Thu Jun 5 13:48:37 1997 Andrew Cagney <cagney@b1.cygnus.com>
2561
2562 * nrun.c (main): Verify the structure returned before using it.
2563
896eab00
AC
2564Wed Jun 4 11:44:06 1997 Andrew Cagney <cagney@b1.cygnus.com>
2565
2566 * sim-config.h (WITH_ENGINE): Enable the sim-engine module by
2567 default.
2568
2569 * sim-engine.c (sim_engine_install): New function. Install the
2570 engine init functions.
2571 (sim_engine_init): [Re]initialize the simulator engine.
2572
2573 * sim-module.c: Add sim_engine to list of modules that always
2574 install.
2575
56e7c849
AC
2576Tue Jun 3 04:52:04 1997 Andrew Cagney <cagney@b1.cygnus.com>
2577
2578 * sim-watch.c (schedule_watchpoint): Use sim_unschedule_watchpoint
2579 to remove the old watchpoint, not delete_watchpoint.
2580 (watch_option_handler): Action the correct watchpoint, not just
2581 cycles.
2582
2583Wed May 28 14:47:41 1997 Andrew Cagney <cagney@b1.cygnus.com>
2584
2585 * sim-n-core.h (sim_core_write_aligned_N): For 8byte reads, output
2586 both low and high word.
2587 (sim_core_write_aligned_N): Ditto.
2588
2589 * sim-trace.c (set_trace_options): Delete code explicitly setting
2590 core->trace.
2591
2592 * sim-options.c (sim_print_help): Call the list commands if not a
2593 standalone simulator.
2594 (sim_print_help): Advise that some options may not be applicable.
2595
2596 * sim-trace.c (set_trace_options): Assume core present.
2597
2598 * sim-events.c (sim_events_schedule_after_signal): Overflow signal
2599 buffer when full not almost full.
2600
2f2e6c5d
AC
2601Tue May 27 14:32:00 1997 Andrew Cagney <cagney@b1.cygnus.com>
2602
1a70e182
AC
2603 * sim-events.c (sim_events_process): Don't blat the event queue
2604 when processing watchpoints.
2605
2606 * sim-watch.h: Make arg unsigned long - stop sign extension.
2607
2608 * sim-events.c (sim_watch_valid): rewrite so debugable.
2609
2610 * sim-config.h (WITH_XOR_ENDIAN): Default to zero.
2611
2f2e6c5d
AC
2612 * sim-watch.c (schedule_watchpoint): Add is_within option so that
2613 inequality test is possible.
2614 (handle_watchpoint): Re-pass is_within arg.
2615 (watch_option_handler): When `!' prefix to pc-watchpoint arg pass
2616 0 to schedule_watchpoint's is_within arg.
2617 (sim_watchpoint_init): Re-pass is_within arg.
2618
2619 * sim-options.c (sim_print_help): Add is_command argument. Don't
2620 include -- prefix when called from the command line interpreter.
2621
2622 * sim-watch.c (schedule_watchpoint): Pass true is_within argument.
2623
2624 * sim-events.c (sim_events_watch_sim): Add is_within argument,
2625 zero indicates that the test should be reversed.
2626 (sim_events_watch_core): Ditto.
2627 (WATCH_CORE): Compare range against is_within.
2628 (WATCH_SIM): Ditto.
2629
2630Tue May 27 12:48:03 1997 Andrew Cagney <cagney@b2.cygnus.com>
2631
2632 * sim-events.c (WATCH_CORE): Pass NULL cpu argument to
2633 sim_core_read_buffer. Check nr-bytes transfered.
2634
2635 * sim-core.h (sim_core_common): Define a new struct that contains
2636 the common data. to sd and cpu structures.
2637 * sim-core.c (sim_core_attach): Update.
2638 (sim_core_init): Update. Remember to copy initialized data to each
2639 cpu.
2640 (sim_core_find_mapping): Ditto.
2641
2642 * sim-core.c (sim_core_read_buffer): Add cpu argument.
2643 (sim_core_write_buffer): Ditto.
2644
2645 * sim-n-core.h (sim_core_read_unaligned_N): When mis-aligned
2646 transfer use xor version of read buffer.
2647 (sim_core_write_unaligned_N): Ditto for write.
2648
2649 * sim-core.c (sim_core_xor_read_buffer): New function implement
2650 xor-endian data read breaking transfer up into xor-endian sized
2651 blocks.
2652 (sim_core_xor_write_buffer): Ditto for write.
2653 (reverse_n): Reverse order of arbitrary number of bytes in buffer
2654 - needed for xor-endian transfers.
2655
cd0d873d
AC
2656Fri May 23 14:24:31 1997 Andrew Cagney <cagney@b1.cygnus.com>
2657
2658 * sim-inline.h: Review description.
2659
2660 * sim-core.h, sim-core.c: Reduce number of functions being inlined
2661 to just those involved in data transfers and configuration.
2662
2663 * sim-xcat.h (XSTRING): New macro, map macro definition onto
2664 string.
2665 * sim-n-core.h (sim_core_read_aligned_N): Use.
2666 (sim_core_read_unaligned_N): Ditto.
2667 (sim_core_read_unaligned_N): Ditto..
2668 (sim_core_write_unaligned_N): Ditto.
2669
2670 * sim-core.h: Add xor endian bitmap to main structure. *
2671
2672 sim-n-core.h (sim_core_write_aligned_N): Add suport for xor
2673 endian.
2674 (sim_core_read_aligned_N): Ditto.
2675
2676 * sim-core.c (sim_core_set_xor_endian): New function.
2677 (sim_core_attach): Don't overwrite the per-cpu xor map when
2678 cloning the global core.
2679
8167e102
AC
2680Fri May 23 10:53:13 1997 Andrew Cagney <cagney@b1.cygnus.com>
2681
2682 * sim-engine.h: Update below so that it is using an enumerated
2683 type.
2684
6e61ecfc
GRK
2685Thu May 22 09:12:16 1997 Gavin Koch <gavin@cygnus.com>
2686
2687 * sim-engine.c (sim_engine_restart):
2688 * sim-resume.c (sim_resume): Change longjmp param/setjmp
2689 return value used for simulator restart from 0 to 2.
2690
50a2a691
AC
2691Wed May 21 08:47:30 1997 Andrew Cagney <cagney@b1.cygnus.com>
2692
2693 * cgen-scache.c (scache_option_handler): Add is_command arg.
2694
2695 * sim-model.c (model_option_handler): Add is_command argument.
2696
2697 * sim-profile.c (profile_option_handler): Add is_command arg.
2698
2699 * sim-events.c (sim_watch_valid): Use ub64, lb64 when 64bit value
2700 involved.
2701
2702 * sim-module.c (sim_module_add_init_fn): Call init fn in the same
2703 order that they are registered.
2704
2705 * sim-options.h (OPTION_HANDLER): Add argument to differentiate
2706 between option and command line processing.
2707
2708 * sim-options.c: Include stdlib.h, ctype.h.
2709
2710 * Make-common.in (sim-watch.o): Add rule.
2711 (sim_main_headers): Assume sim-assert.h included.
2712 (sim-*.o): Simplify make rule.
2713
2714 * sim-module.c: Add sim_watch_install to module list.
2715
2716Tue May 20 14:15:23 1997 Andrew Cagney <cagney@b1.cygnus.com>
2717
2718 * sim-base.h (STATE_LOADED_P): New predicate. Set once everything
2719 has been loaded.
2720
2721 * sim-trace.c (trace_install): Check magic. Include sim-assert.h.
2722 * sim-events.c (sim_events_install): Ditto.
2723 * sim-core.c (sim_core_install): Ditto.
2724 * sim-model.c (model_install): Ditto.
2725 * sim-options.c (standard_install): Ditto.
2726 * sim-profile.c (profile_install): Ditto.
2727 * sim-reason.c (sim_stop_reason): Ditto.
2728 * sim-run.c (sim_engine_run): Ditto.
2729 * sim-utils.c (sim_analyze_program): Ditto.
2730
2731 * sim-module.c (modules): Make profile_install and trace_install
2732 optional.
2733
2734 * sim-base.h (STATE_MEM_BASE): Define for flat memory systems.
2735
2736 * sim-options.c (standard_option_handler): Set the byte order.
2737
2738 * sim-events.c (sim_events_process): Allow multi tick processing.
2739 (sim_events_tickn): New function - multi cycle tick.
2740
2741 * sim-events.h (sim_events_tickn, sim_events_timewarp): Add
2742 prototypes. Under development.
2743 (sim_events): Replace processing with nr_ticks_to_process.
2744
2745Tue May 20 09:39:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
2746
2747 * nrun.c (main): Pass callbacks to sim_open instead of using
2748 sim_set_callbacks.
2749
2750 * run.c (main): Ditto.
2751
f03b093c
AC
2752Mon May 19 12:07:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
2753
fd76456b
AC
2754 * sim-events.c (sim_events_zalloc): Signal save memory allocator -
2755 stop tk interrupting malloc calls.
2756 (sim_events_zalloc): Converse.
2757
2758 * Make-common.in (sim_main_headers): Add sim-events.h.
2759
2760 * sim-events.c (sim_events_schedule_after_signal): Change return
2761 type to void - signal events are strictly internal.
2762 (sim_events_init): Allocate a finite buffer for signal events.
2763 (sim_events_schedule_after_signal): Enter signal events into the
2764 signal buffer.
2765
2766 * sim-engine.c (sim_engine_halt): Check SIM_DESC magic.
2767 (sim_engine_restart): Ditto.
2768 (sim_engine_abort): Ditto.
2769 * sim-stop.c (sim_stop): Ditto.
2770 (control_c_simulation): Ditto.
2771 * sim-resume.c (sim_resume): Ditto.
2772 (has_stepped): Ditto.
2773 * sim-abort.c (sim_engine_abort): Ditto.
2774
f03b093c
AC
2775 * sim-basics.h (transfer_type): New type.
2776
2777 * sim-core.c (sim_core_signal): New function. Print core signal
2778 information.
2779 (sim_core_find_mapping): Add transfer argument.
2780
2781 * sim-n-core.h (sim_core_{write,write}_unaligned_N): Call
2782 SIM_CORE_SIGNAL if a recoverable abort.
2783 * sim-core.c (sim_core_find_mapping): Ditto.
2784
2785Fri May 16 15:13:21 1997 Andrew Cagney <cagney@b1.cygnus.com>
2786
2787 * sim-core.c (sim_core_find_mapping): Replace calls to
2788 sim_io_error to more resiliant sim_engine_abort.
2789
2790 * sim-n-core.h (sim_core_read_unaligned_N): Ditto.
2791 (sim_core_write_unaligned_N): Ditto.
2792
2793Tue May 13 13:50:06 1997 Andrew Cagney <cagney@b1.cygnus.com>
2794
2795 * sim-module.c: Add sim_events_install to list.
2796
2797 * sim-events.c (sim_events_install, sim_events_uninstall): Clonse
2798 from sim_core_*.
2799 (sim_events_init): Now returns SIG_RC.
2800
2801 * sim-run.c: New file. Generic sim_engine_run.
2802 * sim-reason.c: New file. Generic sim_stop_reason.
2803 * sim-stop.c: New file. Generic sim_stop.
2804 * sim-resume.c: New file. Generic sim_resume.
2805
2806 * Make-common.in (sim-engine.o): Add rule.
2807 (sim-run.o, sim-reason.o, sim-stop.o, sim-resume.o): Ditto.
2808
2809 * sim-engine.h, sim-engine.c: New file. Provide generic
2810 implementation of sim_engine_halt, sim_engine_error. et.al.
2811
2812 * sim-base.h (sim_state_base): Add member halt.
2813 (sim-engine.h): Include.
2814
2815 * sim-events.h (sim_event_handler): Always pass SIM_DESC to event
2816 handlers.
2817 * sim-events.c (sim_events_poll): Update event handler.
2818
2819Tue May 13 09:57:49 1997 Andrew Cagney <cagney@b2.cygnus.com>
2820
2821 * sim-events.h, sim-events.c (sim_events_watch_clock): New
2822 function.
2823 (sim_events_watch_sim): New function.
2824 (sim_events_watch_core): New function.
2825 (sim_watch_valid): New function.
2826 (sim_events_preprocess): New function.
2827 (sim_events_process): Process the watchpoints as well as the timer
2828 queue.
2829 (sim_events_tick): Check WORK_PENDING instead of the hold queue.
2830 (sim_events_deschedule): Check all the queues when removing an
2831 event.
2832 (sim_events_init): Ditto for cleaning.
2833
2834Mon May 19 12:07:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
2835
2836 * sim-fpu.c (is_ufpu_number): Comment out - currently unused.
2837
11ab132f
AC
2838Mon May 19 11:23:03 1997 Andrew Cagney <cagney@b1.cygnus.com>
2839
2840 * callback.c (os_open): Type of arg flags is int.
2841
63aa80ff
MM
2842Fri May 16 22:26:43 1997 Michael Meissner <meissner@cygnus.com>
2843
2844 * sim-fpu.c (sim_fpu_is_{eq,ne,lt,le,gt,ge}): Compare Infinities
2845 just like normal numbers as per IEEE rules.
2846
248c1fb8
JL
2847Wed May 14 21:20:38 1997 Bob Manson <manson@charmed.cygnus.com>
2848
2849 * callback.c (os_close): Mark the descriptor as being
2850 available if the close succeeded.
2851 (os_open): Pass 0644 as the mode of the file being created.
2852
d24f06ee
AC
2853Thu May 15 10:58:52 1997 Andrew Cagney <cagney@b1.cygnus.com>
2854
07b4c0a6
AC
2855 * sim-fpu.c (pack_fpu, unpack_fpu): New functions - decode a
2856 float.
2857
2858 * sim-inline.c (SIM_INLINE_C): Rename from _SIM_INLINE_C_.
2859 * sim-lnline.h: Update.
2860
2861 * sim-fpu.h, sim-fpu.c (sim_fpu_[iu]{32,64}to): New int2fp
d24f06ee 2862 conversion functions.
07b4c0a6 2863 (sim_fpu_to{32,64}[iu]): New fp2int functions.
d24f06ee
AC
2864
2865 * sim-fpu.h, sim-fpu.c (sim_fpu_is_{lt,le,eq,ne,ge,gt}): New fp
2866 compare functions. Replacing.
2867 (sim_fpu_cmp): This. Delete.
2868
c445af5a
AC
2869Mon May 12 14:49:05 1997 Andrew Cagney <cagney@b1.cygnus.com>
2870
2871 * sim-core.c (sim_core_find_mapping): Call engine_error not
2872 sim_io_error when possible.
2873
2874Mon May 12 08:55:07 1997 Andrew Cagney <cagney@b2.cygnus.com>
2875
2876 * sim-endian.h (V1_H2): Add macro's to insert a word into a
2877 high/low double word.
2878
2879 * sim-trace.h: Remove definition of attribute - defined in
2880 sim_basics.h.
2881
e05e76e8
AC
2882Mon May 12 08:55:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
2883
2884 * sim-options.h (struct OPTION): Add doc_opt as the documenting
2885 name of the option - or family of options.
2886
2887 * sim-options.c (sim_args_command): Match command `a-b c' with
2888 option `--a-b-c' from option table.
2889
43c53e07
AC
2890Thu May 8 12:40:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
2891
2892 * sim-options.c (sim_print_help): For optional arguments, wrap
2893 them in [].
2894
2895 * sim-trace.c (set_trace_options): New function, handle optional
2896 argument and multiple assignment.
2897 (trace_option_handler): Update.
2898
2899 * sim-trace.c (trace_option_handler): Trace branch and not fpu
2900 when branch tracing selected.
2901
381f42ef
AC
2902Wed May 7 15:19:58 1997 Andrew Cagney <cagney@b1.cygnus.com>
2903
2904 * sim-trace.c (trace_one_insn): Make a va-args function.
2905
2906 * sim-trace.c (trace_vprintf): New function, va-arg version of
2907 trace_printf.
2908
ea4e4493
DE
2909Tue May 6 16:38:16 1997 Doug Evans <dje@canuck.cygnus.com>
2910
2911 * sim-trace.c (trace_uninstall): Don't close a file twice.
bd3274c6 2912 * sim-profile.c (profile_uninstall): Likewise.
ea4e4493 2913
a7724171
MM
2914Tue May 6 06:14:01 1997 Mike Meissner <meissner@cygnus.com>
2915
2916 * sim-trace.c (toplevel): Include bfd.h.
2917 (trace_options): Note that --trace-linenum also turns on
7b167b09 2918 --trace-insn. Add --trace-{branch,semantics}.
a7724171 2919 (trace_option_handler): If --trace-linenum, also turn on
7b167b09
MM
2920 --trace-insn. Add --trace-branch support. If --trace-semantics,
2921 turn on ALU, FPU, branch, and memory tracing.
a7724171
MM
2922 (trace_one_insn): New function to trace an instruction. Support
2923 --trace-linenum.
7b167b09 2924 (OPTION_TRACE_*): Use an enum, rather than lots of defines.
a7724171 2925
7b167b09
MM
2926 * sim-trace.h (TRACE_{SEMANTICS,BRANCH}_IDX): Add new macros.
2927 (MAX_TRACE_VALUES): Use 32, not 12 by default.
2928 (TRACE_branch): Add new mask.
2929 (TRACE_*_P): Define all possible trace_p macros.
a7724171
MM
2930 (trace_one_insn): Declare function.
2931
23b04e79
MM
2932Mon May 5 14:08:34 1997 Mike Meissner <meissner@cygnus.com>
2933
2934 * sim-trace.h (__attribute__): Define as nothing if not GNU C or
2935 GNU C doesn't support __attributes__.
2936 ({trace,debug}_printf): Add attribute's so -Wformat can check the
2937 format strings.
2938
7a418800
AC
2939Mon May 5 11:16:12 1997 Andrew Cagney <cagney@b1.cygnus.com>
2940
2941 * sim-config.h (FORCED_ALIGNMENT): New alignment option -
2942 addresses are masked forcing them to be correctly aligned.
2943 (WITH_ALIGNMENT): Make NONSTRICT_ALIGNMENT the default.
2944 * sim-config.c (config_alignment_to_a): Update.
2945
2946 * sim-core.h (sim_cpu_core): New data type contains cpu specific
2947 core data.
2948 * sim-base.h (CPU_CORE): Add cpu specific core data to cpu base
2949 type.
2950 * sim-core.c (sim_core_attach): Add CPU argument. Ready for
2951 processor specific core maps.
2952 (sim_core_map_attach): Copy the core map data to each of the
2953 processor specific core data structures.
2954 * sim-core.c (sim_core_find_mapping): Update.
2955
2956 * sim-n-core.h (sim_core_read_N, sim_core_write_N): Rename.
2957 (sim_core_write_aligned_N, sim_core_write_aligned_N): New names.
2958 (sim_core_write_unaligned_N, sim_core_write_unaligned_N): New
2959 alternatives that handle unaligned addresses.
2960 (sim_core_{read,write}_{,un}aligned_N): Drop SIM_DESC arg, replace
2961 with just CPU arg.
2962 * cgen-utils.c (sim_disassemble_insn): Update.
2963
3971886a
AC
2964Mon May 5 13:19:16 1997 Andrew Cagney <cagney@b1.cygnus.com>
2965
2966 * sim-trace.h (TRACE_FPU_IDX): Add Floating-point specific
2967 tracing.
2968
2969 * sim-fpu.h, sim-fpu.c: New files - prototype for generic target
2970 fpu support.
2971
2972 * sim-inline.h, sim-inline.c: Add support for SIM_FPU.
2973
1fe05280
AC
2974Fri May 2 17:59:42 1997 Andrew Cagney <cagney@b1.cygnus.com>
2975
2976 * sim-core.c (sim_core_map_to_str): New function ascii equivalent
2977 to map type.
2978
2979 * sim-n-core.h (sim_core_read_N, sim_core_write_N): Use in trace
2980 statement.
2981
2982Fri May 2 17:28:02 1997 Andrew Cagney <cagney@b2.cygnus.com>
2983
2984 * cgen-trace.c: Prepend additional trace_printf argument.
2985
2986 * cgen-utils.c (sim_disassemble_insn): Add additional core
2987 arguments.
2988
2989Fri May 2 11:40:23 1997 Andrew Cagney <cagney@b1.cygnus.com>
2990
2991 * nrun.c (main): Catch/report errorenous simulator states.
2992
2993 * sim-module.c: #include "libiberty.h" so that xmalloc is defined.
2994 * sim-trace.c: #include string.h/strings.h so that memset is
2995 defined.
2996 * sim-utils.c: Ditto.
2997 * sim-profile.c: Ditto. And stdlib.h.
2998 (print_bar): Only define when used by instruction or memory profiler.
2999
3000 * sim-options.c (standard_option_handler): Make ul more local.
3001
3002 * sim-load.c (sim_load_file): Make the name constant.
3003 (sim_load_file): Passify gcc.
3004
3005 * sim-utils.h: New file, pre-declare utilites in corresponding .c
3006 file.
3007 * sim-utils.c, sim-load.c: Include sim-utils.h.
3008
3009 * sim-base.h (sim_cpu): Pre define here so available to all.
3010
3011 * sim-core.h (DECLARE_SIM_CORE_WRITE_N, DECLARE_SIM_CORE_READ_N):
3012 Restore the sim_cpu and instruction_address arguments so that full
3013 information is available to the abort function.
3014 * sim-core.c (sim_core_find_mapping, sim_core_write_buffer): Ditto.
3015 * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
3016
3017 * sim-trace.h, sim-trace.c (trace_option_handler): Add interim
3018 tracing support for sim-events and sim-core.
3019 (trace_option_handler): Convert #if to if where possible so always
3020 compiled/checked by C compiler.
3021 * sim-n-core.h (sim_core_write_N, sim_core_read_N): Update.
3022
3023 * sim-base.h: Adjust comment documenting how to define the cpu
3024 structure.
3025 (sim_state_base): Add sim_core and sim_events to simulator base
3026 object.
3027
3028 * sim-trace.h, sim-trace.c (trace_printf): Add SIM_DESC argument.
3029 * sim-core.c (sim_core_init, sim_core_attach,
3030 sim_core_find_mapping): Update.
3031 * sim-events.c (ETRACE, sim_events_init, sim_events_time,
3032 update_time_from_event, insert_sim_event,
3033 sim_events_schedule_after_signal, sim_events_deschedule,
3034 sim_events_tick): Ditto.
3035
3036 * sim-basics.h (sim-module.h, sim-trace.h, sim-profile.h,
3037 sim-model.h): Move #includes from here.
3038 * sim-base.h: To here.
3039 (sim-core.h, sim-events.h, sim-io.h): Include also
3040
3041Wed Apr 30 15:37:54 1997 Andrew Cagney <cagney@b1.cygnus.com>
3042
3043 * callback.c (default_callback): Missing initialisers.
3044
c967f187
DE
3045Thu May 1 10:40:47 1997 Doug Evans <dje@canuck.cygnus.com>
3046
2317a499
DE
3047 * sim-utils.c (sim_add_commas): New function.
3048 * sim-basics.h (sim_add_commas): Add prototype.
3049 * cgen-scache.c (scache_print_profile): Print commas in numbers.
3050 * sim-profile.c (COMMAS): New macro.
3051 (print_*): Use it to print commas in numbers.
3052
260b2c47
DE
3053 * configure: Regenerated.
3054
3055 * cgen-sim.h (sim_signal_type): Add SIM_SIGINT.
3056 (cgen_state): New member run_fast_p.
3057 (cgen_init): Add prototype.
3058 (sim_disassemble_insn): New arg `cpu'.
3059 * cgen-trace.c (trace_insn): Update call to sim_disassemble_insn.
3060 * cgen-utils.c (cgen_init): New function.
3061 (sim_disassemble_insn): New arg `cpu'. Rewrite fetching of insn.
3062 * genmloop.sh: Call engine_halt if loop exits.
3063
c967f187
DE
3064 * Makefile.in (sim-options_h): Define.
3065 (sim-{module,options,trace,profile,utils}.o): Clean up dependencies.
3066 (sim-model.o): Add new rule.
3067 (cgen-{scache,trace,utils}.o): Add new rules.
3068 * aclocal.m4 (SIM_AC_OPTION_{SCACHE,DEFAULT_MODEL}): Add.
3069 * cgen-scache.c (scache_print_profile): Change `sd' arg to `cpu'.
3070 Indent output by 2 spaces.
3071 * cgen-scache.h (scache_print_profile): Update.
3072 * cgen-trace.c (trace_insn_fini): Indent output by 2 spaces.
3073 Use trace_printf, not fprintf.
3074 (trace_extract): Use trace_printf, not cgen_trace_printf.
3075 * genmloop.sh (!FAST case): Increment `insn_count'.
3076 * sim-base.h (sim_state_base): Only include scache_size if WITH_SCACHE.
3077 (sim_cpu_base): Rename member `sd' to `state' to be consistent with
3078 access macro's name.
3079 * sim-core.c (sim_core_init): Use EXTERN_SIM_CORE to define it.
3080 Change return type to SIM_RC.
3081 (sim_core_{install,uninstall}): New functions.
3082 * sim-core.h (sim_core_{install,uninstall}): Declare.
3083 (sim_core_init): Use EXTERN_SIM_CORE to define it.
3084 Change return type to SIM_RC.
3085 * sim-model.h (models,machs,model_install): Declare.
3086 * sim-module.c (modules): Add scache_install, model_install.
3087 (sim_post_argv_init): Set cpu->state backlinks.
3088 * sim-options.c (standard_options): Delete --simcache-size,--max-insns.
3089 (standard_option_handler): Likewise.
3090 * sim-profile.c (PROFILE_{HISTOGRAM,LABEL}_WIDTH): Move to
3091 sim-profile.h.
3092 (*): Assume ANSI C.
3093 (profile_options): Delete --profile-simcache.
3094 (profile_option_handler): Likewise.
3095 (profile_print_insn): Change `sd' arg to `cpu'. Indent output 2
3096 spaces.
3097 (profile_print_{memory,model}): Likewise.
3098 (profile_print_simcache): Delete.
3099 (profile_print_speed): New function.
3100 (profile_print): Rewrite.
3101 * sim-profile.h (PROFILE_scache): Renamed from PROFILE_simcache.
3102 (WITH_PROFILE_SCACHE_P): Renamed from WITH_PROFILE_SIMCACHE_P.
3103 (PROFILE_DATA): Delete members simcache_{hits,misses}.
3104 (PROFILE_COUNT_SIMCACHE_{HIT,MISS}): Delete.
3105 (PROFILE_{CALLBACK,CPU_CALLBACK}): New types.
3106 (profile_print): Update prototype.
3107
717dbb29
DE
3108Wed Apr 30 11:34:14 1997 Doug Evans <dje@canuck.cygnus.com>
3109
6475b234 3110 * cgen-scache.[ch], cgen-sim.h: New files.
b9c8cd10
DE
3111 * cgen-trace.[ch], cgen-types.h, cgen-utils.c, genmloop.sh: New files.
3112 * sim-model.c: New file.
3113
717dbb29
DE
3114 * Make-common.in (clean targets): Undo patch of Apr. 22.
3115
3116Fri Apr 25 15:28:32 1997 Mike Meissner <meissner@cygnus.com>
3117
3118 * sim-n-bits.h (signed): If we have a standard compiler, undef
3119 signed, so that signedN is defined correctly.
3120
b320601b
DE
3121Thu Apr 24 00:00:07 1997 Doug Evans <dje@canuck.cygnus.com>
3122
3123 * sim-module.h, sim-model.h, sim-profile.h: New files.
3124 * sim-module.c, sim-profile.c: New files.
3125 * Make-common.in (SIM_PROFILE): Define
3126 (CONFIG_CFLAGS): Add $(SIM_PROFILE).
3127 (sim_main_headers): Add sim-module.h, sim-model.h, sim-profile.h.
3128 (sim_module.o,sim-profile.o): Add rules for.
3129 * aclocal.m4 (--enable-sim-trace): Allow symbolic arguments.
3130 (--enable-sim-profile): Add.
3131 * configure: Regenerated.
3132 * sim-base.h (sim_state_base): New members init_list, uninstall_list,
3133 model. Move trace and profile support to sim-{trace,profile}.h.
3134 New members trace_data, profile_data.
3135 * sim-basics.h: #include sim-module.h, sim-model.h, sim-profile.h.
3136 * sim-config.h: Provide default definition of WITH_PROFILE.
3137 (WITH_TRACE): Change default to -1.
3138 (MAX_NR_PROCESSORS): Always define.
3139 * sim-options.c: Move trace and profile support to
3140 sim-{trace,profile}.h.
3141 (sim_pre_argv_init): Moved to sim-model.c.
3142 (standard_install): New function.
3143 * sim-options.h (sim_pre_argv_init): Move decl to sim-model.c.
3144 (standard_install): Declare.
3145 * sim-trace.c: Tracing option handling moved here from sim-options.c.
3146 (trace_install, trace_uninstall): New functions.
3147 (trace_printf): Update reference to TRACE_FILE.
3148 * sim-trace.h (TRACE_FOO_IDX): Moved here from sim-base.h.
3149 (TRACE_foo): Bit masks for symbolic arguments to --enable-sim-trace.
3150 (WITH_TRACE_FOO_P): Define.
3151 (trace_install): Declare.
3152 (TRACE_DATA): New struct.
3153
ef751fb0
DE
3154Wed Apr 23 17:23:15 1997 Doug Evans <dje@canuck.cygnus.com>
3155
3156 * run.c: Undo last exec_bfd patch.
3157 (main): Only pass -E ifdef SIM_HAVE_BIENDIAN.
3158
e3eba3fd
MM
3159Wed Apr 23 17:54:27 1997 Mike Meissner <meissner@cygnus.com>
3160
3161 * run.c (exec_bfd): Add back in.
3162 (main): Set exec_bfd.
3163
2c27ef78
DE
3164Tue Apr 22 14:43:46 1997 Doug Evans <dje@canuck.cygnus.com>
3165
3166 * sim-load.c (sim_load_file): #include <stdio.h> for NULL.
3167
15c16493
AC
3168Wed Apr 23 02:55:54 1997 Andrew Cagney <cagney@b1.cygnus.com>
3169
3170 * sim-events.c (insert_sim_event): Call sim_io_error instead of
3171 less well defined engine_error.
3172 * sim-core.c: Ditto.
3173
0f399b0c
SG
3174Tue Apr 22 08:48:16 1997 Stu Grossman (grossman@critters.cygnus.com)
3175
3176 * Make-common.in: Change clean targets to use :: so that other
3177 Makefiles can have their own clean targets.
3178 * sim-load.c (xprintf eprintf): Use ANSI_PROTOTYPES instead of
3179 __STDC__ to control use of stdarg vs. varargs syntax. Some
3180 systems can't use __STDC__, but require stdarg.
3181
4a6163db
DE
3182Fri Apr 18 11:14:43 1997 Doug Evans <dje@canuck.cygnus.com>
3183
e65bd1d8
DE
3184 * sim-options.c (standard_options): Add --endian.
3185 (standard_option_handler): Likewise.
3186
4a6163db
DE
3187 * nrun.c: #include <signal.h>.
3188 (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
3189 handler that calls sim_stop ().
3190
8517f62b
AC
3191Fri Apr 18 13:11:36 1997 Andrew Cagney <cagney@b1.cygnus.com>
3192
3193 * run.c (main, cntrl_c): Wrap calls to sim_resume in a SIGINT
3194 handler that calls sim_stop (). Simulators may still be
3195 establishing their own handler.
3196
3197 * sim-events.c (sim_events_poll): Rename from
3198 sim_events_at_large_int. Poll IO.
3199
3200 * sim-io.c (sim_io_poll_quit): New function - pass on a polling
3201 request.
3202
3203 * callback.c (os_poll_quit): New function poll for quit signal
3204 where needed.
3205 (default_callback): Include magic number.
3206
0f2811d1
DE
3207Thu Apr 17 02:25:11 1997 Doug Evans <dje@canuck.cygnus.com>
3208
63ddb6bd
DE
3209 * aclocal.m4: Check for headers time.h, sys/time.h, sys/resource.h.
3210 Check for functions getrusage, time.
3211 * sim-basics.h (SIM_ELAPSED_TIME): New typedef.
3212 (sim_elapsed_time_get, sim_elapsed_time_since): Add prototypes.
3213 * sim-utils.c: #include time.h, sys/time.h, sys/resource.h if able.
3214 (sim_elapsed_time_get, sim_elapsed_time_since): New functions.
3215
ba65b2f4
DE
3216 * sim-utils.c (sim_copy_argv, sim_analyze_program): New functions.
3217
4ede3a83 3218 * sim-options.c, sim-options.h: New files.
4b364b00 3219 * sim-config.h (WITH_DEBUG): Provide default value of zero.
e9b2f579 3220 * Make-common.in (nrun.o): Add rules for.
c95d08a8 3221 * nrun.c: New file.
4ede3a83 3222
f7d2f538
DE
3223 * run.c (main): Check return value of sim_open.
3224
e9b2f579 3225 * Make-common.in (sim-options.o, sim-load.o, sim-trace.o): Add rules.
0f2811d1
DE
3226 (sim_main_headers): Add sim-trace.h.
3227 * run.c (exec_bfd, target_byte_order): Delete.
3228 (main): Pass -E <endian> to sim_open. Delete code to load sections,
3229 call sim_load instead. Check return code of sim_create_inferior.
3230 * sim-base.h (CURRENT_STATE): Define.
3231 (sim_state_base): Make typedef. New members options, prog_argv,
3232 prog_bfd, text_{section,start,end}, start_addr, simcache_size,
3233 mem_size, memory [+ corresponding access macros].
3234 (sim_cpu_base): New typedef.
3235 * sim-trace.h: New file.
e9b2f579 3236 * sim-trace.c: New file.
0f2811d1 3237 * sim-basics.h: #include it.
35c384f6 3238 * sim-load.c: New file.
0f2811d1 3239
6808fd61
ILT
3240Tue Apr 15 15:10:13 1997 Ian Lance Taylor <ian@cygnus.com>
3241
3242 * Make-common.in (INSTALL): Set to @INSTALL@.
3243 (INSTALL_XFORM, INSTALL_XFORM1): Remove.
3244 (install-common): Depend upon installdirs. Use
3245 $(program_transform_name) directly, rather than using
3246 $(INSTALL_XFORM).
3247 (installdirs): New target.
3248 * Makefile.in (INSTALL): Set to @INSTALL@.
3249 (INSTALL_XFORM, INSTALL_XFORM1): Remove.
3250 (install-man): Depend upon installdirs. Use
3251 $(program_transform_name) directly, rather than using
3252 $(INSTALL_XFORM).
3253 (installdirs): New target.
3254
7ec396d2
AC
3255Tue Apr 15 15:08:12 1997 Andrew Cagney <cagney@b1.cygnus.com>
3256
3257 * sim-assert.h (SIM_ASSERT, ASSERT): Allow these macros to
3258 be overriden.
3259
3260Wed Apr 9 16:06:44 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3261
3262 * sim-basics.h: Only bring in config.h and tconfig.h if
3263 HAVE_CONFIG_H.
3264
3265Mon Apr 7 11:39:45 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3266
3267 * sim-config.h (WITH_TARGET_WORD_MSB): New Macro. Define the bit
3268 numbering convention of the target.
3269 * sim-config.c (print_sim_config): Print WITH_TARGET_WORD_BITSIZE
3270 and WITH_TARGET_WORD_MSB.
3271 (sim_config): When possible, check for consistency with bitsize
3272 and msb.
3273
3274 * sim-bits.h: Allow MSB to be other than zero.
3275 * sim-bits.c: Ditto.
3276 * sim-n-bits.h: Ditto.
3277
3278 * sim-bits.h (MSMASK*): New macros - converce to LSMASK*.
3279 * sim-n-bits.h (MSMASKEDn): Ditto.
3280
3281Mon Apr 14 16:29:21 1997 Ian Lance Taylor <ian@cygnus.com>
3282
3283 * Makefile.in (INSTALL): Change install.sh to install-sh.
3284
25a9c90b
DE
3285Mon Apr 7 10:46:38 1997 Doug Evans <dje@canuck.cygnus.com>
3286
3287 * sim-base.h (sim_state_base): Move `magic' to end of struct.
3288
b4d88827
AC
3289Mon Apr 7 15:53:21 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3290
3291 * run.c (main): Check that a program to run was specified.
3292
08db4a65
AC
3293Mon Apr 7 15:45:02 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3294
3295 * aclocal.m4 (AC_TYPE_SIGNAL): Add check.
3296
3297 * configure: Regenerated to track ../common/aclocal.m4 changes.
3298 * config.in: Ditto.
3299
fbda74b1
DE
3300Wed Apr 2 15:06:28 1997 Doug Evans <dje@canuck.cygnus.com>
3301
21bfad86
DE
3302 * sim-endian.h: Move host {LITTLE,BIG}_ENDIAN support from here,
3303 * sim-config.h: To here.
3304
00d74d3e
DE
3305 * Make-common.in (SIM_EXTRA_DEPS): New config var.
3306 (sim_main_headers): Define.
3307 (sim-*.o): Depend on $(SIM_EXTRA_DEPS).
3308 (BUILT_SRC_FROM_COMMON): Move here from ../d30v/Makefile.in.
3309 (clean): Use it.
3310 (sim-utils.o): Add rule for.
3311 * sim-utils.o: New file.
3312 * sim-basics.h: #include sim-base.h.
3313 (zalloc): Make argument unsigned long.
3314 * sim-base.h: New file.
3315 * sim-inline.h (SIM_IO support): Delete.
3316 * sim-io.h: Delete inline support.
3317 * sim-io.c: Likewise. sim-state.h renamed to sim-main.h.
3318 * sim-config.c: sim-state.h renamed to sim-main.h.
3319 * sim-core.c: Likewise.
3320 * sim-events.c: Likewise.
3321
bcd1475a
DE
3322 * run.c (main): Pass SIM_OPEN_STANDALONE to sim_open.
3323
fbda74b1
DE
3324 * aclocal.m4: Check for stdlib.h, string.h, strings.h, unistd.h.
3325 (sim-debug): Allow arguments. Define WITH_DEBUG in addition to
3326 -DDEBUG.
3327 * configure: Regenerated to track ../common/aclocal.m4 changes.
3328
a35e91c3
AC
3329Wed Apr 2 14:34:19 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3330
3331 * configure: Regenerated to track ../common/aclocal.m4 changes.
3332
3333Wed Apr 2 11:08:11 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3334
3335 * sim-config.h (WITH_ALIGNMENT, WITH_FLOATING_POINT,
3336 WITH_XOR_ENDIAN, WITH_SMP, WITH_RESERVED_BITS): Assume that these
3337 are defined by the configure.
3338
3339 * aclocal.m4 (sim-stdio): Add option stdio from ../ppc configure.
3340
3341 * aclocal.m4 (floating-point, xor-endian, alignment, smp,
3342 reserved-bits): Always define.
3343
3344 * sim-config.h, sim-config.c (sim_config): New function - and new
3345 file - co-ordinate the setting/checking of the common simulator
3346 configuration options.
3347
3348 * Make-common.in (sim-config.o): Add rule.
3349
3350Fri Mar 28 15:32:00 1997 Mike Meissner <meissner@cygnus.com>
3351
3352 * callback.c (os_{,e}vprintf_filtered): Change stdarg type to
3353 va_list from void *, since va_list might not be a pointer type.
3354
3355Mon Mar 24 15:27:12 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3356
3357 * sim-n-endian.h (offset_N): Correct assertion - word and sub word
3358 in wrong order.
3359 (offset_N): Correct computation of LE offset.
3360
3361 * sim-io.c (sim_io_error): Include a new line when reporting
3362 errors.
3363
3364 * sim-assert.h (SIM_FILTER_PATH): Out by one when locating last
3365 `/'.
3366
aa7cec3f
JL
3367Thu Mar 20 22:31:06 1997 Jeffrey A Law (law@cygnus.com)
3368
3369 * run.c: Include alloca-conf.h.
7c058c9e
JL
3370
3371 * callback.c (os_evprintf_filtered): Fix typo.
3372
fa21d299
AC
3373Fri Mar 21 13:36:20 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3374
3375 * run.c (string.h, strings.h, stdlib.h): Include.
3376
3377 * sim-events.c (sim_events_tick): Recent cleanup failed to return
3378 0 when nothing pending.
3379
3380 * run.c (sim_size, sim_trace): Plicate GCC - these two functions
3381 will soon be going away.
3382 (getopt): Plicate GCC.
3383
3384 * sim-endian.c (sim-io.h): Plicate GCC.
3385 * sim-bits.c (sim-io.h): Ditto.
3386 * sim-n-bits.h (ROTn): Ditto.
3387
3388 * sim-io.c (sim_io_error): Correct check for NULL.
3389
3390 * sim-assert.h (SIM_FILTER_PATH): Separate out the code filtering
3391 the __FILE__.
3392 * sim-events.c: Use SIM_FILTER_PATH to filter out the filename
3393 path.
3394
3395Wed Mar 19 01:12:06 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3396
3397 * aclocal.m4 (SIM_AC_OPTION_*: Move so that they are outside of
3398 SIM_AC_COMMON - SIM_AC_COMMON was gobling arguments.
3399
4a5fb09d
AC
3400Tue Mar 18 20:48:12 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3401
3402 * sim-alu.h: Include sim-xcat.h.
3403
d11d59ac
AC
3404Tue Mar 18 13:58:18 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3405
3406 * Make-common.in (sim-bits.c, sim-core.c, sim-endian.c,
3407 sim-events.c, sim-inline.c, sim-io.c): Define rules for building
3408 these.
3409
3410 * sim-events.c (sim_events_at_large_int): New function. Just
3411 schedules an event every large-int ticks.
3412 (sim_events_init): Call.
3413 (sim_events_tick, sim_events_process): Move async handing to
3414 sim_events_process. Move timer decrement so that it occures after
3415 events have been processed.
3416
3417 * sim-basics.h (struct _engine): Remove declaration.
3418
3419 * sim-events.h, sim-events.c: Rename type to sim_events. Prefix
3420 everything with same. Rename global struct to SIM_DESC.
3421 * sim-core.h, sim-core.c, sim-n-core.c: Ditto for sim_core.
3422 * sim-io.h, sim-io.c: Ditto.
3423
3424 * sim-assert.h: New file. Optional assertion checking macros.
3425 * sim-io.c (sim_io_error): Make just this function tolerant to
3426 null pointers.
3427
3428 * sim-xcat.h: New file. Define concatenate macros.
3429 * sim-basics.h (XCONCAT*): Move to sim-xcat.h.
3430 * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Explicitly include
3431 concat macros.
3432
3433
752517cc
AC
3434Tue Mar 18 12:44:55 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3435
3436 * sim-bits.h (LSMASK): New macro. Create mask of LS bits.
3437
86eb1e29
AC
3438Mon Mar 17 18:10:05 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3439
3440 * sim-inline.h: Add definitions for sim-types.
3441 (ALL_BY_MODULE): New macro, encapsulate full inlining by the
3442 module.
3443
231de1b8
AC
3444Mon Mar 17 15:38:27 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3445
3446 * sim-events.h: Remove defunct reference to callback struct.
3447
a77aa7ec
AC
3448Mon Mar 17 15:10:07 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3449
3450 * configure: Re-generate.
3451
3452Mon Mar 17 15:04:47 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3453
3454 * Make-common.in (CSEARCH): Do not include the gdb directory in
3455 the search path.
3456
3457Mon Mar 17 13:16:26 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3458
3459 * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
3460 SIM_WARNING): Drop, requiring the simulator specific Makefile.in
3461 to explicitly incorporate these.
3462
3463 * aclocal.m4 (--enable-sim-alignment); New option. Strongly
3464 specify the alignment restrictions of the target architecture -
3465 without this option all alignment restrictions are accomodated.
3466 (--enable-sim-assert): New option. Conditionally compile in
3467 assertion statements.
3468 (--enable-sim-float): New option. Strongly specify the target's
3469 floating point support.
3470 (--enable-sim-hardware): New option. Specify the hardware devices
3471 included in the simulation.
3472 (--enable-sim-packages): New option. Specify the hardware
3473 packages included in the simulation.
3474 (--enable-sim-regparm): New option. Specify that parameters be
3475 passed in registers instead of on the stack.
3476 (--enable-sim-reserved-bits): New option. Specify that reserved
3477 bits within an instruction are are correctly set.
3478 (--enable-sim-smp): New option. Specify the level of SMP support
3479 to be included in the simulator.
3480 (--enable-sim-stdcall): New option. Specify an alternative
3481 function call convention.
3482 (--enable-sim-xor-endian): New option. Configure xor-endian
3483 support used by some targets to implement bi-endian support.
3484
f2de7dfd
AC
3485Fri Mar 14 19:51:21 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3486
3487 * aclocal.m4 (--enable-sim-hostendian): New option. Allow the
3488 host endianness to be overridden.
3489 (--enable-sim-endian): Allow the target platform's byte order
3490 to be overridden.
3491 (--enable-sim-inline): Control the inlining of common components.
3492 (--enable-sim-bswap): For compatibility, also define WITH_BSWAP.
3493 (--enable-sim-warnings): Enable additional GCC compiler checks.
3494 * Make-common.in (SIM_ENDIAN, SIM_HOSTENDIAN, SIM_INLINE,
3495 SIM_WARNINGS): Add.
3496
3497 * sim-n-core.h, sim-n-bits.h, sim-n-endian.h: Rename from
3498 sim-*-n.h so that the names are uniq on dos machines
3499 * sim-core.c, sim-bits.c, sim-endian.c: Update.
3500
499aa792
DE
3501Thu Mar 13 12:32:42 1997 Doug Evans <dje@canuck.cygnus.com>
3502
3503 * run.c: #include "libiberty.h".
3504 (main): New locals sd,no_args,sim_argv.
3505 Run buildargv on -a option. Pass argv to sim_open, argv[0]
3506 is program name. Update call to sim_set_callbacks.
3507 Record result of sim_open, pass to other sim_foo routines.
3508
fd435e9f
MM
3509Thu Mar 13 10:24:05 1997 Michael Meissner <meissner@cygnus.com>
3510
3511 * callback.c (os_printf_filtered): Do not call exit(1) or print a
3512 final newline.
3513
3514Thu Mar 6 15:50:28 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3515
3516 * callback.c: Add os_flush_stdout and vprintf_filtered callbacks.
3517 Route stdout through buffered IO.
3518
3519 * callback.c: Add os_flush_stderr, os_write_stderr,
3520 os_evprintf_filtered functions to route error output through
3521 stderr.
3522
3523 * sim-io.h, sim-io.c (sim_io_flush_stderr, sim_io_flush_stdout):
3524 Correct return type - should be void.
3525
3526Fri Mar 7 20:14:37 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3527
3528 * sim-basics.h: Clean up. Many macro's moved to sim-inline.h.
3529
3530 * sim-config.h: Ditto. For some options - eg WITH_DEVICES - do
3531 not provide a default value as undefined indicates disable code.
3532
3533Thu Mar 6 15:50:28 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3534
3535 * sim-core.h, sim-core-n.h, sim-core.c: Borrow code from ppc
3536 directory.
3537 * sim-events.h, sim-events.c: Ditto.
3538 * sim-io.h, sim-io.c: Ditto.
3539
b3e426bc
AC
3540Tue Mar 4 09:35:56 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3541
3542 * sim-alu.h (ALU_SUB_CA, ALU*_SUB_CA): New alu operation.
3543
3544 * sim-bits.h, sim-bits-n.h, sim-bits.c (LSMASKED*): New macro's
3545 extract the tail or least signifiant bits from an integer of the
3546 specified size.
3547
3548 * sim-bits.h, sim-bits.c: Clean up conditionally compiled #if
3549 WITH_TARGET_BITSIZE so that the compilation will fail when an
3550 unsupported bitsize value is defined.
3551
3552 (INSERTED*): Convert to functions.
3553 (EXTRACTED*): Ditto.
3554
3555 (SIGN_EXTEND, SEXT): Change to more terse name.
3556
17bbcaad
AC
3557Tue Mar 4 09:35:56 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3558
3559 * sim-inline.h: Allow explicit control over which .c files will be
3560 included by their header.
3561
3562 * sim-inline.h: Allow explicit control over which .c files use the
3563 alternative - REGPARM - parameter passing mechanism.
3564
3565 * sim-inline.h, sim-inline.c: Don't attempt to include any of
3566 icache.c, idecode.c, semantics.c or support.c. Those names are
3567 not generally applicable.
3568
b3e426bc
AC
3569Thu Feb 27 10:17:23 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3570
3571 * sim-bits.c, sim-bits-n.h (new): Split sim-bits.c into two parts
3572 in a fashion similar to sim-endian-n.
3573
3574 * sim-endian.h: (H_word, L_word, AL_*, VL_*): Extend to include
3575 both value and address macro's.
3576
3577Tue Feb 25 18:51:57 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
3578
3579 * sim-alu.h (ALU16_BEGIN, ALU16_SET, ...): Fill in.
3580
3581 * sim-endian.h (L_word, H_word): Replace MS2W_4, LS2W_4 with more
3582 generic L_word, H_word macro's.
3583
17bbcaad
AC
3584Thu Feb 20 18:36:55 1997 Andrew Cagney <cagney@critters.cygnus.com>
3585
3586 * sim-basics.h: Borrow code from ppc directory.
3587 * sim-bits.c: Ditto.
3588 * sim-bits.h: Ditto.
3589 * sim-config.h: Ditto.
3590 * sim-endian-n.h: Ditto.
3591 * sim-endian.c: Ditto.
3592 * sim-endian.h: Ditto.
3593 * sim-inline.c: Ditto.
3594 * sim-inline.h: Ditto.
3595 * sim-types.h: Ditto.
3596
3597Wed Feb 19 12:40:50 1997 Andrew Cagney <cagney@critters.cygnus.com>
3598
3599 * sim-alu.h (ALU_SET16, ALU_SET32, ALU_SET64, etc): Make available
3600 all the ALU size alternatives and then auto-configure a default.
3601
3602 * sim-alu.h: Copy ppc/idecode_expression.h.
3603
3604Mon Feb 17 10:44:18 1997 Andrew Cagney <cagney@critters.cygnus.com>
3605
3606 * bits.h, bits.c (SIGN_EXTEND32, SIGN_EXTEND64): New functions,
3607 sign extend a bit within a value.
3608
3609 * sim-endian.h, sim-endian-n.h (offset_N): New functions - return
3610 a pointer into the middle of a host word.
3611 * sim-endian.h (MS2W_4, LS2W_4): Use this function.
3612
3613Tue Feb 11 13:46:49 1997 Michael Meissner <meissner@tiktok.cygnus.com>
3614
3615 * callback.c: If HAVE_CONFIG_H is defined, include config.h from
3616 autoconf. If HAVE_UNISTD_H is defined, include unistd.h to get
3617 appropriate definitions of read, write, etc. Add prototype for
3618 system.
3619
1cc9ed29
DE
3620Tue Feb 4 13:24:44 1997 Doug Evans <dje@canuck.cygnus.com>
3621
3622 * Makefile.in (libcommon.a): Delete.
3623 (callback.o,targ-map.o): Delete, moved to Make-common.in.
3624 (gentmap,targ-vals.h,targ-map.c): Likewise.
3625 (run-autoconf): Delete.
3626 * aclocal.m4 (SIM_AC_OUTPUT): Redo creation of Makefile.
3627 (common makefile fragment): Moved back into ...
3628 * Make-common.in: Resurrect.
3629 * configure.in (AC_LINK_FILES): Delete, unnecessary now.
3630 * configure: Regenerated.
3631
8cd89e77
DE
3632Fri Jan 31 07:16:49 1997 Doug Evans <dje@canuck.cygnus.com>
3633
3634 * aclocal.m4 (SIM_AC_COMMON): Move COMMON_MAKEFILE_FRAG from here.
3635 (SIM_AC_OUTPUT): To here.
3636
76e2c9ae
SG
3637Fri Jan 24 10:37:17 1997 Stu Grossman (grossman@critters.cygnus.com)
3638
3639 * aclocal.m4 (COMMON_MAKEFILE_FRAG): Quote a couple of $'s in
3640 comments and single quotes. Fixes a problem found on hpux.
3641
80b7b3a5
SG
3642Thu Jan 23 13:35:03 1997 Stu Grossman (grossman@critters.cygnus.com)
3643
e1dfb8c5 3644 * aclocal.m4: Remove Make-common.in from dependencies.
42653e99 3645 * (distclean): Remove targ-vals.def.
e1dfb8c5 3646
80b7b3a5
SG
3647 * aclocal.m4 (SIM_AC_COMMON): Move contents of Make-common.in
3648 into here. Makes insertion into makefiles easier. Also, change
3649 the way that callback.o, gentmap, targ-vals.h, targ-map.c,
3650 targ-map.o, and run are built. They are now built in the
3651 individual simulator directories, taking sources from ../common as
3652 necessary. This replaces the merging of libcommon.a into
3653 linsim.a, which was problematic for the WinGDB build process.
3654 * run.c: Include config.h from . instead of ../common.
3655 * Make-common.in: Remove. It's no longer necessary.
3656
3657Mon Dec 16 15:02:33 1996 Ian Lance Taylor <ian@cygnus.com>
3658
3659 * Make-common.in (ALL_CLAGS): Put CFLAGS at the end.
3660 (.c.o): Put $(ALL_CFLAGS) before the file being compiled.
3661
3662Wed Dec 11 11:30:58 1996 Jim Wilson <wilson@cygnus.com>
3663
3664 * run.c (main): Set target_byte_order before call to sim_open.
3665
966f47b4
DE
3666Sun Dec 8 18:22:06 1996 Doug Evans <dje@canuck.cygnus.com>
3667
3668 * callback.c: #include <stdlib.h>
3669 (os_error): New function.
3670 (default_callback): Add os_error.
3671
3672Mon Nov 25 19:44:35 1996 Doug Evans <dje@canuck.cygnus.com>
3673
3674 * Make-common.in (Makefile): Set CONFIG_HEADERS="".
3675 * aclocal.m4: Mark the fact that --enable-sim-bswap isn't host
3676 specific.
3677 (SIM_AC_OUTPUT): Don't build Makefile if CONFIG_FILES="".
3678
3679Wed Nov 20 01:11:04 1996 Doug Evans <dje@canuck.cygnus.com>
3680
3681 * run.c: #include ../common/config.h, tconfig.h.
3682 (myname): New static global.
3683 (main): Recognize new options -a, -c. Also recognize -h if h8/300.
3684 Only process -c ifdef SIM_HAVE_SIMCACHE.
3685 Only process -p/-s ifdef SIM_HAVE_PROFILE.
3686 Parse program name from argv[0] and use in error messages.
3687 Pass sim_args to sim_open. Pass prog_args to sim_create_inferior.
3688 Add support for incomplete h8/300 termination indicators.
3689 (usage): Make more verbose.
3690 * aclocal.m4,config.in,tconfig.in,configure.in,configure: New files.
3691 * Makefile.in,Make-common.in,callback.c: New files.
3692 * nltvals.def,gentmap.c,gentvals.sh: New files.
3693
3694Tue Nov 12 13:34:00 1996 Dawn Perchik <dawn@cygnus.com>
3695
3696 * run.c: Include stdarg.h if __STDC__.
3697
3698Tue Oct 15 11:16:31 1996 Jeffrey A Law (law@cygnus.com)
3699
3700 * run.c (main): Don't print out anything if the signal
3701 number is zero (ie no signal).
3702
57bc1a72
MM
3703Tue Oct 15 11:20:44 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3704
3705 * run.c (main): Print out if the program raised a signal.
3706
3707Wed Sep 18 09:52:14 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3708
3709 * run.c (exec_bfd): Rename from sim_bfd, to use the gdb name.
3710 (main): Ditto.
3711
3733d109
JSC
3712Tue Sep 17 11:04:50 1996 James G. Smith <jsmith@cygnus.co.uk>
3713
3714 * run.c (main): Explicitly cast malloc() parameter.
3715
9b280a86
MM
3716Thu Sep 12 11:27:21 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3717
3718 * run.c (sim_bfd): New global to hold the bfd pointer for the
3719 executable.
3720 (main): Initialize sim_bfd.
3721
3722Fri Dec 15 16:27:49 1995 Ian Lance Taylor <ian@cygnus.com>
3723
3724 * run.c (main): Use new bfd_big_endian macro.
3725
3726Wed Nov 8 15:49:49 1995 James G. Smith <jsmith@pasanda.cygnus.co.uk>
3727
3728 * run.c (main): Removed SH specific comments, so source is
3729 generic. Also updated to only load relevant sections. Moved
3730 sim_open() to after callback attach (to match GDB).
3731
3732 * run.1: Removed SH specific comments.
3733
3be50301
JW
3734Sat Oct 21 12:31:01 1995 Jim Wilson <wilson@chestnut.cygnus.com>
3735
3736 * run.c (main): Always return sigrc at end.
3737
3738Tue Oct 10 12:03:13 1995 J.T. Conklin <jtc@rtl.cygnus.com>
3739
3740 * run.c (main): Print error diagnostic and exit if bfd_openr() or
3741 bfd_check_format() fails.
3742
f025d903
SC
3743Thu Sep 28 15:40:36 1995 steve chamberlain <sac@slash.cygnus.com>
3744
3745 * run.c, run.1: From sh directory.
3746
3747
This page took 0.307826 seconds and 4 git commands to generate.