2003-06-19 Andrew Cagney <cagney@redhat.com>
[external/binutils.git] / sim / ppc / ChangeLog
1 2003-06-19  Andrew Cagney  <cagney@redhat.com>
2
3         * Makefile.in (ICACHE_CFLAGS, SEMANTICS_CFLAGS): Delete.
4         (SIM_FPU_FLAGS): Define.
5         (icache.o): Delete explicit compile command.
6         (semantics.o, idecode.o): Delete explicit compile command.
7         (NOWARN_CFLAGS, STD_CFLAGS): Append SIM_FPU_CFLAGS.
8         * gen-support.c (gen_support_c): Generate #include of
9         "sim-inline.h" and "sim-fpu.h", but conditional on
10         HAVE_COMMON_FPU.
11         * gen-idecode.c (gen_idecode_c): Ditto.
12         * igen.c (gen_icache_c, gen_semantics_c): Wrap #include of
13         "sim-inline.h" and "sim-fpu.h" in HAVE_COMMON_FPU conditional.
14         Move to before "support.h".
15         * Makefile.in, gen-support.c, gen-idecode.c, igen.c: Update
16         copyright.
17         
18 2003-05-16  Ian Lance Taylor  <ian@airs.com>
19
20         * Makefile.in (various): Use $(SHELL) whenever we invoke
21         move-if-change.
22
23 2003-02-27  Andrew Cagney  <cagney@redhat.com>
24
25         * sim_calls.c (sim_open, sim_create_inferior): Rename _bfd to bfd.
26
27 2002-09-27  Andrew Cagney  <ac131313@redhat.com>
28
29         * hw_disk.c (hw_disk_init_address): Set device type to "block",
30         not "disk".
31
32 2002-06-22  Andrew Cagney  <ac131313@redhat.com>
33
34         * Makefile.in (INTL_SRC): Define.
35         (INTL_CFLAGS): Define.
36         (INTL_DIR): Define.
37         (STD_CFLAGS): Add INTL_CFLAGS.
38
39 2002-06-17  Elena Zannoni  <ezannoni@redhat.com>
40
41         * psim.c (psim_options): Don't choke when gdb invokes us with
42         the --architecture option, just ignore it.
43
44 2002-06-16  Andrew Cagney  <ac131313@redhat.com>
45
46         * configure: Regenerated to track ../common/aclocal.m4 changes.
47
48 2002-06-08  Andrew Cagney  <cagney@redhat.com>
49
50         * main.c: Include "gdb/callback.h" and "gdb/remote-sim.h".
51         * sim_calls.c: Ditto.
52
53 2002-05-30  DJ Delorie  <dj@redhat.com>
54
55         * lf.c (lf_print__gnu_copyleft): Convert multiline strings to
56         compatible format.
57         * gen-idecode.c (print_run_until_stop_body): Likewise.
58         * gen-model.c (gen_model_c): Likewise.
59
60 2002-04-15  Elena Zannoni  <ezannoni@redhat.com>
61
62         * sim_calls.c (sim_fetch_register, sim_store_register): Return -1 for
63         AltiVec registers as a temporary stopgap.
64
65 2002-03-24  David O'Brien  <obrien@FreeBSD.org>
66
67         * ppc/hw_disk.c: Export a disk device property.
68
69 2002-03-23  Andrew Cagney  <ac131313@redhat.com>
70
71         From 2001-12-09 Julien Ducourthial <jducourt@noos.fr>:
72         * ppc-instructions (lswx): Do the register control with the
73         register count.  Initialize the right register in the loop.
74         (mtfsfi) : Correct prefix for the instruction.
75
76 2002-02-24  Andrew Cagney  <ac131313@redhat.com>
77
78         From wiz at danbala:
79         * std-config.h: Fix grammar and typos.  Update copyright.
80         Fix PR gdb/287.
81
82 2002-01-12  matthew green  <mrg@redhat.com>
83
84         * Makefile.in (tmp-igen): Pass -I $(srcdir) to igen.
85         * igen.c (main): Change -I to add include paths for :include:
86         files.
87         Implement -G as per sim/igen, with just gen-icache=N support.
88         Call load_insn_table() with the built include path.
89
90         * ld-insn.c (parse_include_entry): New. Load an :include: file.
91         (load_insn_table): New `includes' argument.  Look for :include:
92         entries and call parse_include_entry() for them.
93         (main): Adjust load_insn_table() call.
94         * ld-insn.h (model_include_fields): New enum.
95         (load_insn_table): Update prototype.
96         * table.c (struct _open_table, struct _table): Rework
97         structures to handle included files.
98         (table_push): Move the guts of table_open() here.
99
100         * table.c (struct _open table, struct table): Make table object an
101         indirect ptr to the current table file.
102         (current_line, new_table_entry, next_line): Make file arg type
103         open_table.
104         (table_open): Use table_push.
105         (table_entry_read): Point variable file at current table, at eof, pop
106         last open table.
107
108         * misc.h (NZALLOC): New macro. From sim/igen.
109
110         * table.h, table.c (table_push): New function.
111
112 2002-01-04  matthew green  <mrg@redhat.com>
113
114         * bits.c (LSMASKED64): New inline function.
115         (LSEXTRACTED64): Likewise.
116         * bits.h (_LSB_POS, _LSMASKn, LSMASK64): New macros from
117         sim/common/sim-bits.h
118         (LSMASKED64, LSEXTRACTED64): New functions definitions.
119         * Makefile.in (sim-bits.o): Remove target.
120
121         * main.c (zalloc): Fix typo in error message.
122
123 2001-12-16  Andrew Cagney  <ac131313@redhat.com>
124
125         * configure.in (sim_fpu): Don't add sim-bits.o.
126         * configure: Re-generate.
127
128 2001-12-15  matthew green  <mrg@redhat.com>
129
130         * main.c: Include "defs.h", "bfd.h", "callback.h" and "remote-sim.h".
131         (sim_io_error): New function.
132         * sim_calls.c: (sim_io_error): New function.
133
134 2001-12-14  matthew green  <mrg@redhat.com>
135
136         * Makefile.in (LIB_OBJ): Add @sim_fpu@.
137         (ICACHE_CFLAGS, SEMANTICS_CFLAGS): New variables.
138         (icache.o, semantics.o): Add new ICACHE_FLAGS & SEMANTICS_FLAGS.
139         (sim-fpu.o, sim-bits.o, tconfig.h): New targets.
140         * configure.in: Rename INLINE_LOCALS to PSIM_INLINE_LOCALS.  Add a
141         check for sim/common/sim-fpu.c.  Output sim_fpu and sim_fpu_cflags.
142         * configure: Regenerate.
143         * device.h (device_find_integer_array_property): Match function definition.
144         * gen-icache.c (print_icache_internal_function_declaration): Rename
145         INLINE_ICACHE to PSIM_INLINE_ICACHE.
146         * gen-idecode.c (print_idecode_run_function_header): Rename INLINE_IDECODE
147         to PSIM_INLINE_IDECODE.
148         * gen-semantics.c (print_semantic_function_header): Rename
149         EXTERN_SEMANTICS to PSIM_EXTERN_SEMANTICS.
150         * gen-support.c (print_support_function_name): Rename INLINE_SUPPORT to
151         PSIM_INLINE_SUPPORT.
152         * igen.c (print_function_name): Also escape `(' and `)'.
153         (gen_semantics_h): Rename EXTERN_SEMANTICS to PSIM_EXTERN_SEMANTICS.
154         (gen_semantics_c): Likewise.  Also output includes for "sim-fpu.h"
155         * inline.h (INLINE_SIM_ENDIAN): Renamed INLINE_PSIM_ENDIAN.
156         (EXTERN_SIM_ENDIAN): Renamed EXTERN_PSIM_ENDIAN.
157         (STATIC_INLINE_SIM_ENDIAN): Renamed STATIC_INLINE_PSIM_ENDIAN.
158         (INLINE_LOCALS): Renamed PSIM_INLINE_LOCALS.
159         (EXTERN_SUPPORT): Renamed PSIM_EXTERN_SUPPORT.
160         (INLINE_SUPPORT): Renamed PSIM_INLINE_SUPPORT.
161         (EXTERN_SEMANTICS): Renamed PSIM_EXTERN_SEMANTICS.
162         (INLINE_SEMANTICS): Renamed PSIM_INLINE_SEMANTICS.
163         (EXTERN_IDECODE): Renamed PSIM_EXTERN_IDECODE.
164         (INLINE_IDECODE): Renamed PSIM_INLINE_IDECODE.
165         (EXTERN_ICACHE): Renamed PSIM_EXTERN_ICACHE.
166         (INLINE_ICACHE): Renamed PSIM_INLINE_ICACHE.
167         * options.c (options_inline): Fix names.
168         * sim-endian-n.h: Change INLINE_SIM_ENDIAN to INLINE_PSIM_ENDIAN.
169         * sim-endian.h: Likewise.
170         * sim-main.h: New file.
171         * std-config.h: Rename INLINE_LOCALS to PSIM_INLINE_LOCALS.
172
173 2001-12-01  Andrew Cagney  <ac131313@redhat.com>
174
175         From Mark Peek.
176         * ppc-spr-table: Add SDA and PIR.
177
178 2001-10-29  Andrew Cagney  <ac131313@redhat.com>
179
180         * tree.c (parse_size): Assert #size-cells > 0.
181         (parse_address): Ditto for #address-cells.
182         (parse_reg_property): Only parse the size when #size-cells is
183         non-zero.
184
185 2001-10-25  Andrew Cagney  <ac131313@redhat.com>
186
187         * emul_generic.c (OEA_MEMORY_SIZE): Increase to 4mb.
188         * hw_htab.c (htab_map_binary): Don't try to map the text section
189         when it is empty.
190         * emul_chirp.c (map_over_chirp_note): Default load-base to -1 not
191         CHIRP_LOAD_BASE.
192         (emul_chirp_create): Map in the interrupt table.
193
194 2001-07-16  Daniel Jacobowitz  <drow@mvista.com>
195
196         * Makefile.in: Add dependencies on $(CPU_H).
197
198 Wed Mar  7 10:45:12 HST 2001  Glen Nakamura  <gen@lava.net>
199
200         * hw_init.c (dma_file): Fixed problem with loading last 1KB of
201         file.
202         
203 2001-03-04  Andrew Cagney  <ac131313@redhat.com>
204
205         * emul_netbsd.c [WITH_NetBSD_HOST]: Include <sys/mount.h> and
206         <errno.h>.
207         (do_stat): Only do SYS test when SYS_stat defined.
208         (do_sigprocmask): Ditto for SYS_sigprocmask.
209         (do_fstat): Ditto for SYS_fstat.
210         (do_getdirentries): Ditto for SYS_getdirentries.
211         (do_lstat): Ditto for SYS_lstat.
212
213 2001-01-15  Geoffrey Keating  <geoffk@redhat.com>
214
215         * emul_netbsd.c (do_open): Translate the flag parameter to the
216         open syscall to the numbers supported by the host.
217
218 2000-12-12  Geoffrey Keating  <geoffk@redhat.com>
219
220         * sim-endian.h: Don't have parameters on macro definitions which
221         are simply renaming functions, to permit use of XCONCAT2 in both
222         the macro name and the arguments in a use of such a definition.
223
224 2000-11-15  Jim Blandy  <jimb@redhat.com>
225
226         * sim_calls.c: Doc fix.
227         (sim_fetch_register, sim_store_register): Call
228         gdbarch_register_name directly, instead of going through
229         REGISTER_NAME macro.
230
231 2000-10-24  Geoff Keating  <geoffk@cygnus.com>
232
233         * ppc-instructions (lfsux): Correct XO field of lfsux instruction.
234
235 Tue May 23 21:39:23 2000  Andrew Cagney  <cagney@b1.cygnus.com>
236
237         * configure: Regenerated to track ../common/aclocal.m4 changes.
238
239 Fri Apr 28 15:59:27 2000  Andrew Cagney  <cagney@b1.cygnus.com>
240
241         * events.c (event_queue_process): Call update_time_from_event
242         every time an event is removed from the queue.
243         (update_time_from_event): Delete assertion that a negative
244         time_from_event implies an empty event queue.
245
246 Fri Apr 28 15:53:54 2000  Andrew Cagney  <cagney@b1.cygnus.com>
247
248         * interrupts.c (deliver_hardware_interrupt): Print time trace in
249         decimal.
250         * events.c (event_queue_process): Cleanup trace message.
251         (update_time_from_event): Trace full event queue.
252
253 2000-03-25  Geoff Keating  <geoffk@cygnus.com>
254
255         * ppc-instructions (Disabled_Exponent_Underflow): Increment
256         the exponent when denormalizing.
257
258 Thu Sep  2 18:15:53 1999  Andrew Cagney  <cagney@b1.cygnus.com>
259
260         * configure: Regenerated to track ../common/aclocal.m4 changes.
261
262 1999-05-08  Felix Lee  <flee@cygnus.com>
263
264         * configure.in: Use AC_EXEEXT instead of AM_EXEEXT.
265         * configure: Regenerated to track ../common/aclocal.m4 changes.
266         
267 1999-04-02  Keith Seitz  <keiths@cygnus.com>
268
269         * sim_calls.c (POLL_QUIT_INTERVAL): Define. Used to tweak
270         the frequency at which the poll_quit callback is called.
271         (poll_quit_count): New global.
272         (sim_io_poll_quit): Only call the poll_quit callback
273         after the specified POLL_QUIT_INTERVAL.
274
275 1999-02-22  Jim Lemke  <jlemke@cygnus.com>
276
277         * dc-complex: Force expansion on all bits of field BO.
278         Previously, the least-significant (prediction) bit was ignored.
279         * ppc-instructions (conditional branches): Implement mpc860c0 option.
280         * igen.c (gen_semantics_[ch]): Setup for mpc860c0 option.
281         * psim.c (is_num, psim_options): Added parsing for mpc860c0 option.
282         * interrupts.h: Added "mpc860c0_instruction_program_interrupt".
283         * interrupts.c (program_interrupt): Added handling for above interrupt.
284
285 1999-02-01  Jim Blandy  <jimb@zwingli.cygnus.com>
286
287         Make the simulator compatible with the MPC750.  It would be nicer
288         to make this a real multi-sim, but that's more work than we have
289         time for.
290         * emul_generic.c (emul_add_tree_options): Only require strict
291         alignment if it was explicitly requested at configuration time.
292         Don't make it the default for little-endian machines.
293         * ppc-spr-table (UMMCR0, UMMCR1, UPMC1, UPMC2, USIA, UPMC3, UPMC4,
294         MMCR0, PMC1, PMC2, SIA, MMCR1, PMC3, PMC4, L2CR, ICTC, THRM1,
295         THRM2, THRM3): Plop in the MPC750 SPR registers.
296         (DABR): This is weird.  This was HID5, but the PPC spec says this
297         should be DABR; why did some random processor use it for something
298         else?  The HID5 entry dates back to the original checkin of the
299         simulator code in 1995, so remove it.
300         * sim_calls.c (register_names): Delete this; since the user can
301         now change GDB's list of register names dynamically, we can't
302         pretend there's a static mapping here.
303         (sim_fetch_register, sim_store_register): Call GDB's REGISTER_NAME
304         function to get the register name.  That ought to be accurate.
305         However, we're changing a compile-time dependency (using the
306         REGISTER_NAMES macro) into a link- and run-time dependency
307         (calling REGISTER_NAME, which happens to be a function call on the
308         PPC).
309
310 1999-01-22  Jim Lemke <jlemke@cygnus.com>
311
312         * igen.c(gen_semantics_[ch]): setup/use of new option
313         (-o mpc860c0[=n]).
314         interrupts.[ch](mpc860c0_instruction_program_interrupt): added.
315         ppc-instructions(the four branch insn groups): detect problematic br's.
316         psim.c(is_num - added, psim_options): Parse and init new option.
317         These changes are currently under #ifdef WITH_OPTION_MPC860C0.
318
319 1998-12-01  Ken Raeburn  <raeburn@cygnus.com>
320
321         * hw_nvram.c (hw_nvram_bcd): Force value to fit in 0..99.
322
323 Fri Nov 20 12:17:28 1998  Andrew Cagney  <cagney@b1.cygnus.com>
324
325         * main.c (sim_io_poll_quit): Stub function.
326
327         * events.c (SIM_EVENTS_POLL_RATE): Define.
328         (sim_events_poll): Copy function from common/sim-events.c.
329         (event_queue_init): Copy scheduling of sim_events_poll from same.
330
331         * sim_callbacks.h, sim_calls.c (sim_io_poll_quit): New function,
332         poll the external environment.
333
334 1998-11-19  Michael Meissner  <meissner@cygnus.com>
335
336         * ppc-instructions (is_{NaN,inf}): Use unsigned64 to get the
337         fractional type, so that quiet NaN's aren't treated like
338         Infinities.
339
340 Mon Sep 28 09:42:45 1998  Drew Moseley  <dmoseley@cygnus.com>
341
342         * table.c (table_open): For cygwin hosts, we need to use the
343         return value from the read routine as the number of bytes to
344         process.  This apparently is due to text-mode vs binary-mode.  If
345         the mounts are done text-mode, then the size returnedby fstat()
346         may be different than the number of bytes "read" in text mode.
347
348 Sun Oct  4 00:50:47 1998  Felix Lee  <flee@cygnus.com>
349
350         * emul_netbsd.c (do_open): fix order-of-evaluation problem.
351         (do_close): ditto.
352         (do_fstat): ditto.
353         (do_lstat): ditto.
354
355 1998-09-03  Michael Meissner  <meissner@cygnus.com>
356
357         * emul_{netbsd,unix}.c: Update copyright year.
358
359 Mon Jun 29 10:57:36 1998  Michael Snyder  <msnyder@cleaver.cygnus.com>
360
361         * sim_calls.c (sim_fetch_register, sim_store_register):
362         return zero when nothing to do.
363
364 1998-06-26  Michael Meissner  <meissner@cygnus.com>
365
366         * configure.in (AC_CHECK_HEADERS): Don't check for sys/mount.h.
367         * configure: Regenerate.
368         * emul_{netbsd,unix}.c (toplevel): No longer try to include
369         sys/mount.h. It conflicts on Linux when gnu libc2 is used.
370
371 Tue May 12 12:10:33 PDT 1998  James Ingham  <jingham@leda.cygnus.com>
372
373         * Makefile.in: The run target depended on a target psim$(EXEEXT),
374         but there was no such target, only plain psim.  So I changed the
375         run target to depend on psim.
376
377 Sat May  2 01:10:12 1998  Stu Grossman  <grossman@babylon-5.cygnus.com>
378
379         * aclocal.m4:  Remove defs of AM_EXEEXT and AM_CYGWIN32.  These are
380         now defined in ../common/aclocal.m4, and the double definition causes
381         problems with AC_SUBST of EXEEXT.
382         * configure:  Regenerate.
383         
384 Wed Apr 29 15:44:52 1998  Geoffrey Noer  <noer@cygnus.com>
385
386         * aclocal.m4: new file for AM_EXEEXT macro
387         * configure.in: call AM_EXEEXT
388         * configure: regenerate with autoconf 2.12.1.
389         * Makefile.in: add EXEEXT support
390
391 Sun Apr 26 15:31:55 1998  Tom Tromey  <tromey@creche>
392
393         * configure: Regenerated to track ../common/aclocal.m4 changes.
394         * config.in: Ditto.
395
396 Sun Apr 26 15:19:51 1998  Tom Tromey  <tromey@cygnus.com>
397
398         * acconfig.h: New file.
399         * configure.in: Reverted change of Apr 24; use sinclude again.
400         Don't call AC_C_CROSS.
401
402 Fri Apr 24 14:16:40 1998  Tom Tromey  <tromey@creche>
403
404         * configure: Regenerated to track ../common/aclocal.m4 changes.
405         * config.in: Ditto.
406
407 Fri Apr 24 11:18:46 1998  Tom Tromey  <tromey@cygnus.com>
408
409         * Makefile.in (top_builddir): New macro.
410         (INTLLIBS): New macro.
411         (INTLDEPS): Likewise.
412         (psim): Depend on INTLDEPS; link against INTLLIBS.
413         * configure.in: Call CY_GNU_GETTEXT.
414
415 Wed Apr 22 14:28:48 1998  Michael Meissner  <meissner@cygnus.com>
416
417         * configure: Regenerate with autoconf 2.12.1.
418
419 Fri Mar 13 09:25:58 1998  Andrew Cagney  <cagney@b1.cygnus.com>
420
421         * psim.c (psim_read_register, psim_write_register): Handle updates
422         for FPSCR.
423
424         * registers.c (register_description): Reconize "FPSCR".
425
426         * emul_netbsd.c (emul_netbsd_create): When FP available, enable
427         MSR FP exception mode. Do not enable FPSCR bits.
428         * emul_unix.c (emul_unix_create): Ditto.
429
430 Tue Feb 17 12:48:58 1998  Andrew Cagney  <cagney@b1.cygnus.com>
431
432         * sim_calls.c (sim_store_register, sim_fetch_register): Pass in
433         length parameter.  Return -1.
434
435 Mon Feb  9 14:13:14 1998  Andrew Cagney  <cagney@b1.cygnus.com>
436
437         * ppc-instructions (fdiv, fdivs): Check for divide by zero.
438         (is_invalid_zero_divide, invalid_zero_divide_operation): New
439         functions.
440         
441 Wed Dec 10 17:38:28 1997  Andrew Cagney  <cagney@b1.cygnus.com>
442
443         * sim_calls.c (sim_load): Do not parse PROG using buildargv, use
444         raw value instead.
445
446 1997-11-05  Felix Lee  <flee@cygnus.com>
447
448         * emul_chirp.c: #ifdef HAVE_UNISTD_H
449
450 Wed Oct 15 08:50:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
451
452         * corefile.c (core_attach): Pad out allocated memory regions so
453         that they are always correctly aligned.
454         (struct _core_mapping, core_map_attach, core_init,
455         new_core_mapping): Change free_buffer to type void*.
456
457 Mon Oct  6 18:09:26 1997  Michael Meissner  <meissner@cygnus.com>
458
459         * sim_calls.c (zfree): Call free correctly.
460
461 Mon Sep 29 10:05:01 1997  Andrew Cagney  <cagney@b1.cygnus.com>
462
463         * sim_calls.c (zfree): Use free, not mfree.
464         (sim_io_flush_stdoutput): Replace gdb_flush with callback ->
465         flush_stdout.
466
467 Fri Sep 26 09:50:29 1997  Andrew Cagney  <cagney@b1.cygnus.com>
468
469         * ppc-instructions (sraw, slw, srw): From Charles Lefurgy, Fix
470         mask extracting shift amount. Correctly condition for setting XER
471         in sraw.
472         (ldhau): From Johannes Reisinger, update rA after load.
473
474 Tue Sep  9 22:13:23 1997  Felix Lee  <flee@cygnus.com>
475
476         * basics.h (CONCAT*): token-pasting macros, if ALMOST_STDC,
477         for MSVC.
478         * words.h: __int64 instead of long long for MSVC.
479
480 Wed Aug 27 10:24:15 1997  Andrew Cagney  <cagney@b1.cygnus.com>
481
482         * sim_calls.c (sim_create_inferior): Check the simulator was
483         initialized before creating inferior.
484
485         * idecode_expression.h (ALU_END): From Charles Lefurgy - Extract
486         sign bit using 64 bit and not a 32 bit mask.
487
488 Wed Aug 27 10:15:48 1997  Andrew Cagney  <cagney@b1.cygnus.com>
489
490         * sim_calls.c (sim_load): From Ian Lance Taylor - free argv after
491         it has been used, not before.
492         
493 Tue Aug 26 10:41:35 1997  Andrew Cagney  <cagney@b1.cygnus.com>
494
495         * sim_calls.c (sim_kill): Delete.
496         (sim_create_inferior): Add ABFD argument.
497         (entry_point): Delete variable.
498         (sim_load): Move setting of PC from here.
499         (sim_create_inferior): To here.
500
501 Mon Aug 25 16:17:06 1997  Andrew Cagney  <cagney@b1.cygnus.com>
502
503         * sim_calls.c (sim_open): Add ABFD argument.
504
505 Thu Jul  3 10:18:06 1997  Andrew Cagney  <cagney@b1.cygnus.com>
506
507         * ppc-instructions (PPC_INSN_INT): From Michael Thies - Monitoring
508         CR register updates dependant on RC value had logic backwards.
509
510         * ppc-instructions (Load String Word Immediate): From Brad Parker
511         - sense of wrap test in check for overwriting RA wrong.
512         (Load String Word Indexed): Ditto.
513         
514         * configure.in: From Erik Landry - set sim_default_model not
515         sim_model for sim-default-model option.
516         * configure: Regenerate.
517         
518         * interrupts.c (check_masked_interrupts): Schedule a hardware
519         interrupt delivery when FP interrupts get enabled.
520         (program_interrupt): Generate FP exceptions instead of aborting.
521         (deliver_hardware_interrupt): Deliver a FP exception if so
522         enabled.
523
524         * registers.h: Add definition of fpscr_vx_bits.
525
526         * idecode_expression.h (FPSCR_END): Always update FEX and VX bits
527         in FPSCR.
528         (FPSCR_END): Explicitly check for possible floating point
529         exception conditions.
530         (FPSCR_BEGIN): Simplify.
531         
532         * ppc-instructions (Move From FPSCR): Enable.
533         (Move To FPSCR Bit 1): Ditto.
534         (Move To FPSCR Bit 0): Ditto.
535         (Move To FPSCR Field Immediate): Ditto.
536         (Move to Condition Register from FPSCR): Simplify.
537         (invalid_arithemetic_operation): Generate a QNaN when invalid
538         operation exception disabled.
539         
540 Tue May 20 10:22:50 1997  Andrew Cagney  <cagney@b1.cygnus.com>
541
542         * sim_calls.c (sim_open): Add callback argument.
543         (sim_set_callbacks): Delete.
544
545 Tue Apr 22 22:36:57 1997  Mike Meissner  <meissner@cygnus.com>
546
547         * sim_callbacks.h (error): Make declaration match gdb's.
548         * main.c (error): Ditto.
549
550 Fri Apr 18 17:03:09 1997  Andrew Cagney  <cagney@b1.cygnus.com>
551
552         * sim_calls.c (sim_stop_reason): Simplify.  Was running implies
553         stopped/SIGINT. Exit implies a status code.
554
555         * psim.c (cntrl_c_simulation): From main.c.  Event function that
556         halts the simulator.
557         (psim_stop): New. Asynchronously schedule a stop simulator event.
558         (psim_run_until_stop): Delete. Made redundant by psim_stop.
559
560         * main.c (cntrl_c): Update.
561         (cntrl_c_simulation): Moved to psim.c.
562
563         * sim_calls.c (sim_stop): New function. Use psim_stop which
564         schedules a stop event.
565         (sim_resume): Drop SIGINT handler, now in gdb/main.c.
566         (sim_resume): Use psim_run as stop variable no longer needed.
567
568 Fri Apr 18 17:03:08 1997  Andrew Cagney  <cagney@b1.cygnus.com>
569
570         * psim.c (psim_options): Handle -E option correctly.
571         (psim_usage): Document.
572
573 Thu Apr 17 03:28:03 1997  Doug Evans  <dje@canuck.cygnus.com>
574
575         * psim.c (psim_options): Ignore -E option (sets endianness).
576         * sim_calls.c: #include bfd.h.
577         (entry_point): New static local.
578         (sim_load): Return SIM_RC.  New arg abfd.  Set start address from bfd.
579         (sim_create_inferior): Return SIM_RC.  Delete arg start_address.
580
581 Tue Apr 15 14:57:18 1997  Ian Lance Taylor  <ian@cygnus.com>
582
583         * Makefile.in (INSTALL): Set to @INSTALL@.
584         (INSTALL_XFORM, INSTALL_XFORM1): Remove.
585         (install): Depend upon installdirs.  Use $(program_transform_name)
586         directly, rather than using $(INSTALL_XFORM).
587         (installdirs): New target.
588
589 Fri Apr  4 17:54:36 1997  Jim Wilson  <wilson@cygnus.com>
590
591         * Makefile.in (tmp-hw, tmp-pk): Use for loop to eliminate duplicates
592         rather than the non-portable cat -n.
593
594 Mon Apr 14 16:29:51 1997  Ian Lance Taylor  <ian@cygnus.com>
595
596         * Makefile.in (INSTALL): Change install.sh to install-sh.
597
598 Tue Apr  1 18:15:14 1997  Jim Wilson  <wilson@cygnus.com>
599
600         * ppc-instructions: Change milhwu to mulhwu.
601
602 Wed Apr  2 15:38:08 1997  Doug Evans  <dje@canuck.cygnus.com>
603
604         * sim_calls.c (sim_open): New arg `kind'.
605
606 Wed Apr  2 14:51:17 1997  Ian Lance Taylor  <ian@cygnus.com>
607
608         * COPYING: Update FSF address.
609
610 Tue Mar 25 16:17:59 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
611
612         * main.c (sim_io_read_stdin): Only compile unbuffered IO code if
613         all the required features are supported by the host OS.
614
615 Tue Mar 25 12:13:02 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
616
617         * emul_bugapi.c (emul_bugapi_create): Guard against NULL images.
618
619         * configure.in (enable-sim-endain): Correct typo in usage (from
620         Erik Landry <landry@ENGR.ORST.EDU>).
621         * configure: Re-generate.
622
623 Fri Mar 14 18:23:02 1997  Andrew Cagney  <cagney@kremvax.cygnus.com>
624
625         * Makefile.in (targ-vals.def): Re-do rule so that it works with
626         FreeBSD's make.  Didn't like $<.
627
628 Thu Mar 13 12:55:48 1997  Doug Evans  <dje@canuck.cygnus.com>
629
630         * sim_calls.c (sim_open): New SIM_DESC result.  Argument is now
631         in argv form.
632         (other sim_*): New SIM_DESC argument.
633
634 Thu Feb 13 10:35:14 1997  Andrew Cagney  <cagney@phydeaux.cygnus.com>
635
636         * ppc-opcode-simple-array, ppc-opcode-simple-goto,
637         ppc-opcode-simple-switch, ppc-opcode-complex-array,
638         ppc-opcode-complex-goto, ppc-opcode-complex-switch,
639         ppc-opcode-jump, ppc-opcode-goto, ppc-opcode-flat: Delete,
640         superseeded by --sim-decode-mechanism option.
641
642         * ppc-opcode-simple, dc-simple: Rename to be 8.3
643         * ppc-opcode-complex, dc-complex: Ditto.
644         * ppc-opcode-stupid, dc-stupid: Ditto.
645         * ppc-opcode-test-1, dc-test.01: Ditto.
646         * ppc-opcode-test-2, dc-test.02: Ditto.
647
648         * configure.in (--enable-sim-opcode): Change prefix to dc- instead
649         of ppc-opcode-.
650
651 Wed Feb 12 19:33:45 1997  Andrew Cagney  <cagney@phydeaux.cygnus.com>
652
653         * Many of the ppc-opcode-* files are identical baring the type of
654         lookup table.  Instead of having multiple tables, igen can do this
655         via an additional option.
656         
657         * ld-decode.h, ld-decode.c (force_decode_gen_type): New function,
658         allow the type of generated table specified in the decode file to
659         be overridden.
660
661         * ld-decode.c (load_decode_table): Allow the table type to be
662         overridden.
663
664         * igen.c (main): Add -T <mechanism> option so that an overriding
665         instruction decode mechanism can be specified.
666
667         * configure.in: New option --sim-decode-mechanism to control
668         igen's new -T <mechanism> flag.
669         * Makefile.in (IGEN_FLAGS): Add IGEN_IDECODE_MECHANISM set by the
670         configure script.
671         * configure: Regenerate.
672         
673 Tue Feb 11 13:49:10 1997  Michael Meissner  <meissner@tiktok.cygnus.com>
674
675         * events.c (event_queue_create): Don't use NULL to initialize an
676         integer field.
677         (even_queue_{init,schedule_after_signal,tick}): Conditionalize use
678         of sigprocmask to appropriate autoconf test.
679
680         * main.c ({cntrl_c,main}): Use RETSIGTYPE for signal return type,
681         don't assume void.
682         * sim_calls.c (sim_{ctrl_c,resume}): Ditto.
683
684         * Makefile.in (callback.o): Define HAVE_CONFIG_H, so callback.c
685         includes our config.h.
686
687 Tue Feb  4 13:42:59 1997  Doug Evans  <dje@canuck.cygnus.com>
688
689         * configure.in: Fix typo in test for callback.c.
690         * configure: Regenerated.
691
692 Fri Feb  7 10:04:25 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
693
694         * emul_chirp.c (emul_chirp_create): Handle a virtbase of -1 being
695         found in the device tree.
696
697 Wed Feb  5 10:56:27 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
698
699         * Property create/initialization still wasn't correctly ordered.
700         Should be delaying everything related to ihandle creation until
701         after the rest of the tree has been established.
702         
703         * device.c (device_find_ihandle_runtime_property): Update.
704         (device_add_ihandle_runtime_property): Update.
705
706         * tree.c (parse_ihandle_property): Delay lookup of the device to
707         be opened until the ihandle initialization phase.
708         * tree.c (print_properties): Update.
709
710 Wed Feb  5 10:56:27 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
711         
712         * gen-icache.c (print_icache_extraction): Add a reason parameter.
713         Augment each extracted field with a comment citing the codes
714         origin.  Should simplify tracking down incorrect cache
715         extractions.
716
717 Tue Feb  4 17:44:51 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
718
719         * gen-icache.c: Generalize code handling XXX_is_NNN so that it
720         works for normal and boolean table entries.
721
722         * psim.c (psim_write_memory): last_cpu == -1 or nr_cpus is now
723         valid.  Handle this just like *_{read,write}_register now handles
724         it.
725
726 Mon Feb  3 17:18:16 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
727
728         * events.c (insert_event_entry): Correct loop termination
729         assertions.
730
731 Fri Jan 31 16:20:26 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
732
733         * psim.c (psim_options): Add new option -c for max-iterations or
734         count.
735         (psim_usage): Document.
736         (psim_max_iterations_exceeded): New function, abort simulation if
737         max iterations exceeded.
738
739         * gen-idecode.c: Re-work the table lookup code so that it assumes
740         that the entry is a leaf by default.  Simplify the boolean table
741         entry code so that it involves a mask + test instead of shift +
742         shift + mask + test.
743
744         * gen-idecode.c: Correct generated igen body so that it no drops
745         or doubles clock interrupts.
746
747         
748 Thu Jan 30 11:23:20 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
749
750         * Makefile.in (BUILT_SRC_WO_CONFIG): Change targ-vals.* to
751         @sim_targ_vals@
752
753         * configure.in (sim_callback, sim_targ_vals): Set sim_targ_valls
754         if common callback is present.
755
756 Wed Jan 29 12:32:41 1997  Michael Meissner  <meissner@tiktok.cygnus.com>
757
758         * configure.in (sim_callback): If the gdb is post 4.16, configure
759         callback support from the common directory.
760         * configure: Regenerate.
761
762         * Makefile.in (BUILT_SRC_WO_CONFIG): Add targ-vals.{h,def} and
763         targ-map.c.
764         (GDB_OBJ): Add callback support configured in.
765         (gentmap,targ-vals.def): Build from common directory.
766         (targ-vals.h,targ-map.c): Build by running gentmap.
767         (callback.o): Build from source in common directory.
768         (targ-map.o): Add dependency.
769         (clean): Remove gentmap.
770
771 Wed Jan 29 12:14:19 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
772
773         * igen wasn't aborting if the opcode table contained no valid
774         fields.
775         
776         * misc.c (name2i): Possibly abort if an invalid name is
777         encountered.
778         * ld-decode.c: Abort if the table type isn't found.
779
780 Wed Jan 29 12:14:19 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
781
782         * When performance monitoring is disabled, it is still possible to
783         determine the simulation speed by looking at the number of elapsed
784         ticks recorded by the event queue.
785         
786         * psim.c (psim_write_register, psim_read_register): Force the cpu
787         to zero when it is either of `-1' or `nr_cpus'.  In both cases the
788         next cpu would be zero any way.
789
790         * mon.c (mon_print_info): If possible, print the system cycle
791         performance.  This is an indication of the number of instructions
792         per second.
793
794 Wed Jan 29 12:14:19 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
795
796         * The code to allow an event queue to be updated during a signal
797         was missing.  For main.c, a cntrl-c simulation termination wasn't
798         handled cleanly.
799         
800         * The simulation would not correctly restart if an event requested
801         that the simulation be halted.
802         
803         * psim.c (psim_options): Add hack to -i option to optionally
804         include a level vis -i2.
805         (psim_usage): Document.
806
807         * main.c (cntrl_c, cntrl_c_simulation): New functions.  When a
808         cntrl-c occures schedule an event to halt the simulation.
809         (main): Catch CNTRL-C signals with the function cntrl_c.
810
811         * events.c (event_queue_process): Mask interrupts while
812         manipulating the async event queue.
813         (event_queue_init): Ditto.
814         (event_queue_schedule_after_signal): Ditto.
815
816         * events.c (event_queue_process): Mark the event queue as being in
817         the processing state when processing has started.  Adjust code
818         so that it is tolerant of halts.
819         (event_queue_init): Start the event queue out with processing
820         false.
821         (event_queue_tick): Check that processing isn't still being
822         performed.
823         
824         * gen-idecode.c (print_run_until_stop_body): Call
825         event_queue_process_events to clear possibly pending events before
826         starting a simulation run.  Re-arange main loop so that simulator
827         is correctly restarted when an event halts the simulation.
828
829         * psim.c (psim_halt): Handle an event halting the simulation.
830         * psim.c (psim_init): Adjust initial cpu - == -1 - to match
831         reworked idecode.
832
833 Wed Jan 29 12:14:19 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
834
835         * ppc-opcode-complex: Correct typo - was expanding ORA instead of
836         RA.  Based on instruction frequency stats, expand additional
837         instructions.
838         * ppc-instructions: Change all `RA == 0' to RA_is_0.
839         
840         * ppc-opcode-stupid: Move all but the basic table in -complex into
841         here.  Update to new format.
842         
843         * Makefile.in (tmp-defines): New target. Force defines.h to always
844         be built.  Hence get ppc-opcode-goto to build.
845
846 Tue Jan 28 13:00:19 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
847
848         * hw_com.c (hw_com_instance_read, hw_com_instance_write):
849         Implement.
850         
851 Thu Jan 23 09:07:26 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
852
853         * hw_trace.c (hw_trace_init_data): Delete.  The trace options need
854         to be initialized independant of the rest of the simulation
855         initalization.  Otherwize a trace option explictly set from gdb
856         could be overridden by hw_trace.
857
858         * psim.c (psim_options): Clarify reason why the trace ioctl occures.
859
860         * FIXME: The trace code is too scattered - hw_trace.c, psim.c,
861         debug.c.  It could be much simpler.
862
863 Thu Jan 23 09:07:26 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
864         
865         * Some devices support removable media.  Add hooks to the disk
866         device so that it supports this.
867         
868         * device.c (device_add_string_array_property,
869         device_find_string_array_property): New functions, manipulate
870         properties containing an array of strings.
871         (device_find_string_property): Allow a string array.
872         (device_init_static_properties): Update.
873         (device_init_runtime_properties): Update.
874
875         * hw_disk.c (hw_disk_ioctl): Add ioctl for changing the disk
876         media.  If no file image is specified, use the next one in the
877         image property list.
878         (hw_disk_init_address): Change the file property so that it is a
879         string array - use the first entry for the initial file image.
880
881         * tree.c (print_string_aray_property): New function - print a
882         string array.
883         (print_properties): Adjust.
884         (print_string): Write a string, handling double quotes.
885
886         * device.h: Define an ioctl to `change-media' with an optional new
887         media image.
888         
889         * hw_disk.c: Allow floppy disk devices to be specified.
890
891         * psim.c (psim_command): New function, parse more complex psim
892         commands such as "change-media" and "trace".
893         * sim_calls.c (sim_do_command): Use.
894
895 Wed Jan 22 09:38:33 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
896
897         * For expressions like (RA == 0) that are entered in to the cache
898         as RA_is_0. If possible generate the result of the expression so
899         that the compiler gets a better chance of eliminating dead
900         branches.
901
902         * gen-icache.c (print_icache_extraction): For a cache entry of
903         the form <name>_is_<const> where it is a boolean field, generate
904         the result of the expression instead of the expression its self.
905         (print_icache_body): Remove code that was looking for *_is_0 and
906         then generating corresponding definitions.
907
908         * gen-icache.c (print_icache_struct): If there is no cache, do not
909         output expressions in idecode.h file.
910         
911         * gen-icache.c (print_icache_body): Output them here.
912         
913         * ppc-opcode-complex: Clarify constant values for SPR==LR register
914         expansion.
915
916         * ppc-cache-rules (RA_is_0, SPR_is_256): Two new cache entries.
917
918 Wed Jan 22 12:24:52 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
919
920         * The code that put values in and extracted values from the cache
921         was too compilicated.  The cache table did not allow values to be
922         computed from cache entries.  #defines could only be used when a
923         cache was present, remove the restriction.
924
925         * ld-cache.h, ld-cache.c: Add a new cache entry type - SCRATCH.  A
926         scratch variable is defined when a cache entry is beinf
927         filled. Change the definition of a COMPUTE variable to be defined
928         when the cache entry is being used.
929         * gen-icache.c: Update.
930         
931         * ld-cache.h, ld-cache.c: Change field names so that their meaning
932         is more obvious.  old_name->field_name, new_name->derived_name.
933         * gen-icache.c: Update
934         
935         * gen-icache.h, gen-icache.c (print_icache_body): Make the three
936         different types of cache code - put into cache, extract from
937         cache, no cache - an explicit argument to print_icache_body.
938         * gen-icache.c (print_icache_extraction): Ditto.
939         
940         * gen-semantics.c (print_c_semantic): Update use.
941         * gen-idecode.c (print_jump_insn): Update use.
942         * gen-icache.c (print_icache_function): Update use.
943
944         * igen.c (main): Change 'R' option so that it does not force the
945         cache.
946
947         * configure.in (enable-sim-icache): Clarify description.  Make
948         #define one of the defaults regardless of the cache.  Probably
949         should revamp and add a separate option.
950
951 Tue Jan 21 13:26:10 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
952
953         * pk_disklabel.c (block_is_fdisk): Tidy up traces - use dos
954         partition numbering.
955         (pk_disklabel_create_instance): Partition 1..4 are valid - not
956         1..3.
957         (is_iso9660): New function, verify a CD9660 File system.
958         (pk_disklabel_create_instance): Start expanding so that active
959         partition selection is supported.
960
961 Mon Jan 20 11:20:15 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
962
963         * The cap object was retaining a reference to the instance of a
964         device after it was deleted. Instead add and remove cap's from the
965         cap db as they are created and deleted.  This ensuring that a
966         capibility is only used during the lifetime of the corresponding
967         object.
968         
969         * cap.h, cap.c: Correct cap type - was signed32 should be
970         signed_cell.
971         
972         * cap.c (cap_add, cap_remove): New methods for cap object that
973         allow the explicit addition and removal of internal objects that
974         the cap knows about.
975         
976         * cap.c (cap_init): Rewrite.  Verify that the only objects
977         remaining in the cap data base are those that were entered first.
978         Thse objects will be the permenant ones.
979         * device.c (device_init_address): Remember to initialize the cap
980         database.
981         
982         * device.c (device_create_instance_from): Explicitly add device
983         instances to the cap database.  Simplify create code.
984         (device_instance_delete): Explicitly remove device instances from
985         the cap database.
986         
987         * device.c (device_create_from): Explicitly add a device to the
988         cap data base.
989         
990         * device.c (device_create_from): Always set the cap members.
991
992         * hw_disk.c: Output the instance when tracing.
993         
994 Sun Jan 19 16:44:29 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
995
996         * tree.c (split_device_specifier): Add support for aliases when
997         looking up a device. Now needs a device as an argument.
998         (split_property_specifier): Ditto.
999
1000 Sun Jan 19 15:28:23 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1001
1002         * The memory "claim" and "release" methods take an address and
1003         size as arguments.  These may be multi cell values. Initially fix
1004         the memory code so that they check/detect this.  Leave the
1005         adjustment of any clients to later.
1006         
1007         * hw_memory.c (hw_memory_instance_claim,
1008         hw_memory_instance_release): Handle multi-cell memory devices.
1009         
1010         * hw_memory.c (hw_memory_instance_claim): Be tolerant towards the
1011         release of memory regions that were not claimed.
1012
1013 Fri Jan 17 12:01:07 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1014
1015         * device.h, device.c (device_instance_call_method): Correct return
1016         type - can return either 0 or -1, hence should be a signed type.
1017         * device_table.h: Ditto.
1018         
1019         * hw_memory.c (hw_memory_instance_claim,
1020         hw_memory_instance_release): Update.
1021         * hw_disk.c (hw_disk_max_transfer, hw_disk_block_size,
1022         hw_disk_nr_blocks): Ditto.
1023         
1024 Fri Jan 17 11:50:13 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1025
1026         * emul_chirp.c (chirp_emul_claim): Implement using the "claim"
1027         method belonging to "/chosen/memory".
1028         (chirm_emul_release): Ditto.
1029         
1030         * Makefile.in (LIB_INLINE_SRC): Remove emul_* from list of files
1031         that are inlined.  These modules are called via a table and are
1032         not made inline.
1033
1034         * hw_init.c (update_for_binary_section): Fix failure to allocate
1035         memory used by the binary in real-mode executions. If "claim"
1036         property is present, allocate memory from the "/chosen/memory"
1037         device.
1038
1039         * emul_chirp.c (emul_chirp_create): Specify that memory should be
1040         claimed when loading a real image.
1041
1042         * hw_memory.c (hw_memory_instance_claim): Don't page align memory
1043         allocations.
1044
1045         * hw_memory.c (hw_memory_instance_release): Avoid infinite loop
1046         when merging adjacent memory chunks.
1047
1048 Thu Jan 16 08:51:25 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1049
1050         * vm.h (vm_data_map_read_buffer, vm_data_map_write_buffer): Add
1051         optional PROCESSOR & CIA args so that this routine also abort an
1052         access.
1053
1054         * vm_n.h (vm_data_map_read_N, vm_data_map_write_N): For a
1055         miss-aligned access when a transfer fails abort.
1056         
1057         * emul_bugapi.c (emul_bugapi_do_write): Use emul_read_buffer
1058         instead of the vm_read_buffer.
1059         * emul_netbsd.c (do_write): Ditto.
1060         * emul_unix.c (do_unix_write): Ditto.
1061
1062 Wed Jan 15 14:38:25 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1063
1064         * configure.in (--enable-sim-jump): Default is NULL and not -E.
1065         * configure: Regenerate.
1066         
1067         * basics.h (__attribute__): Enable attributes if GCC >= 2.6.
1068         (UNUSED): Only enable UNUSED if GCC >= 2.7.
1069         
1070         * gen-icache.c (print_icache_extraction): Print UNUSED macro
1071         instead of explicit __unused__ attribute.
1072         (print_icache_body): Ditto.
1073         * idecode_expression.h (FPSCR_BEGIN): Use UNUSED.
1074
1075 Wed Jan 15 13:54:50 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1076
1077         * cpu.h, cpu.c (cpu_synchronize_context): Add CIA argument as
1078         reference point.
1079
1080         * vm.c (vm_synchronize_context): Add PROCESSOR and CIA as
1081         arguments so that there is a reference point for recovery.
1082         (vm_synchronize_context): Pass processor+cia for errors.
1083         (om_unpack_sr): Ditto.
1084         (om_unpack_srs): Ditto.
1085         * vm.c (vm_create): Review error messages.
1086
1087         * vm.c: Include "cpu.h" so that cpu_error is visible.
1088
1089         * ppc-instructions (Return From Interrupt): Pass CIA.
1090         (Instruction Synchronize): Ditto.
1091         * psim.c (psim_init): Ditto.
1092
1093 Wed Jan 15 12:25:11 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1094
1095         * cpu.h, cpu.c (cpu_error): Aborts simulation with error message,
1096         but also saves current processor state.
1097         
1098         * basics.h: Move #include <stdarg.h> to here from device_table.h.
1099
1100         * interrupts.c (perform_oea_interrupt): Use.  No longer loose CIA
1101         when simulation aborted.
1102         (program_interrupt): Ditto.
1103         (floating_point_unavailable_interrupt): Ditto.
1104         (alignment_interrupt): Ditto.
1105         (floating_point_assist_interrupt): Ditto.
1106         (perform_oea_interrupt): Ditto.
1107         (machine_check_interrupt): Ditto.
1108
1109 Tue Jan 14 12:19:10 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1110
1111         * ppc-instructions (Move from Special Purpose Register): Support
1112         move from DEC.
1113
1114 Mon Jan 13 16:58:12 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1115
1116         * debug.h, debug.c: Add "interrupts" trace option.
1117
1118         * interrupts.c (data_storage_interrupt): Add tracing.
1119         (machine_check_interrupt): Ditto.
1120         (instruction_storage_interrupt): Ditto.
1121         (alignment_interrupt): Ditto.
1122         (program_interrupt): Ditto.
1123         (floating_point_unavailable_interrupt): Ditto.
1124         (system_call_interrupt): Ditto.
1125         (floating_point_assist_interrupt): Ditto.
1126         (deliver_hardware_interrupt): Ditto.
1127         
1128         * interrupts.c (program_interrupt): For UEA mode, halt the
1129         processor - so that the current state is saved - instead of
1130         aborting.
1131         (floating_point_unavailable_interrupt): Ditto.
1132         (floating_point_assist_interrupt): Ditto.
1133
1134 Thu Jan  2 09:10:41 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1135
1136         * interrupts.c (perform_oea_interrupt): Halt rather than abort on
1137         a double interrupt.
1138
1139 Wed Jan  1 22:54:52 1997  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1140
1141         * ppc-instructions (Store Multiple Word, Load Multiple Word):
1142         Enable.
1143
1144         * tree.c (print_properties): For an array consider printing it out
1145         as an integer array.
1146
1147         * hw_memory.c (hw_memory_init_address): If an "available" property
1148         is present, use that to initialize the available memory instead of
1149         using the reg property.
1150
1151         * emul_generic.c (emul_add_tree_hardware): Add "available"
1152         property to memory device.
1153
1154 Fri Dec 20 13:19:07 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1155
1156         * ppc-instructions (Rotate Left Word then AND with Mask): Enable.
1157
1158         * device.c (device_instance_call_method): Was only looking at the
1159         first method.
1160
1161         * hw_disk.c (hw_disk_nr_blocks): Implement #blocks method.
1162         (hw_disk_block_size): Implement block-size method.
1163         (hw_disk_max_transfer): Implement max-transfer method.
1164
1165         * hw_phb.c (hw_phb_init_address): Reinit the rest of the PHB.
1166
1167         * emul_chirp.c (chirp_emul_instance_to_path): Recover from an
1168         invalid ihandle.
1169         (chirp_emul_instance_to_package): Ditto.
1170         (chirp_emul_method): Ditto.
1171         (chirp_emul_read): Ditto.
1172         (chirp_emul_write): Ditto.
1173         (chirp_emul_close): Ditto.
1174         (chirp_emul_seek): Ditto.
1175         (chirp_emul_package_to_path): Ditto (for phandle).
1176         (chirp_emul_package_to_path): Return the length.
1177
1178         * psim.c (psim_merge_device_file): Allow continuation lines.
1179
1180 Thu Dec 19 11:09:43 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1181
1182         * emul_chirp.c (chirp_emul_boot): Implement. Well report the new
1183         string and exit.
1184         
1185         * emul_chirp.c (chirp_emul_exit): Correct type of args struct
1186         members - *_cell not host dependant int.
1187
1188 Wed Dec 18 17:49:59 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1189
1190         * interrupts.c (perform_oea_interrupt): Print additional
1191         information if a double interrupt is encountered.
1192
1193 Wed Dec 18 17:49:59 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1194         
1195         * psim.c (psim_merge_device_file): Tolerate an incorrect file-name
1196         being specified with the -f option.
1197         (psim_merge_device_file): Correct check for end of string.
1198
1199 Wed Dec 18 17:49:59 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1200         
1201         * emul_chirp.c (chirp_emul_peer): Was falling off the end of the
1202         list of devices. Return zero to the client instead.
1203         * emul_chirp.c (chirp_emul_child): Ditto
1204         * emul_chirp.c (chirp_emul_parent): Ditto
1205
1206         * device.c (device_root): Assert assumption about the device being
1207         valid.
1208
1209 Tue Dec 17 15:12:38 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1210
1211         * emul_chirp.c (emul_chirp_create): Add description property to
1212         each significant node in the device tree.
1213         * emul_bugapi.c (emul_bugapi_create): Ditto.
1214
1215 Fri Dec 13 14:30:31 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1216
1217         * main.c (sim_io_read_stdin): For a single byte STDIO read, use a
1218         tempoary two byte buffer.  Single byte read with fgets will not
1219         work.
1220         * main.c: Include errno.h.
1221         (sim_io_read_stdin): For non-STDIO, make it work.
1222
1223         * emul_chirp.c (chirp_emul_read): Return the correct error status.
1224
1225 Fri Dec 13 14:30:31 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1226
1227         * std-config.h (WITH_STDIO): Don't hard-wire the STDIO mechanism.
1228         Instead have each emulation default it to DO_USE_STDIO.
1229
1230         * emul_generic.c (emul_add_tree_options): Select the STDIO I/O
1231         mechanism as the default if enabled or if nothing selected.
1232
1233         * sim_calls.c (sim_io_read_stdin): Passify GCC's desire for a
1234         return value.
1235         (sim_io_write_stdout): Ditto.
1236         (sim_io_write_stderr): Ditto.
1237         * main.c (sim_io_write_stdout): Ditto.
1238         (sim_io_write_stderr): Ditto.
1239         (sim_io_read_stdin): Ditto.
1240
1241 Tue Dec 10 10:31:48 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
1242
1243         * emul_chirp.c (emul_chirp_instruction_call): Make *printf calls
1244         type correct.
1245         * vm.c (om_effective_to_virtual): Ditto.
1246         * events.c (event_queue_schedule{,_after_signal}): Ditto.
1247         (event_queue_{deschedule,process}): Ditto.
1248         * hw_htab.c (htab_decode_hash_table): Ditto.
1249         (htab_map_{page,binary}): Ditto.
1250         * hw_opic.c (hw_opic_init_data): Ditto.
1251         (handle_interrupt): Ditto.
1252         (do_processor_init_register_{read,write}): Ditto.
1253         (write_vector_priority_register): Ditto.
1254         ({read,write}_destination_register): Ditto.
1255         (do_suprious_vector_register_{read,write}): Ditto.
1256         (do_current_task_priority_register_N_{read,write}): Ditto.
1257         (do_timer_frequency_reporting_register_{read,write}): Ditto.
1258         (do_timer_N_{current,base}_count_register_{read,write}): Ditto.
1259         (do_ipi_N_dispatch_register_write): Ditto.
1260         (do_vendor_identification_register_read): Ditto.
1261         (do_feature_reporting_register_N_read): Ditto.
1262         (do_global_configuration_register_N_{read,write}): Ditto.
1263         * hw_phb.c (hw_phb_attach_address): Ditto.
1264         (hw_phb_unit_decode): Ditto.
1265         (hw_phb_address_to_attach_address): Ditto.
1266         (hw_phb_io_{read,write}_buffer): Ditto.
1267         * hw_ide.c (setup_fifo): Ditto.
1268
1269         * sim_calls.c ({defs,callback,remote-sim}.h): Find gdb include
1270         files via -I<dir> instead of using "../../gdb/" prefixes.
1271
1272 Tue Dec 10 10:12:44 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1273
1274         * debug.h: Add tracing for the pal device.
1275         * hw_pal.c: Update.
1276
1277         * emul_chirp.c (chirp_emul_getprop): More tracing.
1278
1279 Tue Dec 10 10:12:44 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1280
1281         * device.h, device.c (device_find_ihandle_runtime_property): New
1282         function. Reverse of add_ihandle_runtime property.
1283         (device_init_runtime_properties): Use it.
1284         
1285         * device.c (find_property_entry): New function returns the
1286         internal property spec.
1287         (device_set_property): Use.
1288         (device_find_property): Use.
1289
1290 Tue Dec 10 10:12:44 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1291
1292         * psim.c (psim_merge_device_file): Strip newline from device
1293         specs.
1294         
1295 Tue Dec 10 10:12:44 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1296
1297         * hw_htab.c (htab_map_binary): For overlapping text / data maps
1298         merge the two.  Also check that the merge is safe.
1299
1300         * emul_chirp.c (emul_chirp_create): Add a description property to
1301         the pte's so that they are easier to identify.
1302         
1303         (emul_chirp_create): Don't specify a load address for the CHRP
1304         image.  Always use the values specified by the executable.
1305
1306         * hw_htab.c (htab_map_page): Abort if a duplicate map is
1307         encountered.
1308
1309 Mon Dec  9 12:08:46 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1310
1311         * hw_htab.c (htab_map_page): Formatting.
1312
1313         * emul_chirp.c (emul_chirp_instruction_call): Check for a NULL
1314         method name when handling the client call. Also check for other
1315         bad call arguments.
1316         
1317         * emul_chirp.c (emul_chirp_create): Allow real-mode?, real-base,
1318         etc to be overriden.
1319
1320 Mon Dec  9 12:08:46 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1321
1322         * os_emul.c (os_emul_create): Use tree find property instead of
1323         device find property - sigh.
1324
1325 Thu Dec  5 10:46:42 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1326
1327         * 961205: Release snapshot 961205.
1328         
1329 Thu Dec  5 10:46:42 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1330
1331         * configure.in (hostbitsize, bitsize): Fix typo in error message -
1332         cannot contain a comma.
1333         (sim-warnings): Check for more potential errors.
1334
1335         * psim.c (psim_usage): Add -f <file> option.  Specifies a file
1336         containing device tree specifications that should be merged into
1337         the device tree.
1338
1339         * configure.in: Sort options.
1340         * configure: Rebuild
1341         
1342 Wed Dec  4 13:57:31 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1343
1344         * psim.c (psim_usage): Add -n option - specify number of
1345         processors.
1346
1347         * emul_chirp.c: Add description.
1348         * emul_bugapi.c: Ditto.
1349         * emul_unix.c: Ditto.
1350         * emul_netbsd.c: Ditto.
1351
1352 Fri Nov 29 11:12:22 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1353
1354         * hw_pal.c (hw_pal_attach_address): New function, if an attach is
1355         encountered, assume that it is the single disk.
1356         * hw_pal.c: Add generic device/size decode methods.
1357         
1358         * hw_nvram.c (hw_nvram_init_address): Use the first nonzero reg
1359         property entry when determining the nvram size.
1360
1361         * hw_core.c: Add generic address/size decode methods.
1362
1363         * emul_chirp.c (emul_chirp_instruction_call): Return and trace
1364         nonzero status from client functions.
1365
1366         * main.c (error): Always include a cariage return when writing out
1367         errors.
1368
1369 Wed Nov 20 00:36:55 1996  Doug Evans  <dje@canuck.cygnus.com>
1370
1371         * sim_calls.c (sim_resume): Reset sim_should_run if single
1372         stepping.
1373
1374 Thu Nov 28 13:19:46 1996  Andrew Cagney  <cagney@kremvax.tpgi.com.au>
1375
1376         * emul_bugapi.c (emul_bugapi_do_diskio): Add support for multiple
1377         optional disks.
1378
1379         * emul_generic.c (emul_add_tree_hardware): Drop the dummy eeprom.
1380         Attach the pal - for I/O - as a pseudo device haning from the
1381         firmware sub tree.
1382
1383         * emul_bugapi.c (emul_bugapi_create): Add a small memory device to
1384         the device tree at the address of the hi-mem interrupt vector
1385         addreses.  Used by bugapi to establish its trap instructions.
1386         
1387         * debug.h: Add a new macro DITRACE for tracing device instances.
1388         
1389         * debug.h: Extend the DTRACE macro so that it can also tests for
1390         device specific tracint.
1391         
1392         * device.h, device.c (device_trace): Add method to determine
1393         device specific tracing.
1394         (device_init_address): Set the devices tracing level.
1395         
1396 Thu Nov 21 12:05:32 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1397
1398         * tree.h, tree.c (tree_device): New files - separate out the
1399         device parser and other tree operations from the device.
1400         
1401         * inline.h, inline.c (INLINE_TREE): Add.
1402         * device.h, device.c (device_tree_add_parsed): Delete.
1403         * Makefile.in (tree.c): Add rules for new file.
1404         * Makefile.in: Better order the emul_* files.
1405         
1406         * emul_generic.c (emul_add_tree_hardware): Update.
1407         * emul_netbsd.c (emul_netbsd_create): Update.
1408         * emul_unix.c (emul_unix_create): Ditto.
1409         * emul_chirp.c (emul_chirp_create): Ditto.
1410         * emul_bugapi.c (emul_bugapi_create): Ditto.
1411         * psim.c (psim_tree): Ditto.
1412         * hw_init.c: Ditto.
1413         
1414         * emul_generic.h: Include tree.h
1415         * Makefile.in: Add to EMUL_GENERIC_H dependencies.
1416         
1417         * device.h, device.c (device_root): New function - returns the
1418         root of the tree.
1419         * corefile.c: Use.
1420         
1421         * device.h, device.c (device_clean): New function, clean up device
1422         ready for next simulation run. This includes things like deleting
1423         interrupt edges and properties created during the simulation and
1424         also scrubbing any pre-defined properties.
1425         * tree.c (tree_init): Use.
1426         
1427         * device.h, device.c (device_init_static_properties): New
1428         function.  Initialize any static predefined properties.  By static
1429         we mean those that have values that can be determined before the
1430         device tree initialization has started.
1431         * tree.c (tree_init): Use.
1432
1433         * device.h, device.c (device_init_address): Add code to
1434         check/verify the devices #address-cells and #size-cells.
1435         (device_add_integer_property): Delete corresponding code.
1436         (device_nr_address_cells, device_nr_data_cells): Check for
1437         property when returning value.
1438         
1439         * device.h, device.c (device_init_runtime_properties): New
1440         function.  Initialize those properties that are not `static'.  At
1441         present the only such property is the ihandle.
1442         * tree.c (tree_init): Use.
1443         
1444         * device.h, device.c (reg, ranges): Rework these so that they use
1445         an array of the fundamental type - single reg or single range
1446         entry.
1447         
1448         * device.h, device.c (device_add_ihandle_runtime_property):
1449         Re-implement the adding of an ihandle during tree construction so
1450         that it better fits in with device initialization.
1451         
1452 Thu Nov 21 12:05:32 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1453
1454         * device.h, device.c (device_ioctl): Add additional argument -
1455         request - so that the caller must always specify the type of
1456         the ioctl request.
1457
1458         * device_table.h: Update.
1459         * hw_trace.c (hw_trace_ioctl): Ditto.
1460         * hw_vm.c (hw_vm_ioctl_callback): Ditto.
1461         * hw_init.c (hw_stack_ioctl_callback): Ditto.
1462         * psim.c (psim_options): Ditto.
1463         
1464 Thu Nov 21 12:05:32 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1465         
1466         * BUGS: Updated a bit.
1467
1468 Wed Nov 20 14:06:37 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1469
1470         * hw_opic.c: Finish - third round.
1471
1472 Wed Nov 20 12:02:08 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1473
1474         * hw_glue.c (hw_glue_io_read_buffer_callback): Fix miscalc of glue
1475         reg index.
1476         (hw_glue_io_write_buffer_callback): Ditto.
1477
1478 Tue Nov 19 21:17:08 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1479
1480         * events.c (event_queue_process): Was incorrectly consuming future
1481         events on the queue when they should be left alone.
1482
1483         * debug.h, debug.c (events): Add support for event queue tracing.
1484         * events.c: Add event tracing.
1485         
1486         * debug.h, debug.c: Order device trace options.
1487         
1488 Fri Nov 15 15:23:39 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
1489
1490         * pk_disklabel.c (pk_disklabel_create_instance): Fix up some
1491         warnings generated by GCC.
1492
1493 Sun Nov 17 17:59:14 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1494
1495         * sim-endian.h: Add LE versions of byte swap macros.  Needed for
1496         PCI devices which are little-endian.
1497         
1498         * sim-endian-n.h (endian_le2h_N, endian_h2le_N): Ditto
1499
1500 Sun Nov 17 17:59:14 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1501
1502         * hw_iobus.c (hw_iobus_attach_address_callback): Change the iobus
1503         so that it is implementing a 1-1 address map.
1504         
1505         * emul_generic.c (emul_add_tree_hardware): Adjust.
1506
1507         * emul_generic.c (emul_add_tree_hardware): Don't add the nvram as
1508         a default.
1509
1510 Sun Nov 17 17:59:14 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1511         
1512         * device.c (split_find_device): Be tolerant of missing unit
1513         addresses.
1514
1515 Fri Nov 15 16:49:49 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1516
1517         * basics.h (port_direction): New type, specify the direction of
1518         any `port'.
1519         
1520         * device.h, device.c (device_interrupt_decode): Include
1521         specification of port direction in operations.
1522         (device_interrupt_encode): Ditto.
1523         
1524         * device_table.h: Add a direction field to the interrupt port
1525         table.
1526
1527         * device.c (device_tree_add_parsed): Specify port direction.
1528         
1529 Thu Nov 14 21:38:13 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1530
1531         * hw_opic.c: Finish - second round.
1532
1533 Thu Nov  7 00:18:59 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1534
1535         * hw_htab.c (htab_init_data_callback): Allow the virtual-address
1536         to be specified as an array which allows 64bit addresses.
1537
1538         * device.c (device_find_integer_array_property): New function.
1539         Simplify the querying of elements of an integer array.
1540         (device_add_integer_property, device_find_integer_property):
1541         Update to correctly use the cell type.
1542
1543         * vm.c (om_unpack_sr): Clarify shifting comment.
1544         (om_pte_0_masked_vsid): Ditto. Add 64bit version.
1545
1546         * emul_chirp.c (emul_chirp_create): Initialize the segment
1547         registers.
1548
1549         * vm.c (om_effective_to_virtual): Trace segment register use.
1550
1551         * hw_htab.c (htab_map_page): Print out the pteg base address to
1552         simplify cross checking between vm and the htab.
1553         (htab_decode_hash_table): Use device_error instead of error.
1554         (htab_map_page): Ditto.
1555         (htab_dma_binary): Ditto.
1556         (htab_map_binary): Ditto.
1557         (htab_init_data_callback): Ditto.
1558
1559 Wed Nov  6 20:20:58 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1560
1561         * interrupts.h: Clarify what the optional instruction program
1562         interrupt is - a subset of illegal instruction program interrupt.
1563
1564         * interrupts.c (program_interrupt): For UEA mode, clarify what an
1565         optional instruction program interrupt is.
1566         (program_interrupt): For OEA mode, as per spec, generate an
1567         illegal instruction program interrupt when an optional instruction
1568         is encountered.
1569         
1570         * gen-semantics.c (print_semantic_body): Delete code
1571         differentiating between an unimplemented floating point and normal
1572         instruction.  Instead, such a case can be handled explicitly.
1573
1574         * ppc-instructions (store floating-point as integer word indexed):
1575         Mark as optional.
1576         (Floating Convert to Integer Doubleword): Make the floating point
1577         assist interrupt explicit.
1578         (Floating Convert To Integer Doubleword with round towards Zero):
1579         Ditto.
1580         (Floating Convert To Integer Word): Ditto
1581         (Move From FPSCR): Ditto.
1582         (Move to Condition Register from FPSCR): Ditto.
1583         (Move To FPSCR Fields): Ditto.
1584         (Move To FPSCR Field Immediate): Ditto.
1585         (Move To FPSCR Bit 0): Ditto.
1586         (Move To FPSCR Bit 1): Ditto.
1587         
1588 Mon Nov  4 12:49:13 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1589
1590         * corefile.c (core_map_read_buffer, core_map_write_buffer): Avoid
1591         breaking up transfers.
1592
1593         * corefile.c: Adjust arguments so that the client server
1594         relationship is clarified.
1595         
1596         * hw_glue.c (hw_glue_init_address): Update so it can be attached
1597         to a PCI bus.
1598
1599         * hw_disk.c (hw_disk_instance_write): Add more checks to disk IO -
1600         looking for things like overflow/underflow.
1601
1602 Sun Nov  3 18:45:20 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1603
1604         * emul_generic.c (emul_add_tree_hardware): Hang the disk off the
1605         PAL device instead of the IOBUS.  The disk must be attached to a
1606         logical bus.
1607
1608         * hw_disk.c (hw_disk_init_address): Just use the unit address
1609         directly in the attach - the rest isn't relevant.
1610
1611 Sat Nov  2 21:48:57 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1612
1613         * configure.in (sim-hardware, sim-packages): Allow additional
1614         hardware and packages to be prefixed as well as appended.
1615
1616         * Makefile.in (tmp-hw, tmp-pk): Retain the user specified order of
1617         packages when building them.  Consequently, a user can override a
1618         standard device by prefixing their own version.
1619         
1620         * Makefile.in (hw_opic.o, hw_pci.o, hw_ide.o): Add dependencies.
1621
1622 Fri Nov  1 14:42:57 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
1623
1624         * mon.c (_cpu_mon): Add fields for counting 1, 2, 4, and 8 byte
1625         reads and writes.
1626         (mon_{read,write}): Count 1, 2, 4, and 8 byte reads/writes.
1627         (mon_print_info): Correct typo regarding # of unaligned reads and
1628         writes.  Print out how many 1, 2, 4, and 8 byte reads/writes there
1629         are.
1630
1631 Tue Oct 29 17:55:43 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
1632
1633         * configure.in (AC_CHECK_FUNCS): Add access.
1634         * config{.in,ure}: Regenerate.
1635
1636         * emul_unix.c (do_unix_nop): System call that always succeeds.
1637         (do_unix_access): Support access system call.
1638         (solaris_descriptors): Make sigaltstack and sigaction nops.
1639         ({solaris,linux}_descriptors): Add support for access.
1640
1641 Tue, 8 Oct 18:42:26 1996  Jason Molenda <crash@cygnus.co.jp>
1642         
1643         * Makefile.in (clean): Move config.log to distclean.
1644
1645 Fri Nov  1 16:44:28 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1646
1647         * corefile-n.h (core_map_write_N): Improve abort messages.
1648
1649         * device.h, device.c (device_attach_address): Remove unused name
1650         parameter.
1651         (device_detach_address): Ditto.
1652         * device_table.h, device_table.c: Update.
1653         * hw_iobus.c (hw_iobus_attach_address_callback): Ditto.
1654         * hw_nvram.c (hw_nvram_init_address): Ditto.
1655         * hw_memory.c (hw_memory_init_address): Ditto.
1656         * hw_vm.c (hw_vm_init_address_callback): Ditto.
1657         (hw_vm_attach_address): Ditto.
1658         (hw_vm_add_space): Ditto.
1659         * hw_init.c (update_for_binary_section): Ditto.
1660         * hw_core.c (hw_core_attach_address_callback): Ditto.
1661
1662         * hw_iobus.c (hw_iobus_attach_address_callback): Rewrite to handle
1663         configurable parent busses.
1664
1665 Wed Oct 30 18:46:32 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1666
1667         * device_table.c (generic_device_size_to_attach_size): Provide
1668         limited support for multi-cell sizes.
1669         (generic_device_address_to_attach_address): Ditto for addresses.
1670
1671 Tue Oct 29 02:01:29 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1672
1673         * device.c (device_add_integer_property): Check for setting of
1674         #address-cells and #size-cells properties.  For these, update the
1675         corresponding device values.
1676         (device_nr_address_cells, device_nr_size_cells): Use the value
1677         from the device instead of the property.
1678
1679         * hw_core.c: Use generic address and size conversions for the top
1680         bus.
1681
1682         * hw_memory.c (hw_memory_init_address): Tolerate case where
1683         #address and #size cells is greater than 1.
1684
1685         * device.c (device_tree_print_device): Clean out printing of
1686         properties.
1687         
1688         * device.c (split_device_specifier): Don't detect comments here -
1689         "#" can be a valid prefix - eg #size-cells.
1690
1691         * psim.c (psim_merge_device_file): Suppress comments and blank
1692         lines here.
1693
1694         * emul_generic.c (emul_add_tree_hardware): Fix typo of incorrect
1695         pal unit address.  Add the property /#address-cells to the root of
1696         the tree.
1697
1698         * device.c (device_template_create_device): Check that the unit
1699         address was successfully parsed.
1700
1701         * device_table.c (generic_device_unit_decode): Rewrite to better
1702         handle multi-cell addresses.
1703         (generic_device_unit_encode): Ditto.
1704
1705         * emul_generic.c (emul_add_tree_hardware): "reg" properties no
1706         longer need the explicit array type - the parser takes care of it.
1707
1708         * pk_disklabel.c (pk_disklabel_create_instance): Add NULL return
1709         to keep GCC happy.
1710
1711 Mon Oct 28 22:55:48 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1712
1713         * hw_ide.c: New file.  Model of a basic IDE interface attached to
1714         a PCI bus.
1715         
1716         * configure.in (hardware): Add the ide device to the default
1717         configuration.
1718         * configure: Regenerate.
1719         
1720         * debug.h, debug.c: Add tracing option for the IDE device.
1721         
1722 Fri Oct 25 21:28:25 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1723
1724         * hw_phb.c, hw_phb.h: New files - implement a PHB.
1725
1726         * configure.in (hardware): Add the phb to the list of devices to
1727         build by default.
1728
1729 Fri Oct 25 21:28:25 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1730
1731         * hw_com.c: Review description.
1732         * hw_disk.c: Ditto.
1733         * hw_htab.c: Ditto.
1734         * hw_eeprom.c: Ditto.
1735         * hw_init.c: Ditto.
1736         * hw_cpu.c: Ditto.
1737         
1738         * hw_com.c: Update event handling.
1739
1740         * hw_disk.c: Implement tracing.
1741         
1742 Fri Oct 25 21:28:25 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1743
1744         * device_table.c (generic_device_init_address): Use
1745         assigned-addresses property in preference to any other reg
1746         property.
1747
1748 Fri Oct 25 21:28:25 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1749
1750         * device.h, device.c (device_find_ranges_property): New function.
1751         Simplify the manipulation of "ranges" properties.
1752         
1753         * device.c (device_add_parsed): Extend to include support for the
1754         ranges property.
1755
1756         * device.c (device_add_parsed): Add assigned-addresses to the list
1757         of reg type properties.
1758         
1759         * device.c (device_tree_print_device): Add code to format and
1760         print a ranges property.
1761         
1762         * device.h, device.c (device_nr_address_cells,
1763         device_nr_size_cells): New functions. Determine the values of the
1764         standard properties #address-cells and #size-cells.  Both of which
1765         are optional and have default values of two and one respectfuly.
1766         Previously, code that determined #address-cells was incorrectly
1767         using a value of one.
1768
1769 Fri Oct 25 21:28:25 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1770
1771         * debug.h, debug.c: Sort debug options, Add entries for the
1772         comming PHB device.
1773         
1774 Fri Oct 18 12:12:21 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
1775
1776         * ppc-instructions (Floating Select): Add support for fsel unless
1777         model is 601.  Allow user to filter out instruction unless -Fs is
1778         passed to igen.
1779         (Store Floating-Point as Integer Word Indexed): Raise optional
1780         instruction program abort.  Allow user to filter out instruction
1781         unless -Fs is passed to igen.
1782         (Floating Square Root{, Single}): Ditto.
1783         (Floating Reciprocal Estimate Single): Ditto.
1784         (Floating Reciprocal Square Root Estimate): Ditto.
1785
1786         * configure.in (--enable-sim-filter): If not passed, pass 32,f,s
1787         to igen.
1788         * configure: Regenerate.
1789
1790         * interrupts.h (program_interrupt_reasons): Add
1791         optional_instruction_program_interrupt.
1792
1793         * interrupts.c (program_interrupt): Call error with more detailed
1794         information on program interrupts, particularly in user mode.  Add
1795         support for optional_instruction_program_interrupt.
1796
1797 Wed Sep 25 10:20:29 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1798
1799         * hw_glue.c: New device.  Hooks for manipulating interrupt ports.
1800
1801         * debug.h, debug.c (trace_glue_device): Add tracing support for
1802         the interrupt glue logic device.
1803
1804         * configure.in (hardware): Add glue device.
1805         * configure: Regenerate.
1806
1807 Tue Sep 24 20:55:38 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1808
1809         * device.c (device_tree_parse_integer_property): New function,
1810         parse a list of integers as an array property.
1811         (device_tree_add_parsed): Call it.
1812
1813         * device.c (device_tree_parse_string_property): New function,
1814         parse a list of strings as a string property (with embeded
1815         null's).  For moment, don't try to implement a complext string
1816         parser.
1817         (device_tree_add_parsed): Call it.
1818
1819 Tue Sep 24 16:30:48 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1820
1821         * hw_opic.c: New file.  OpenPIC interrupt controller.
1822
1823         * configure.in (hardware): Add opic device.
1824         * configure: re-generate.
1825
1826         * hw_pic.c: Delete, replaced with hw_opic.c.
1827
1828         * debug.h, debug.c: Add debug option for OpenPIC device. -
1829         opic-device.
1830
1831 Tue Sep 24 16:30:48 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1832
1833         * Makefile.in (psim.o, idecode.o): Since idecode and not psim is
1834         now the file that does all the inlining.
1835
1836         * Makefile.in (LIB_SRC, LIB_INLINE_SRC, idecode.o): Break out the
1837         library source code that could be involved in an inlining.  Make
1838         idecode.o only dependant on the inlined library source code.
1839
1840         * Makefile.in (LIB_OBJ): Put options last on the list so that it
1841         is compiled last.
1842
1843         * std-config.h (DEVICE_INLINE): Only inline locals when the
1844         default is to inline.
1845
1846 Mon Sep 23 00:37:49 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1847
1848         * hw_htab.c (htab_sum_binary): Determine the real-base for the
1849         binary.
1850
1851         * hw_htab.c (htab_map_binary): Depending on the value of the
1852         load-base, either map the program in as a contiguous section or as
1853         separate sections controled by th binaries lma values.
1854         (htab_init_data_callback): Ditto.
1855
1856 Sun Sep 22 15:56:22 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1857
1858         * emul_generic.c (emul_add_tree_options): Remove load-base option.
1859
1860         * emul_chirp.c (map_over_chirp_note): Add load_base field to note
1861         struct.  Don't require the load_base field to be present - just
1862         issue warning - it is a recent addition.
1863         (emul_chirp_create): Support both virtual and physical modes.
1864
1865         * emul_chirp.c (emul_chirp_create): Add a stack initialization
1866         property so that any arguments specified on the command line can
1867         be passed on to user programs.
1868
1869         * hw_init.c (create_ppc_chirp_bootargs): Add support for chirp
1870         argument passing to the pseudo device stack.
1871
1872 Sat Sep 21 19:39:56 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1873
1874         * device.c (device_error): Make it more tolerant to incomplete
1875         devices.
1876
1877         * hw_init.c (hw_data_init_data_callback): Extend the data device
1878         so that it can perform initialization operations either dma or a
1879         more complex instance open, seek, write operation.
1880         * hw_init.c: Update the description of the data device to reflect
1881         this.
1882
1883 Sat Sep 21 00:13:02 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1884
1885         * device.c (device_event_queue_schedule,
1886         device_event_queue_deschedule, device_event_queue_time): Have the
1887         device object export the event operations.  Making these available
1888         from the device object should hopefully simplify writing device
1889         models.
1890
1891 Fri Sep 20 14:04:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1892
1893         * configure.in (sim-hardware): Add eeprom device to default build.
1894
1895         * hw_eeprom.c: Rewrite so it works.
1896
1897         * debug.h, debug.c: Add tracing support for the eeprom and com
1898         devices.
1899
1900 Thu Sep 19 14:40:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1901
1902         * debug.h: Add disklabel-package and disk-device trace options.
1903         debug.h (PTRACE): Add macro to simplify tracing in packages.
1904
1905 Thu Sep 19 14:40:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1906
1907         * device.c (device_create_instance_from): Tighten up loop
1908         searching for device instances.
1909         (device_instance_delete): Ditto.
1910         (device_instance_delete): Only leaf instances need to be removed
1911         from a devices list of active instances.
1912
1913 Thu Sep 19 14:40:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1914
1915         * hw_disk.c: Add the cdrom as an alias.
1916
1917         * pk_disklabel.c (disklabel_delete): Implement, remembering to
1918         delete the raw disk instance while we're at it.
1919
1920         * pk_disklabel.c (pk_disklabel_create_instance): Implement a
1921         little bit more - still a long way to go.
1922
1923         * pk_disklabel.c (disklabel_write, disklabel_read): Remember the
1924         new head position after a read or write.
1925
1926 Thu Sep 19 13:05:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1927
1928         * emul_chirp.c (chirp_emul_read): Allow reads to be longer then
1929         the internal buffer.
1930
1931 Thu Sep 19 13:05:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1932
1933         * emul_chirp.c (chirp_read_t2h_args): Call memset-0 with the args
1934         in the correct order.
1935
1936         * emul_chirp.c (chirp_emul_call_method): Correct computation for
1937         the address of the first stack argument passed in from the client
1938         program.
1939
1940 Wed Sep 18 19:33:54 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1941
1942         * words.h: Add new types signed_cell and unsigned_cell which
1943         correspond to the signed and unsigned IEEE 1275 memory locations.
1944         * device.h, device.c, emul_chirp.c: Where refering to an IEEE 1275
1945         memory cell, replace uses of unsigned32 with unsigned_cell.
1946         * device_table.h: Ditto.
1947
1948         * sim-endian.h: Add new macros H2BE_cell and BE2H_cell which
1949         convert cell sized values to from big endian.
1950         * device.c, emul_chirp.c: Where refering to IEEE 1275 memory cells
1951         use these new macros.
1952
1953 Tue Sep 17 15:57:44 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1954
1955         * device.c (device_tree_add_parsed): Detect and report an
1956         interrupt being attached to an invalid device. Was dumping core.
1957
1958 Mon Sep 16 23:09:12 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1959
1960         * device.h, device.c (device_address_to_attach_address,
1961         device_size_to_attach_size): New functions.  Convert a devices
1962         unit address or unit size structure into a form suitable for
1963         passing on to the attach and detach functions.
1964         * device_table.h: Add extra methods to device table.
1965
1966         * device.h, device.c (device_find_reg_property): New function.
1967         For a reg type property, return the selected address + size
1968         tupple, along with a positive success status.  Add a reg_property
1969         to the list of property types.
1970         * (device_tree_add_parsed): Make array properties with the name
1971         reg or alternate-reg of type reg_property.
1972
1973         * hw_memory.c (hw_memory_init_address): Rewrite to use new
1974         find_reg_property method.
1975         * hw_nvram.c (hw_nvram_init_address): Ditto.
1976
1977         * device.c (device_tree_print_device): Add code to print out a reg
1978         property.
1979
1980         * device_table.c (generic_device_address_to_attach_address,
1981         generic_device_size_to_attach_size ): New functions.  Generic
1982         functions for converting between unit and attach address or size.
1983
1984         * device_table.c (generic_device_init_address): Rewrite to use the
1985         new find_reg and address convert functions.  Look for both reg and
1986         alternate-reg properties.
1987
1988 Mon Sep 16 23:09:12 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1989
1990         * hw_com.c: New file.  A '550 serial device that can quickly be
1991         attached to any bus.
1992         * configure.in (enable-sim-hardware): Add the com device.
1993         * configure: re-generate.
1994
1995 Thu Sep 12 17:30:56 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
1996
1997         * device.c (device_tree_verify_reg_unit_address): New
1998         function. Check that the unit address as specified by the reg
1999         property correctly corresponds to any unit address previously
2000         specified by the devices name.
2001         (device_tree_add_parsed): When adding a reg property, verify
2002         that the unit-address - first value of property - correctly
2003         matches any previous value specified when creating the device
2004         node.
2005
2006 Thu Sep 12 17:30:56 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2007
2008         * mon.c (mon_event): Remove assertion that an unsigned is >= 0.
2009
2010 Fri Aug 16 12:05:24 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2011
2012         * device.c (device_full_name): Cast strdup to char *, since AIX
2013         3.2.5 mistakenly declares the function to be const char *.
2014         (device_create_from): Ditto.
2015         (device_create_instance_from): Ditto.
2016         (device_add_property): Ditto.
2017
2018 Tue Aug 13 11:40:14 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2019
2020         * debug.c (trace_option): For -t all, do not set the
2021         trace_dump_device_tree flag, so that the simulator is run.
2022
2023 Tue Aug 13 11:40:14 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2024
2025         * Makefile.in (options.o): Depend on defines.h.
2026         (defines.h): New rule, go through config.h and make strings of all
2027         of the #define HAVE_xxx macros.
2028         (distclean): Remove defines.h.
2029
2030         * options.c (print_options): Print whether many of the
2031         configuration macros are defined.
2032
2033         * main.c (main): If -t options and no filename, just print the
2034         options, and don't print the usage message.
2035
2036 Mon Aug 12 18:42:37 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2037
2038         * configure.in: Test whether /dev/zero works on the system, and if
2039         it does, define HAVE_DEVZERO.
2040         * configure: Regenerate.
2041
2042         * emul_generic.c (emul_add_tree_hardware): Do not add /iobus/disk
2043         if we don't have a working /dev/zero on the system.
2044
2045         * emul_bugapi.c (emul_bugapi_init): If HAVE_DEVZERO is not
2046         defined, don't add disk support.
2047         (emul_bugapi_do_diskio): Ditto.
2048         (emul_bugapi_instruction_call): Ditto.
2049
2050 Wed Aug  7 14:34:20 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2051
2052         * emul_unix.c (HAVE_TCGETATTR): If HAVE_TERMIOS_STRUCTURE is not
2053         defined, make sure HAVE_TCGETATTR is #undef'ed
2054
2055 Wed Aug  7 14:34:20 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2056
2057         * std-config.h (REGPARM): Only define REGPARM attributes if using
2058         GNU C.  Test for __i686__ in case GCC ever defines it.  If not on
2059         a x86 platform, define REGPARM as nothing.
2060
2061         * sim-endian.h (WITH_HOST_BYTE_ORDER): Test for i686 and __i686__
2062         also.
2063
2064 Wed Aug  7 20:19:55 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2065
2066         * ld-decode.h, ld-decode.c: Rename goto_gen to the more correct
2067         goto_switch_gen.
2068         * gen-idecode.c: Ditto.
2069
2070         * gen-idecode.c (print_idecode_table): Comment out check for
2071         switch/table combination until a bug with it is fixed.
2072
2073         * ppc-opcode-goto: New file.  Like complex and flat but uses
2074         goto-switch instead of padded-switch for the tables.
2075
2076         * gen-idecode.c (print_goto_switch_name): New function.
2077         (print_goto_switch_table_leaf): New function.
2078         (print_goto_switch_break): New function.
2079         (print_goto_switch_table): New function. Prints a jump table
2080         that can be jumped into instead of a switch statement.
2081
2082         * gen-idecode.c (*switch_*): As an option output a switch that is
2083         implemented using a jump table but only if the switch is not
2084         boolean.
2085         
2086 Tue Aug  6 09:28:22 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2087
2088         * configure.in (--enable-sim-{hardware,packages}): Fix typos.
2089         * configure: Regenerate.
2090
2091         * device.c (device_instance_call_method): Fixup format message in
2092         error case.  Return 0 in case of error to shut up compiler
2093         warnings.
2094
2095 Wed Aug  7 00:17:37 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2096
2097         * device_table.c (generic_device_unit_decode): Require a comma
2098         between elements of a unit address.
2099
2100         * device.c (device_tree_print_device): For reg, alternate-reg and
2101         ranges properties use special print functions.
2102         (device_print_ranges_property): Print formatted ranges property.
2103         (device_print_reg_property): Print formatted reg property.
2104
2105 Tue Aug  6 21:35:18 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2106
2107         * device.c (device_tree_add_parsed): For reg, ranges and
2108         alternate-reg properties use a special parser.
2109         (device_tree_parse_reg_property): New function to parse a reg
2110         property.
2111         (device_tree_parse_ranges_property): New function to parse a
2112         ranges property.
2113         (device_encode_unit): Wrapper for encode_unit callback.
2114         (device_decoce_unit): Wrapper for decode_unit callback.
2115
2116 Wed Jul 31 00:02:30 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2117
2118         * device_table.h (device_instance_callbacks): Relace the claim and
2119         release methods with a more general table mapping from method-name
2120         to method-function.
2121
2122         * device.c (device_instance_call_method): New function.  Implement
2123         the OpenBoot call-method client interface.  Attempts to locate the
2124         instances method in the callback table.
2125         (device_instance_claim, device_instance_release): Delete.
2126         Replaced with call-method and a lookup table.
2127
2128         * emul_chirp.c (chirp_emul_call_method): Use the new device
2129         instance call method and let that handle a client claim call.
2130
2131         * hw_htab.c (claim_memory): Wrapper function to call the memory
2132         devices "claim" method using the new device-instance call-method
2133         interface.  Replaces the previous direct calls to claim.
2134         (htab_map_region): Use claim_memory.
2135         (htab_init_data_callback): Ditto.
2136
2137         * hw_memory.c (hw_memory_instance_claim): Update function
2138         interface so that it is compatible with call-method.
2139         (hw_memory_instance_release): Ditto.
2140         (hw_memory_instance_methods): New table of memory specific
2141         methods claim and release.  Add to the hw_memory_callback
2142         table.
2143
2144 Tue Jul 30 21:26:14 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2145
2146         * psim.c (psim_init): Back out of change to initial value of
2147         system->last_cpu.
2148
2149 Tue Jul 30 21:12:24 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2150
2151         * sim_callbacks.h (sim_io_printf_filtered): Replace
2152         printf_filtered with a local simulator specific version.  Add
2153         #define printf_filtered to simplify updating of existing code.
2154
2155         * sim_callbacks.h (sim_io_write_stdout, sim_io_read_stdin,
2156         sim_io_write_stderr): New functions.  Read / write to the
2157         simulations stdin and stdout and stderr interfaces.  Merge in code
2158         from hw_pal that previously handled async I/O.
2159         (sim_io_flush_stdoutput): Rename flush_stdoutput.  Add #define
2160         flush_stdoutput to simplify updating of existing code.
2161
2162         * hw_pal.c (scan_hw_pal, write_hw_pal,
2163         hw_pal_instance_write_callback): Use the new sim_io functions.
2164
2165         * main.c: Implement standalone versions of the new sim_io
2166         functions.  Include support for async I/O.
2167         * sim_calls.c: Ditto.  This time using the gdb callback table.
2168
2169         * std-config.h (CURRENT_STDIO, current_stdio): New macro. Set up
2170         stdio configuration so that it works in the same way as the rest
2171         of the simulation.
2172         * psim.c (psim_create): Initialize current_stdio from the device
2173         tree.
2174         * emul_generic.c (emul_add_tree_options): Enter a default value
2175         for use-stdio in the device tree.
2176
2177 Fri Jul 26 19:43:03 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2178
2179         * gen-idecode.c (print_jump): Was always generating a jump back to
2180         idecode.  Only necessary at tail of semantic code.
2181         (print_jump): Was always setting the processor's cia, even during
2182         startup when the processor was still undefined.
2183         (print_jump): For safety, restart smp loop when cpu_nr >= nr_cpus,
2184         not just equal.
2185         
2186         * options.c (print_options): Add printing of WITH_REGPARM and
2187         WITH_STDCALL.
2188
2189         * std-config.h (WITH_REGPARM, WITH_STDCALL): Provide default
2190         (disabled) values if not defined.
2191
2192 Fri Jul 26 00:36:35 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2193
2194         * ppc-cache-rules (cache): Change RS and RB to cache instead of
2195         compute.  The block move instructions use them.
2196
2197         * idecode_expression.h (FPSCR_SET): New macro, set specific FPSCR
2198         register.
2199         (CR_FIELD): New macro, extract specific CR register.
2200         (FPSCR_FIELD): New macro, extract specific FPSCR register.
2201
2202         * registers.h (GPR): New macro, simplify accesses to GPR[i].
2203
2204         * bits.c (INSERTED): Covert INSERTED macro into a function.
2205         (EXTRACTED): Conditionally compile on correct bit size macro.
2206
2207         * bits.h (BIT8): New macro, set a single bit in an 8 bit byte.
2208
2209         * ppc-instructions: With hints from Paul Martin, type in missing
2210         some instruction semantics.  Leave disabled for the moment.
2211         (Load Multiple Word): Ditto.
2212         (Store Multiple Word): Ditto.
2213         (Load String Word Immediate): Ditto.
2214         (Load String Word Indexed): Ditto.
2215         (Store String Word Immedate): Ditto.
2216         (Store String Word Indexed): Ditto.
2217         (Move to Condition Register from XER): Ditto.
2218         (Move From Condition Register): Ditto.
2219         (Move From FPSCR): Ditto.
2220         (Move to Condition Register from FPSCR): Ditto.
2221         (Move To FPSCR Field Immediate): Ditto.
2222         (Move To FPSCR Fields): Ditto.
2223         (Move To FPSCR Bit 0): Ditto.
2224         (Move To FPSCR Bit 1): Ditto.
2225
2226 Thu Jul 25 22:10:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2227
2228         * std-config.h (SEMANTICS_INLINE): By default, mask out the
2229         inlining of semantic functions from DEFAULT_INLINE.  Almost all
2230         configurations call the semantic code via a pointer so there is
2231         little benefit.
2232
2233         * std-config.h (ICACHE_INLINE): Ditto.
2234
2235 Thu Jul 25 20:07:30 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2236
2237         * configure.in (sim_regparm): Add configuration option for
2238         enabling GCC's regparm attribute.
2239         * (sim_stdcall): Add configuration option for enabling GCC's
2240         stdcall attribute.
2241
2242         * Makefile.in (REGPARM_CFLAGS): Pass regparam configuration onto
2243         compilations.
2244         * (STDCALL_CFLAGS): Pass stdcall configuration onto compilations.
2245
2246         * std-config.h (REGPARM): Extend construction of REGPARM macro so
2247         that it can include __stdcall__ function attribute.
2248
2249 Wed Jul 24 19:04:20 1996  Andrew Cagney  <cagney@sawnoff>
2250
2251         * options.c (print_options): Include SUPPORT_INLINE in information
2252         dump.
2253
2254         * gen-idecode.c (print_run_until_stop_body): Only generate loop
2255         termination test if creating idecode_run_until_stop.  Push the
2256         loop termination test back into each alternative branch.
2257
2258 Wed Jul 24 15:47:09 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2259
2260         * gen-icache.c (print_icache_function): Have the cache function
2261         always update the cache_entries semantic and address fields.
2262
2263         * gen-idecode.c (print_idecode_switch_illegal): Include a break
2264         when generating illegal instructions.  This was commented out
2265         which is a hangover from looking a at switch statements generated
2266         using indirect jumps.
2267
2268 Tue Jul 23 20:57:01 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2269
2270         * igen.c (print_my_defines): Replaces print_define_my_index.
2271         Print both a definition for MY_INDEX and MY_PREFIX.
2272         * gen-icache.c (print_icache_function): Adjust.
2273         * gen-idecode.c (print_jump_insn): Adjust.
2274         * gen-semantics.c (print_c_semantic): Adjust.
2275
2276         * gen-support.c (gen_support_h): Add optional include to created
2277         support.h so that, like cpu, it is optionally inlined for all
2278         modules that include it.
2279         * inline.h, inline.c: Adjust so that support.[hc] is handled the
2280         same as cpu.[hc].
2281
2282         * idecode_fields.h (LABEL, GOTO): Macro's that create a unique
2283         name for a lable and then branch to it.
2284
2285         * ppc-instructions (convert_to_integer, Floating Round to
2286         Single-Precision, Floating Convert from Integer Doubleword): Use
2287         LABEL and GOTO instead of the recently added switch statements.
2288
2289 Wed Jul 24 14:02:42 1996  Andrew Cagney  <cagney@sawnoff.highland.com.au>
2290
2291         * gen-idecode.c (print_run_until_stop_body): Too many rparen in
2292         generated code.
2293
2294 Tue Jul 23 20:57:01 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2295
2296         * configure.in (--enable-sim-line-nr): Typo - sim_line-nr.
2297         * (--enable-sim-inline): Reorder patern matching of arguments so
2298         that SUPPORT=ALL_INLINE is reconized as *=* and not *_INLINE.
2299
2300         * configure: rebuild.
2301
2302 Mon Jul 22 23:25:08 1996  Andrew Cagney  <cagney@highland.com.au>
2303
2304         * configure.in (--enable-sim-hardware, --enable-sim-packages): New
2305         configuration options.  Let the user specify the packages or
2306         hardware devices that are to be included in the build.  Makes it
2307         possible for user packages to be specified.
2308
2309         * Makefile.in (tmp-pk, tmp-hw): Just use the list of packages and
2310         hardware instead of checking it using ls.  configure.in should
2311         have taken care of any problems.
2312         (HW_SRC, HW_OBJ, PACKAGE_SRC, PACKAGE_OBJ): Set by configure.
2313
2314 Mon Jul 22 22:38:59 1996  Andrew Cagney  <cagney@highland.com.au>
2315
2316         * psim.c (psim_options): Enter the argument to the memory size
2317         option directly into the device tree.  Was using atol() which is
2318         dangerously non portable.
2319
2320 Mon Jul 22 22:17:08 1996  Andrew Cagney  <cagney@highland.com.au>
2321
2322         * configure.in (icache): Extend icache flag to include an insn
2323         option.  If specifyed the insn - aka instruction - is included in
2324         the instruction cache.  Make this the default.
2325         * configure: re-generate.
2326
2327         * igen.c (main), igen.h: Add option -S - inSn - for specifying
2328         that the instruction should be included in the icache.
2329
2330         * gen-icache.c (print_icache_body): If enabled, output code to put
2331         the instruction into the icache.
2332         (print_icache_struct): If enabled, add insn to the icache struct.
2333
2334 Mon Jul 22 20:46:12 1996  Andrew Cagney  <cagney@highland.com.au>
2335
2336         * Makefile.in (BUILD_CFLAGS): Include -g when building the
2337         generators.
2338
2339 Mon Jul 22 20:00:25 1996  Andrew Cagney  <cagney@highland.com.au>
2340
2341         * emul_generic.c (emul_add_tree_options): Was incorrectly setting
2342         the strict-alignment option when hardwired for non-strict
2343         alignment.
2344
2345 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2346
2347         * gen-semantics.c: Make the my_index variable a macro MY_INDEX.
2348
2349         * ppc-instructions: Adjust so that references are to MY_INDEX and
2350         not my_index.
2351
2352 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2353
2354         * gen-idecode.c: Output the complete run_until_stop function
2355         instead of just the code to handle a single instruction issue.
2356         * : Have the generated idecode.c include inline.c (instead of psim.c).
2357
2358         * std-config.h: Change psim.c so that it isn't inlined (as this is
2359         no longer needed).
2360
2361         * psim.c (run_until_stop): Delete the old run_until_stop function
2362         instead calling the idecode_run and idecode_run_until_stop
2363         functions that gen-idecode.c is now creating.
2364
2365 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2366
2367         * dgen.c: Maintenance - update to use new features found in lf.c.
2368
2369         * filter_filename.c (filter_filename): Maintenance - make the
2370         string constant.
2371
2372 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2373
2374         * debug.c (TRACE, ITRACE, DTRACE): Have GCC instead of CPP
2375         eliminate trace statements.
2376
2377         * debug.c: Change trace format so that it is consistent
2378         (file:line-nr) with CC's error output.
2379
2380         * gen-itable.c (itable_c_insn): Add the source file name and
2381         source line number to the instruction's informational entry.
2382
2383         * debug.c (ITRACE): Use the itable (and my_index) to get the
2384         current instructions name and source line number.
2385
2386         * gen-semantics.c, gen-icache.c: Adjust generated ITRACE calls to
2387         match new interface.
2388
2389         * emul_bugapi.c (emul_bugapi_instruction_call): Adjust
2390         corresponding call to ITRACE so that it still matches.
2391
2392         * idecode_expression.h (ALU_END, CR0_COMPARE): Use TRACE instead
2393         of ITRACE.  The CPP line directives would have previously set the
2394         line-nr and file name so ITRACE isn't needed.
2395
2396 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2397
2398         * gen-idecode.c (print_jump_until_stop_body): New function and
2399         idecode generation option.  Instead of generating and calling
2400         separate functions containing the semantic and icache code
2401         generate a single monolythic function and use goto's (and GCC's
2402         indirect jump) to move between code blocks.
2403
2404         * Makefile.in: Add sim_jump flag to those passed to igen.
2405
2406         * configure.in: New option --enable-sim-jump (default disabled)
2407
2408         * ppc-instructions: Eliminate any uses of labels and goto's.
2409         These result in duplicate declarations when a single flat function
2410         is being create.
2411
2412         * ppc-opcode-jump: New file.  Set of opcode rules useful when
2413         testing jumping idecodes.
2414
2415 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2416
2417         * gen-idecode.c: Optionally include the semantic code for an
2418         instruction in the function that is doing the decoding.
2419
2420         * igen.c: Add option (-C) to generate semantics in the instruction
2421         decode functions.
2422
2423         * configure.in (--enable-sim-icache): Accept an option list such
2424         as 1024,define.  Add a new choice to the list - semantic - which
2425         will cause igen to generate instruction decode functions that
2426         include the corresponding semantic code.
2427
2428 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2429
2430         * configure.in: New option --enable-sim-line-nr (default enabled).
2431         Enable/disable the inclusion of CPP line directives in the
2432         generated files.  Such directives refer back to the source files
2433         used when generating the simulator code.
2434
2435         * Makefile.in (sim_line_nr): Pass to igen.
2436
2437 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2438
2439         * igen.c (main): Revamp the options so that more letters are
2440         available.
2441
2442         * configure.in: Adjust to match igen's revamped options
2443
2444 Sun Jul 21 21:18:05 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2445
2446         * Makefile.in (pk.h, hw.h): Rewrite depenencies for hw.h (etc) so
2447         that they use the same technique as igen (ie a dummy targets
2448         tmp-pk and tmp-hw are created).
2449
2450 Mon Jun 24 22:28:00 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2451
2452         * Makefile.in (BUILD_CFLAGS): Include WARNING_CFLAGS.
2453
2454 Wed Jun 19 21:45:28 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2455
2456         * ld-cache.[hc], ld-decode.[hc], ld-insn.[hc]: New files. Separate
2457         out the loading of each of the tables from the rest of igen.
2458         * Makefile.in: Adjust.
2459         * igen.c: Adjust.
2460
2461         * gen-icache.[hc], gen-idecode.[hc], gen-itable.[hc],
2462         gen-model.[hc], gen-semantics.[hc]: New files. Separate out the
2463         code creating each separate set of generated files.
2464         * Makefile.in: Adjust.
2465         * igen.c: Adjust.
2466
2467         * gen-support.[ch]: New files. Output the support functions (found
2468         in the ppc-instructions file) into a separate file.
2469         * Makefile.in: Add.
2470         * inline.h, inline.c: Add.
2471         * std-config.h: Add.
2472
2473         * ld-cache.c: Re-design the cache table format.
2474         * ppc-cache-rules: Update to new format.
2475
2476         * ld-decode.c: Re-design the decode table format.
2477         * ppc-opcode-simple: Update to new format
2478         * ppc-opcode-complex: Ditto
2479         * ppc-opcode-flat: Ditto
2480
2481         * filter.h, filter.c: New files. Separate the opcode filter table
2482         reading code from the rest of igen.c.  Re-design the filter so that
2483         it works inclusivly not exclusivly.
2484         * igen.c: Remove the opcode filter table loading code.
2485         * Makefile.in (filter.o): Adjust
2486         * configure.in: Adjust filter flag so that default includes 32bit
2487         and floating point.
2488         * ppc-instructions: Clean up filter fields so that only in use
2489         entries are specifed (ie delete `be').
2490
2491         * misc.c (name2i, i2name): New function.  Map between a string and
2492         an integer value.
2493
2494 Mon Jun 17 20:08:03 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2495
2496         * sim_calls.c (sim_close): If simulator not created, skip printing
2497         of run information.
2498
2499 Mon Jun 17 20:08:03 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2500
2501         * registers.c (register_description): Typo, insns not insn.
2502
2503         * ppc-instructions (model_get_number_of_stalls): New model function,
2504         returns number of stalls for the specified processor.
2505         * psim.c (psim_read_register): Add call to new function
2506         model_get_number_of_stalls().
2507
2508         * ppc-instructions (model_get_number_of_cycles): New model function,
2509         returns number of stalls for the specified processor.
2510         * psim.c (psim_read_register): Add call to new function
2511         model_get_number_of_cycles().
2512
2513 Fri Jun 14 00:11:56 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2514
2515         * device_table.h: Don't pass the parent device into a devices
2516         create function.  This makes the create function consistent with
2517         the documentation.
2518         * device.c (device_template_create_device): Ditto
2519         * hw_pal.c (hw_pal_create): Ditto
2520         * hw_core.c (hw_core_create): Ditto
2521         * hw_vm.c (hw_vm_create): Ditto
2522         * hw_disk.c (hw_disk_create): Ditto
2523         * hw_nvram.c (hw_nvram_create): Ditto
2524         * hw_memory.c (hw_memory_create): Ditto
2525         * hw_cpu.c (hw_cpu_create): Ditto.
2526
2527         * device.c (split_find_device): Allow a null initial parent device.
2528         (device_template_create_device): Ditto.
2529
2530         * device.c (device_create_from): Make local (static) only used
2531         within device.c.
2532         * device_table.h: typedef device_callbacks moved here (from
2533         device.h) where it belongs.
2534
2535         * hw_core.c: New file. Implements just the core device using the
2536         core object.
2537
2538         * corefile.c: Moved all core device functions into the new
2539         hw_core.c file. core_device_create() disapears.
2540
2541         * psim.c (psim_tree): Use device_tree_add_parsed() to create the
2542         core device.
2543
2544 Thu Jun 13 00:09:29 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2545
2546         * hw_init.c: Correct typo in comment.
2547
2548         * corefile.c (core_init): Remove any remaining references to a
2549         default map.
2550         (core_map_find_mapping): Ditto.
2551
2552 Wed Jun 12 22:30:32 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2553
2554         * corefile.c (core_init): Make function global so that other
2555         devices are able to use the full core object.
2556
2557         * corefile.c (core_create, core_from_device): Break core_create
2558         into two functions.  The first creates a core object, the second
2559         returns the core object associated with a core device.
2560
2561         * corefile.c (core_device_create): Use core_create to make the
2562         core object.
2563
2564         * psim.c (psim_create): Use core_from_device() instead of
2565         core_create().
2566
2567         * device.c (device_template_create_device): Make static as only
2568         needed by functions internal to device.c.
2569
2570 Fri Jun  7 23:47:18 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2571
2572         * ppc-opcode-test-2: Remove description of fields.
2573         * ppc-opcode-complex: Ditto
2574         * ppc-opcode-flat: Ditto
2575         * ppc-opcode-simple: Ditto
2576         * ppc-opcode-stupid: Ditto
2577         * ppc-opcode-test-1: Ditto
2578         * ppc-cache-rules: Ditto
2579
2580         * igen.c: Add description of files as a comment at the front.
2581
2582 Wed Jun 26 12:50:33 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2583
2584         * configure.in: Check for whether the termios and termio
2585         structures are really defined, and whether or not, they define the
2586         c_line field.
2587         * configure: Regenerate.
2588
2589         * Makefile.in ({,TERMIO_}CFLAGS): Add TERMIO_CFLAGS options set by
2590         configure.
2591
2592         * emul_unix.c: Various changes to allow for building on systems
2593         with different termio and termios structures.  If host has both
2594         termio and termios, just use termios.  No longer include
2595         sys/ioctl.h.
2596
2597 Wed Jun 26 12:26:55 1996  Jason Molenda  (crash@godzilla.cygnus.co.jp)
2598
2599         * Makefile.in (bindir, libdir, datadir, mandir, infodir, includedir,
2600         INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set values.
2601         (docdir): Removed.
2602         * configure.in (AC_PREREQ): autoconf 2.5 or higher.
2603         (AC_PROG_INSTALL): Added.
2604         * configure: Rebuilt.
2605
2606 Wed Jun  5 23:53:42 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2607
2608         * corefile.h: Rewrite documentation so that it can be extracted and
2609         converted into texinfo (and hence ready for translation into html,
2610         tex or nroff).
2611         * device.h: Ditto
2612
2613 Thu Jun  6 09:52:37 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2614
2615         * hw_disk.c (SEEK_SET): If SEEK_SET is not defined, define as 0.
2616
2617 Wed Jun  5 11:46:52 1996  Andrew Cagney  <cagney@puddin>
2618
2619         * hw_disk.c: Include <unistd.h> if available.  Under SunOS, that
2620         is the source of SEEK_SET.
2621
2622 Wed Jun  5 01:39:07 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2623
2624         * psim.c (psim_options): Correct type of dummy arguments being
2625         passed to a device_ioctl call.
2626
2627         * hw_init.c (hw_data_init_data_callback): Adjust printf arguments.
2628         (write_stack_arguments): Ditto.
2629         * hw_trace.c: Instance callback entry no longer a table.
2630
2631 Wed Jun  5 01:39:07 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2632
2633         * emul_unix.c (do_unix_umask): Cast printf argument.
2634         (convert_to_linux_termios): Use LINUX_VSWTC not LINUX_VSWCH
2635
2636 Mon Jun  3 15:02:04 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2637
2638         * hw_init.c (update_for_binary_section): Abort if we find an
2639         .interp section, which indicates the need for shared libraries to
2640         be loaded.
2641
2642 Mon Jun  3 15:02:04 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2643
2644         * emul_unix.c (do_unix_{time,gettimeofday,getrusage}): Add support
2645         for time, gettimeofday, and getrusage system calls.
2646         ({solaris,linux}_descriptors): Add new system calls.
2647         (do_get{,e}{uid,gid}): Use gid_t/uid_t types.
2648         (do_get{,p}pid): Use pic_t types.
2649
2650         * configure.in (AC_TYPE_{GETGROUPS,SIGNAL}): Define.
2651         (AC_TYPE_{MODE,OFF,PID,SIZE,UID}_T): Define.
2652         * config{.in,ure}: Regenerate.
2653
2654 Mon Jun  3 23:19:57 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2655
2656         * emul_netbsd.c (emul_netbsd_create): Use the more specific names
2657         `ppc-elf' and `ppc-xcoff' for the stack-type.
2658         * emul_unix.c (emul_unix_create): Ditto.
2659         * emul_bugapi.c (emul_bugapi_create): Ditto.
2660         * hw_init.c: Reconize the new names.
2661
2662         * emul_unix.c (do_unix_break): Adjust so that the updated ioctl
2663         call is used (no system parameter).
2664
2665 Sun Jun  2 11:21:17 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2666
2667         * emul_unix.{h,c}: New files to provide Solaris and Linux system
2668         call emulations.
2669
2670         * Makefile.in (LIB_{SRC,OBJ}): Add emul_unix.{c,o}.
2671         (os_emul.o): Depend on emul_unix.h.
2672         (emul_unix.o): New dependency.
2673
2674         * configure.in (--enable-sim-alignment): Add 0|default to mean set
2675         alignment to 0, which means use appropriate alignment for mode.
2676         (AC_CHECK_FUNCS): Add new functions needed by emul_unix.c.
2677         (AC_CHECK_HEADERS): Add new include files needed by emul_unix.c.
2678         * config.in: Regenerate.
2679         * configure: Regenerate.
2680
2681         * emul_generic.c (emul_write2_status): New function to return
2682         results in r3 and r4 for Solaris system calls.
2683         (emul_do_system_call): If the system call is not support, but
2684         there is a string for the system call name, print out the string
2685         instead of the system call number.
2686
2687         * emul_generic.h (emul_write2_status): Declare it.
2688
2689         * emul_netbsd.c: Use /* */ around comment on #endif.
2690
2691         * os_emul.c: Include emul_unix.h.
2692         (os_emulations): Add emulations for Solaris, and Linux.
2693
2694         * psim.c (psim_usage): Add message about solaris, linux
2695         emulations.
2696
2697 Thu May 30 00:00:10 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2698
2699         * hw_iobus.c: Tidy up notes so that they can be auto-extracted.
2700
2701         * README: Correct PSIM's title
2702
2703 Wed May 29 23:50:26 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2704
2705         * basics.h: New global type object_disposition, used to indicate
2706         the status of objects when things are restarted.
2707
2708 Fri May 17 17:28:52 1996  Andrew Cagney  <cagney@benjimen.highland.com.au>
2709
2710         * device_table.h: Change the interrupt descriptor structure so
2711         that it includes an additional member - an upper bound on the
2712         interrupts by that name.
2713
2714         * device.c (device_interrupt_decode): Allow a range of interrupt
2715         ports (eg rst0 .. rst6) if the port descriptors bound is non zero.
2716
2717         * device.c (device_tree_print_device): Include a list of valid
2718         interrupt ports when listing supported devices.
2719
2720         * device.h, device.c (device_child_interrupt_*): Delete. Not used.
2721
2722         * emul_generic.c (emul_add_tree_hardware): Modify the creation of
2723         the interrupt net so that it uses int0 .. intN.
2724
2725 Tue May 14 23:03:53 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2726
2727         * device.h, device.c (device_ioctl): Drop the system argument.
2728         Devices can not obtain this using the device_system() call.
2729         * device_table.h: Adjust accordingly.
2730         * hw_*.c: Adjust accordingly.
2731         * emul_netbsd.c (do_break): Adjust call to vm device accordingly.
2732         * psim.c (psim_options): Use a device_ioctl call to force the
2733         hw_trace device to update the trace options.
2734         * hw_trace.c: Replace the init function with an ioctl call.  Adjust
2735         doc accordingly.
2736
2737         * psim.c (psim_init): Re-order initialization so that the
2738         os-emulation is initialized after the device tree.  Without this,
2739         os-emul's are not able to create instances or access properties
2740         that contain an instance handle.
2741
2742         * device.h, device.c (device_add_*_property): Make these functions
2743         internal to device.c.  The user has access to the more generic
2744         device_tree_add_parsed function.  Differentiate between the initial
2745         and current value for each property.
2746         * (clean_device_properties): New function that deletes any
2747         properties created after the start of a simulation and restores
2748         the initial value of any others (ignoring ihandles).
2749         * (init_device_properties): (Re)Initialize any properties that
2750         contain ihandles. create
2751
2752         * (device_tree_init): Include calls to clean the device tree's
2753         properties and then initialize them.  Document this in the device.h
2754         file.
2755
2756 Mon May  6 17:36:15 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2757
2758         * interrupts.c (decrementer_interrupt): Always pend a decrementer
2759         interrupt even if it is not yet possible to deliver it.
2760
2761 Wed May  1 12:26:51 1996  Andrew Cagney  <cagney@benjimen>
2762
2763         * mon.h, mon.c (mon_get_number_of_insns): Make this externally
2764         visable adjusting the arguments so that the interface is correct.
2765         (mon_print_info): Adjust calls.
2766         
2767         * registers.h, registers.c (register_description): Add phony
2768         cycle, insn and stall registers.
2769
2770         * psim.c (psim_read_register): Return nr of instructions for given
2771         processor.
2772
2773 Tue Apr 30 22:09:09 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2774
2775         * hw_htab.c: New file. Extract contents from disk_table.c.
2776         Contains a device that, during initialization will create a
2777         PowerPC htab in memory.
2778         * hw_register.c: New file. Extract contents from disk_table.c.
2779         Contains a device that, during initialization, will parse its
2780         property list and use that to initialize various processor
2781         registers (not target specific).
2782         * hw_vm.c: New file. Extract contents from disk_table.c.  Contains
2783         a device that handles accesses to invalid virtual memory addresses
2784         (in user mode).
2785         * hw_init.c: New file. Extract contents from disk_table.c.  Misc
2786         devices that can initialize memory from a file.
2787         * hw_trace.c: New file. Extract contents from disk_table.c.
2788         Configure trace options from property values.
2789
2790         * Makefile.in (hw_htab.o, hw_register.o, hw_vm.o, hw_init.o,
2791         hw_trace.c): Add new device files.
2792
2793         * device_table.c: Remove above code, now in separate independant
2794         files.
2795
2796 Fri Apr 26 00:00:07 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2797
2798         * hw_disk.c: New file.  Disk and CDROM device.
2799
2800         * Makefile.in (hw_disk.o): Add device hw_disk.c.
2801
2802         * pk_disklabel.c: New file.  Implement the miss-named disk-label
2803         package.
2804
2805         * Makefile.in (pk.h): Create the file pk.h that contains a list of all
2806         the packages.
2807
2808         * Makefile.in (hw.h, hw.c): Add dependancy on Makefile so that
2809         they are re-created when the makefile is updated.
2810
2811         * emul_generic.c (emul_add_tree_hardware): Add a disk device
2812         (below the iobus) to the device tree.  Include an ihandle of
2813         the disk as /chosen/disk.
2814
2815         * emul_bugapi.c (emul_bugapi_create): Don't initialize the input,
2816         output and (new) disk handles yet.
2817         * (emul_bugapi_init): Initialize the input, output (and just added)
2818         disk ihandles here.
2819         * (emul_bugapi_do_diskio): New.  Performs disk i/o (well at least
2820         what I think the behavour is).
2821         * emul_bugapi.c (emul_bugapi_instruction_call): Add hook to disk
2822         i/o bug call.  For RETURN call, exit using gpr[3]'s status even
2823         though this isn't part of the spec - makes it possible for machine
2824         code to signal the aporting of a simulation run.
2825
2826         * emul_chirp.c (chirp_emul_call_method): Add support for the
2827         claim/release methods.
2828         * (chirp_emul_exit): Add an optional exit status argument to
2829         the exit method.  Makes it possible for chirp emul simulations
2830         to abort upon an error.
2831         * device.h, device.c (device_instance_claim,
2832         device_instance_release): New methods for claiming and releasing
2833         memory.
2834         * hw_memory.c: add claim and release memory methods.
2835         * hw_*: Use the claim memory method when allocating physical
2836         memory.
2837
2838 Thu Apr 18 23:38:10 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2839
2840         * hw_nvram.c (hw_nvram_update_clock): Use the current not previous
2841         time when updating the clock.
2842
2843         * hw_nvram.c: Tidy up documentation
2844
2845 Fri May 24 10:08:10 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2846
2847         * configure.in (AC_STRUCT_ST_{BLKSIZE,BLOCKS,RDEV}): Use these
2848         macros to determine whether or not the appropriate st_<xxx> fields
2849         exist in the stat structure.
2850         (AC_CHECK_FUNCS): Check for all unix system calls used, except for
2851         the real basic ones like open, read, write, etc.
2852         * config{.in,ure}: Regenerate.
2853
2854         * emul_netbsd.c: Add support for missing system calls, and/or
2855         missing stat fields.
2856         (MAXPATHLEN): Undefine if including unistd.h, since sys/param.h
2857         might define it.
2858
2859         * hw_pal.c (WITH_STDIO): Redefine if O_NDELAY, F_GETFL, or F_SETFL
2860         are not defined.
2861         (scan_hw_pal): Do not cause syntax error if O_NDELAY, F_GETFL, or
2862         F_SETFL not defined.
2863
2864 Tue May 21 17:24:45 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2865
2866         * emul_netbsd.c (write_stat): Don't convert st_blocks unless the
2867         host is netbsd.
2868
2869 Thu May 16 10:56:45 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2870
2871         * configure.in (AC_CHECK_HEADERS): Add sys/ioctl.h.
2872         * config{.in,ure}: Regenerate.
2873         * emul_netbsd.c: If HAVE_SYS_IOCTL_H is not defined, don't include
2874         sys/ioctl.h.
2875
2876 Tue May  7 17:28:12 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2877
2878         * hw_pal.c (hw_pal_instance_read_callback): Remove unused
2879         variable.
2880
2881         * misc.c ({,target_}a2i): Rewrite to not use strtoul.
2882
2883         * Makefile.in ({spreg,misc}.o): Add dependency on .c file.
2884         ({i,d}gen): Don't link in liberity.  Use BUILD_LIBS instead of
2885         LIBS.
2886
2887 Mon May  6 11:31:43 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2888
2889         * hw_pal.c (hw_pal_instance_read_callback): If using stdio, use
2890         fgets to read line.  If not using stdio, do a simple blocking read
2891         of len bytes.
2892
2893 Fri May  3 15:07:42 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2894
2895         * Makefile.in: Correctly build simulator for build machine != host
2896         machine.
2897
2898 Tue Apr 30 18:46:05 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2899
2900         * configure.in (--enable-hostendian): Rework so the default uses
2901         the AC_C_BIGENDIAN results.  Only run AC_C_BIGENDIAN if not cross
2902         compiling.
2903         * configure: Regenerate.
2904         
2905         * sim-endian.h: Add more tests for host endian to support more
2906         platforms in a cross compilation environment.
2907
2908 Wed Apr 17 14:38:06 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
2909
2910         * hw_pal.c ({scan,write}_hw_pal): If WITH_STDIO == DO_USE_STDIO,
2911         use stdio, instead of unpended read/printf_filtered.
2912         (hw_pal_instance_write_callback): If WITH_STDIO == DO_USE_STDIO,
2913         flush stdout after writing the characters.
2914
2915         * options.c (print_options): Print out WITH_STDIO.
2916
2917         * Makefile.in (STDIO_CFLAGS): Pass on result of @sim_stdio@
2918         configuration variable.
2919         (CONFIG_CFLAGS): Include STDIO_CFLAGS.
2920         (hw.{c,h}): Allow for source dir != build dir, and for HW_SRC
2921         files to contain directory pieces.
2922
2923         * std-config.h (DO{,NT}_USE_STDIO): New flags for whether we
2924         should use stdio for console input.
2925         (WITH_STDIO): If not defined, define as DONT_USE_STDIO.
2926
2927         * configure.in (--enable-sim-stdio): Add new switch to control
2928         whether stdio is used for console I/O.
2929         * configure: Regenerate.
2930
2931         * interrupts.c (external_interrupt): Declare it to be
2932         INLINE_INTERRUPTS, not INLINE_CPU.
2933
2934 Mon Apr 15 23:30:56 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2935
2936         * events.c (insert_event_entry): Allow events to be scheduled
2937         *NOW* (at delta time 0).  Add assertions to clarify behavour of
2938         event queue.
2939
2940         * events.c (update_time_from_event): New function. Calculates the
2941         number of ticks from the next event.  Use this.
2942
2943 Sun Apr 14 21:39:45 1996  Andrew Cagney  <cagney@highland.com.au>
2944
2945         * emul_netbsd.c (do_break): Return 0 if success (instead of
2946         adjusted break).
2947
2948         * device_table.c (vm_ioctl_callback): Don't return adjusted break
2949         (isn't needed).
2950
2951 Sun Apr 14 21:32:41 1996  Andrew Cagney  <cagney@highland.com.au>
2952
2953         * device_table.h: Change type of the device ioctl so that it
2954         returns an int (status).
2955         * device.h (device_ioctl): Ditto.
2956         * device.c (device_ioctl): Ditto.
2957
2958         * device_table.c (stack_ioctl_callback): Return 0 status.
2959         (vm_ioctl_callback): Ditto
2960
2961 Sat Apr 13 00:00:24 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2962
2963         * emul_netbsd.c (do_read): Correctly set the return value.
2964         (do_getpid): Ditto.
2965         (do_getuid): Ditto.
2966         (do_geteuid): Ditto.
2967         (do_dup): Ditto.
2968         (do_getegid): Ditto.
2969         (do_getgid): Ditto.
2970         (do_sigprocmask): Ditto.
2971         (do_umask): Ditto.
2972         (do_dup2): Ditto.
2973         (do_gettimeofday): Ditto.
2974         (do_getrusage): Ditto.
2975         (do_fstat): Ditto.
2976         (do_stat): Ditto.
2977         (do_lseek): Ditto.
2978         (do___sysctl): Ditto.
2979
2980 Fri Apr 12 20:56:47 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2981
2982         * device_table.c (vm_ioctl_callback): Don't access the processor
2983         registers directly, instead leave it to the caller to handle this.
2984
2985         * emul_netbsd.c (do_break): Which calls vm_ioctl_callback to
2986         perform a break.  Pass in the new break value and set the
2987         registers according to the result.
2988
2989         * emul_generic.c (emul_write_status): Change so that r3 contains
2990         either status or errno and failure is indicated by SO.
2991
2992 Thu Apr  4 23:03:38 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
2993
2994         * emul_bugapi.c (emul_bugapi_create): More strict check of OEA
2995         address.
2996
2997 Thu Apr  4 20:58:05 1996  Andrew Cagney  <cagney@highland.com.au>
2998
2999         * interrupts.h (interrupts): New structure contains state of
3000         pending interrupts.
3001
3002         * cpu.c (cpu_interrupts): New function.  Pending interrupt status
3003         in the cpu and grant access to it.  Add interrupts to cpu
3004         structure.
3005
3006 Fri Mar 29 22:09:25 1996  Andrew Cagney  <cagney@highland.com.au>
3007
3008         * device.c (device_tree_add_parsed): Check that the creation of a
3009         device instance worked before using it.
3010
3011         * psim.c (psim_halt): Remove cia argument from psim_halt.  This
3012         function does not save the CIA so do not pass it in.
3013
3014 Fri Mar 29 21:30:56 1996  Andrew Cagney  <cagney@highland.com.au>
3015
3016         * hw_pal.c (hw_pal): Merge the halt and icu and console devices
3017         found in device_table.c into a single hack pal.
3018
3019         * device_table.c (halt, icu, console): Delete.
3020
3021         * Makefile.in (hw_pal.o): New dependency.
3022
3023         * emul_generic.c (emul_add_tree_hardware): Re-arange device tree
3024         so that it uses the pal instead of the icu/halt/console devices.
3025         Wire the pal's interrupt ports up to the cpu nodes.
3026
3027 Fri Mar 29 20:17:17 1996  Andrew Cagney  <cagney@highland.com.au>
3028
3029         * hw_iobus.c (hw_iobus_attach_address_callback): Move from
3030         device_table.c to here.
3031
3032         * Makefile.in (hw_iobus.o): New dependency.
3033
3034 Fri Mar 29 12:17:58 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3035
3036         * emul_bugapi.c (_os_emul_data): Add fields for output, input.
3037         (emul_bugapi_create): Create input, output from /chosen/stdin and
3038         /chosen/stdout.
3039         (emul_bugapi_do_{read,write}): Switch to use device_instance
3040         interface.
3041         (emul_bugapi_instruction_call): Change calls to
3042         emul_bugapi_do_{read,write} to pass device instance argument.
3043
3044 Tue Mar 26 14:57:58 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
3045
3046         * igen.c (idecode_switch_end): Fix 2/26 change so that an extra
3047         default is not written out if a default was already written.
3048
3049         * psim.c (psim_{read,write}_register): Use sizeof unsigned_8 to
3050         size cooked_buf, not sizeof natural_word, since floating point
3051         registers are 8 bytes.
3052
3053 Mon Mar 25 22:07:13 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3054
3055         * configure: Regenerate with autoconf 2.9.
3056
3057 Thu Mar 21 00:14:26 1996  Andrew Cagney  <cagney@highland.com.au>
3058
3059         * device_table.h: Always include string headers.
3060
3061 Thu Mar 21 00:06:09 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3062
3063         * main.c (error): Be careful to not try to print out statistics
3064         when the simulation was never created.
3065
3066 Sun Mar 17 22:40:57 1996  Andrew Cagney  <cagney@highland.com.au>
3067
3068         * basics.h: Move the event queue's definition to here so that it
3069         can be refered to globally with out importing all of events.h.
3070
3071         * psim.h, psim.c (psim_event_queue): New function.  Grant access
3072         to the simulation event queue.  Will make this the single point of
3073         access (there is after all only one event queue in the
3074         simulation).
3075
3076         * cpu.c (cpu_create): Use psim_event_queue to obtain the event
3077         queue instead of it being passed in.  No longer allow access to
3078         the cpu's copy of the event queue.
3079
3080 Sun Mar 17 22:40:57 1996  Andrew Cagney  <cagney@highland.com.au>
3081
3082         * events.h, events.c (event_handler): Remove event_queue from
3083         arguments passed to an event handler.  That argument is redundant
3084         - the `data' should refer to a data structure that contains the
3085         event queue if queing is needed.
3086
3087         * cpu.c (cpu_decrement_event): adjust
3088
3089         * events.c (event_queue_process): adjust
3090
3091 Sun Mar 17 22:40:57 1996  Andrew Cagney  <cagney@highland.com.au>
3092
3093         * device.h, device.c (device_system): New, returns a handle for
3094         the system given the device.
3095
3096         * device.c (device_address_init): Store a pointer back to the
3097         system in each devices node.
3098
3099         * device_table.h: Don't pass `system' into each device when it is
3100         being initialized, this is now available using device_system(me).
3101
3102         * device.c (device_address_init, device_data_init): Adjust.
3103
3104         * hw_cpu.c, hw_nvram.c, hw_memory.c, hw_eeprom.c, device_table.c:
3105         Adjust.
3106
3107 Sun Mar 17 22:40:57 1996  Andrew Cagney  <cagney@highland.com.au>
3108
3109         * interrupts.c (decrementer_interrupt, external_interrupt):
3110         Remember that an interrupt wasn't delivered so that it can be
3111         tried again later.
3112
3113         * interrupts.c (check_masked_interrupt): New function.  (re)
3114         checks for the posibility that a recent change to the MSR may have
3115         made it possible to deliver an interrupt that was previously
3116         masked be the EE bit.
3117
3118         * ppc-instructions (mtmsr, mfmsr, rfi): Check for posibility of
3119         a pending interrupt being delivered using check_masked_interrupt().
3120
3121         * cpu.c (cpu_decrement_event): Just call decrementer_interrupt()
3122         leaving it to that module to handle both interrupt synchronization
3123         and masking.
3124
3125         * cpu.c (struct _cpu): remove variables that were going to record
3126         pending decrementer and external interrupts.
3127
3128 Sun Mar 17 22:40:57 1996  Andrew Cagney  <cagney@highland.com.au>
3129
3130         * hw_cpu.c, hw_cpu.h: New files.  Implement a device that sits
3131         between the interrupt controller and the simulators internal
3132         processor model.  Maps device interrupts onto the processor
3133         interrupt function calls.
3134
3135 Mon Mar  4 06:06:54 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3136
3137         * hw_nvram.c: NVRAM device that includes a real-time clock that is
3138         updated each second.
3139
3140 Mon Mar  4 04:18:50 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3141
3142         * device.h (attach_type): Remove attach_default type address
3143         spaces.  Will replace with levels of callback memory.
3144
3145         * corefile.h, corefile.c (new_core_mapping), corefile.c
3146         (core_map_attach): Replace default attach with a layerd callback
3147         approach.
3148
3149 Sun Mar  3 03:58:46 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3150
3151         * device.c (split_property_specifier): ensure that only a single
3152         property is found.
3153         (split_value): New function, parses the value part of a device
3154         spec.
3155
3156         * device.c (device_tree_add_parsed): Use the interrupt conversion
3157         functions to determine the interrupt port numbers.
3158
3159         * device_table.h: Add table that maps between an interrupts
3160         symbolic name and its port number.
3161
3162         * device.h, device.c (device_interrupt_decode,
3163         device_interrupt_encode): new functions use the recently added
3164         interrupt port name/number tables to perform conversion.
3165
3166 Sun Mar  3 03:23:59 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3167
3168         * device.h, device.c (device_set_array_property,
3169         device_set_boolean_property, device_set_ihandle_property,
3170         device_set_integer_property, device_set_string_property): New
3171         functions - allow the value of a given property to be changed.
3172
3173         * device.h, device.c: Re-order declaration and definition of
3174         property functions.
3175
3176 Sun Mar  3 03:10:22 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3177
3178         * device.c (device_tree_print_device, device_tree_add_parsed):
3179         Remove references to phandle properties.
3180
3181 Wed Feb 28 00:43:07 1996  Andrew Cagney - aka Noid  <cagney@highland.com.au>
3182
3183         * Makefile.in (corefile.o): missing dependency on device_table.h
3184         etc.
3185
3186 Tue Feb 27 23:59:35 1996  Andrew Cagney - aka Noid  <cagney@highland.com.au>
3187
3188         * device_table.h: Revamp device init callbacks so that they are a
3189         sub structure.
3190         * device.c (device_init_data, device_init_address): If an init
3191         callback is NULL assume it should do nothing.
3192         * device_table.c (ignore_device_init, unimp_device_init): delete
3193         as redundant.
3194         * device_table.c, hw_memory.c: adjust.
3195
3196         * (io): ditto.
3197         * (dma): ditto.
3198         * (device_instance): ditto.
3199         * (ioctl): ditto.
3200         * (address nee config_address): ditto.
3201         * (interrupt): ditto.
3202
3203 Mon Feb 26 21:11:20 1996  Andrew Cagney - aka Noid  <cagney@highland.com.au>
3204
3205         * igen.c (idecode_switch_end): Output a default entry when the
3206         switch statement is perfect.  Firstly stops GCC complaining about
3207         an incomplete switch and secondly it will be eliminated by a good
3208         compiler any way.
3209
3210 Mon Feb 26 22:47:15 1996  Andrew Cagney - aka Noid  <cagney@highland.com.au>
3211
3212         * Makefile.in (hw.h, hw.c): New targets. Create from the list of
3213         hw_*.c files. hw.h declares a device descriptor table for each hw
3214         device while hw.c lists those tables in a form suitable for the
3215         construction of a top leveltable in device_table.c.
3216
3217         * Makefile.in (device_table.o): now depends on hw.c a generated
3218         table of hw.
3219
3220         * device_table.c (device_table): Re-arange the table of devices so
3221         that two levels are possible.  Make use of hw.c.
3222         * device_table.h: ditto.
3223
3224         * device.c (device_template_create_device): Handle new two level
3225         device lookup table.
3226         * device.c (device_usage): ditto.
3227
3228 Mon Feb 26 22:24:00 1996  Andrew Cagney - aka Noid  <cagney@highland.com.au>
3229
3230         * device_table.c: Delete the memory device (moved to hw_memory.c).
3231
3232         * hw_memory.c: New file.  Just an OpenBoot memory device.
3233
3234 Wed Jan 17 21:47:34 1996  Andrew Cagney  <cagney@highland.com.au>
3235
3236         * device.c (device_init_address): New.  Split initialization into
3237         two stages, address and address spaces
3238         * device.c (device_init_data): New. ... and data or other work.
3239         With out this, devices try to modify memory before it as been
3240         attached.
3241
3242         * device.c (device_tree_init): Update to perform staged
3243         initialization.
3244
3245         * device.c (device_init): Delete.
3246
3247 Wed Jan 17 21:43:09 1996  Andrew Cagney  <cagney@highland.com.au>
3248
3249         * device_table.c (data_*): Rewrite to make heaver use of property
3250         nodes. Allow initialization by different data types.
3251         * device_table.c (htab_* pte_*): Rewrite to use properties.
3252
3253         * emul_chirp.c (emul_chirp_create): Use
3254         * emul_bugapi.c (emul_bugapi_create): Ditto
3255         * emul_netbsd.c (emul_netbsd_create): Ditto
3256
3257 Wed Jan 17 21:24:50 1996  Andrew Cagney  <cagney@highland.com.au>
3258
3259         * emul_generic.c (emul_add_tree_options): Annotate existing tree
3260         with options that haven't yet been specified.
3261         * emul_generic.c (emul_add_tree_hardware): Annotate existing tree
3262         with demo devices and properties.
3263
3264         * emul_chirp.c (emul_chirp_create): Update to use new
3265         device_tree_add_parsed call and additional information now
3266         included in the device tree.  Use emul_add_tree* functions to add
3267         any missing details.
3268         * emul_bugapi.c (emul_bugapi_create): Ditto
3269         * emul_netbsd.c (emul_netbsd_create): Ditto
3270
3271 Wed Jan 17 21:18:27 1996  Andrew Cagney  <cagney@highland.com.au>
3272
3273         * device.c (device_instance_create): New. Create/delete and
3274         operate on instances of a device.
3275         * device.c (device_instance_delete): Ditto
3276         * device.c (device_instance_read): Ditto
3277         * device.c (device_instance_write): Ditto
3278         * device.c (device_instance_seek): Ditto
3279         * device.c (device_instance_data): Ditto
3280         * device.c (device_instance_name): Ditto
3281         * device.c (device_instance_path): Ditto
3282
3283         * emul_chirp.c (chirp_emul_open): Implement using device_instance.
3284         * emul_chirp.c (chirp_emul_close): Ditto
3285         * emul_chirp.c (chirp_emul_read): Ditto
3286         * emul_chirp.c (chirp_emul_write): Ditto
3287         * emul_chirp.c (chirp_emul_seek): Ditto
3288
3289         * emul_chirp.c (chirp_read_t2h_args): Read arguments from device.
3290         Being careful to convert all from target to host byte order.
3291         * emul_chirp.c (chirp_write_h2t_args): Converse.
3292
3293 Wed Jan 17 20:07:15 1996  Andrew Cagney  <cagney@highland.com.au>
3294
3295         * device.c (device_tree_add_parsed): New.  Rewrite code to add
3296         devices to the device tree so that a single printf style function
3297         is used.
3298
3299         * device.c (device_tree_add_*): Delete. Replaced by above.
3300
3301         * device.c (split_device_specifier): Functions to manipulate a
3302         device specifier (path) breaking it into its components
3303         * device.c (split_property_specifier): Ditto
3304         * device.c (split_device_name): Ditto
3305         * device.c (split_find_device): Ditto
3306
3307         * device.c (scan_*): Delete
3308
3309         * device.c (device_tree_find_device): Rewrite to use above.
3310         * device.c (device_add_property): Ditto
3311
3312 Wed Jan 17 19:51:56 1996  Andrew Cagney  <cagney@highland.com.au>
3313
3314         * psim.c(psim_options): Parse the psim options, installing their
3315         value in the device tree.  Options are now first entered into a
3316         device tree and then extracted out again when needed.  This allows
3317         greater flexability in configuration.
3318
3319         * psim.c (psim_tree): Returns a basic device tree ready for
3320         parsing by psim_options.
3321         * psim.c (psim_usage): New.  Give usage to varing levels of detail
3322         according to the verbosity.  In turn output device and trace
3323         usage.
3324
3325         * main.c (main): Update to use new system
3326         * sim_calls.c (sim_open, sim_do_command): Ditto
3327
3328         * psim.c (psim_options): Add `r' option - ram size.
3329         * psim.c (psim_options): Add `o' option - openboot tree entry.
3330         * psim.c (psim_options): Add `h'/`H' options - more help.
3331
3332         * debug.c (trace_usage): Add more detailed help.
3333         * device.c (device_usage): New. Output help including a list of
3334         the devices currently available in the device table.
3335         * device_table.c: Add usage operator to each device.
3336
3337         * corefile.c (core_create, core_device_create): Adjust so that the
3338         core device is created earlier for psim_tree().  Core can later be
3339         created from it.
3340
3341         * psim.c (psim_create): Update to handle above way of creating
3342         things.  Extract all information from the device tree.
3343
3344         * device_tree.c (trace_*): New device node, its properties are
3345         used to set the value of the trace options.  Init this device (in
3346         psim_options) when ever the options are updated.
3347
3348 Wed Jan 17 19:46:07 1996  Andrew Cagney  <cagney@highland.com.au>
3349
3350         * debug.h: Add trace_print_info, trace_print_device_tree and
3351         trace_dump_device_tree.  The first is a replacement for the
3352         variable `print_info' found in main.c and sim_calls.c.  The latter
3353         two enable the dumping of the entire device tree.
3354
3355         * debug.c: Add to trace_description table.
3356
3357         * main.c (main): Use above trace instead of local variable
3358         * sim_calls.c (sim_close): Ditto
3359
3360         * device.c (device_tree_print_device): New.  Prints the device
3361         tree in a format that is consistent with what can be parsed by the
3362         device tree load from file code.
3363
3364         * psim.c (psim_create): Dump device tree if enabled. If nump
3365         selected, exit psim immediatly.
3366
3367 Wed Jan 17 19:36:52 1996  Andrew Cagney  <cagney@highland.com.au>
3368
3369         * corefile-n.h (core_map_read_N): When mapping from an address to
3370         a device, do not subtract the devices base.  The device its self
3371         can do this.  Brings the behavour into line with OpenBoot.
3372         * corefile-n.h (core_map_write_N): Ditto
3373         * corefile.c (core_map_read_buffer): Ditto
3374         * corefile.c (core_map_write_buffer): Ditto
3375
3376         * device_table.c (console_io_read_buffer_callback): Adjust to
3377         handle biased address.
3378         * device_table.c (console_io_write_buffer_callback): Ditto
3379
3380 Wed Jan 17 18:36:09 1996  Andrew Cagney  <cagney@highland.com.au>
3381
3382         * device.c (attach_device_interrupt_edge): New. Interrupt model
3383         did not allow interrupts to be wired up as a general net (edges).
3384         Re-implement so that interrupt events can be passed to multiple
3385         controllers and interrupt controllers can further propogate
3386         interrupt events.
3387
3388         * device.c (attach_device_interrupt_edge) : New, Ditto
3389         * device.c (detach_device_interrupt_edge) : New, Ditto
3390         * device.c (clean_device_interrupt_edges) : New, Ditto
3391         * device.c (device_interrupt_event) : New, Ditto
3392         * device.c (device_interrupt_attach) : New, Ditto
3393         * device.c (device_interrupt_detach) : New, Ditto
3394         * device.c (device_child_interrupt_attach) : New, Ditto
3395         * device.c (device_child_interrupt_detach) : New, Ditto
3396
3397         * device.c (device_attach_interrupt) : Delete old
3398         * device.c (device_detach_interrupt) : Delete old
3399         * device.c (device_interrupt) : Delete old
3400         * device.c (device_interrupt_ack) : Delete old
3401
3402         * device_table.c (unimp_*) : Update to match
3403         
3404         * device_table.c (icu_io_write_buffer_callback) : Update to use
3405         interface.
3406         * device_table.c (icu_interrupt_event_callback) : Ditto
3407
3408 Wed Jan 17 18:18:40 1996  Andrew Cagney  <cagney@highland.com.au>
3409
3410         * device.c (external_to_device) : New function that provides a
3411         standard mapping between a devices internal representation (a
3412         pointer) and its external (or what is passed to a client)
3413         representation (a phandle).  Implement using the cap object
3414         attached to the root node.
3415
3416         * device.c (device_to_external) : Ditto
3417         * device.c (external_to_device_instance) : Ditto but for ihandle
3418         and device instance.
3419         * device.c (device_instance_to_external) : Ditto
3420
3421         * Makefile (device.o): Add dependency on cap.
3422
3423         * emul_chirp.c (struct _emul_chirp_data) : Elimate use of cap. Code
3424         needing to translate between internal and external representations
3425         changed to use the external_to_device et.al. device operations.
3426         * emul_chirp.c (chirp_emul_*) : Ditto
3427
3428         * Makefile (emul_chirp.o): Remove dependency on cap
3429
3430 Sat Jan  6 10:13:26 1996  Andrew Cagney - aka Noid  <cagney@highland.com.au>
3431
3432         * emul_chirp.c (map_over_chirp_note): Tighten up (and fix) checks
3433         on OpenBoot note section.
3434
3435 Fri Jan  5 20:28:53 1996  Andrew Cagney  <cagney@hignland.com.au>
3436
3437         * emul_generic.c (emul_write_buffer): Use vm faulting byte
3438         read/write calls for buffer transfers.  This will cause a fault to
3439         occure if the transfer fails.  CHRP catches the fault while the
3440         others suffer the consequences.
3441         (emul_read_buffer): Ditto.
3442         (emul_write_word): Ditto.
3443         (emul_read_word): Ditto.
3444         (emul_read_string): Ditto.
3445
3446 Fri Jan  5 18:55:34 1996  Andrew Cagney  <cagney@highland.com.au>
3447
3448         * emul_chirp.c (emul_chirp_create, emul_chirp_instruction_call),
3449         emul_generic (emul_blr_instruction): Use a real blr instruction to
3450         return from a client service call.
3451
3452         * emul_chirp.c (services): Add all OpenBoot services to table.
3453
3454         * emul_generic.h, emul_bugapi.c (emul_bugapi_create), emul_chirp.c
3455         (emul_chirp_create) : Use names instead of numbers for
3456         instructions being stored in memory.
3457
3458 Fri Jan  5 18:52:28 1996  Andrew Cagney  <cagney@highland.com.au>
3459
3460         * Makefile.in (maintainer-clean): Remove .log, core and *.core
3461         (From NetBSD) files.
3462
3463 Wed May 29 22:57:40 1996  Andrew Cagney  <cagney@kremvax.highland.com.au>
3464
3465         * ChangeLog.00, ChangeLog: ChangeLog from gdb-4.16 becomes
3466         ChangeLog.00
3467