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