]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - sim/m68hc11/ChangeLog
sim: punt WITH_DEVICES & tconfig.h support
[thirdparty/binutils-gdb.git] / sim / m68hc11 / ChangeLog
1 2015-12-26 Mike Frysinger <vapier@gentoo.org>
2
3 * config.in, configure: Regenerate.
4
5 2015-12-24 Mike Frysinger <vapier@gentoo.org>
6
7 * sim-main.h (SIM_HANDLES_LMA): Delete.
8
9 2015-12-24 Mike Frysinger <vapier@gentoo.org>
10
11 * sim-main.h (WITH_WATCHPOINTS): Delete.
12
13 2015-11-17 Mike Frysinger <vapier@gentoo.org>
14
15 * sim-main.h (WITH_MODULO_MEMORY): Delete.
16
17 2015-11-15 Mike Frysinger <vapier@gentoo.org>
18
19 * Makefile.in (SIM_OBJS): Delete sim-reason.o and sim-stop.o.
20
21 2015-11-14 Mike Frysinger <vapier@gentoo.org>
22
23 * Makefile.in (SIM_OBJS): Delete sim-load.o.
24
25 2015-11-14 Mike Frysinger <vapier@gentoo.org>
26
27 * interp.c (sim_close): Delete.
28
29 2015-06-23 Mike Frysinger <vapier@gentoo.org>
30
31 * configure: Regenerate.
32
33 2015-06-12 Mike Frysinger <vapier@gentoo.org>
34
35 * configure: Regenerate.
36
37 2015-06-12 Mike Frysinger <vapier@gentoo.org>
38
39 * configure: Regenerate.
40
41 2015-06-11 Mike Frysinger <vapier@gentoo.org>
42
43 * interp.c (interrupt_names): Delete.
44
45 2015-06-11 Mike Frysinger <vapier@gentoo.org>
46
47 * Makefile.in (SIM_OBJS): Add sim-resume.o
48 * interp.c (has_stepped, sim_resume): Delete.
49
50 2015-06-11 Mike Frysinger <vapier@gentoo.org>
51
52 * interp.c (INLINE): Delete define.
53
54 2015-04-29 Nick Clifton <nickc@redhat.com>
55
56 PR 18273
57 * gencode.c (gen_fetch_operands): Remove unreachable code.
58
59 2015-04-18 Mike Frysinger <vapier@gentoo.org>
60
61 * sim-main.h (SIM_CPU): Delete.
62
63 2015-04-18 Mike Frysinger <vapier@gentoo.org>
64
65 * sim-main.h (sim_cia): Delete.
66
67 2015-04-17 Mike Frysinger <vapier@gentoo.org>
68
69 * sim-main.h (CIA_GET, CIA_SET): Delete.
70
71 2015-04-15 Mike Frysinger <vapier@gentoo.org>
72
73 * Makefile.in (SIM_OBJS): Delete sim-cpu.o.
74 * sim-main.h (STATE_CPU): Delete.
75
76 2015-04-13 Mike Frysinger <vapier@gentoo.org>
77
78 * configure: Regenerate.
79
80 2015-04-13 Mike Frysinger <vapier@gentoo.org>
81
82 * Makefile.in (SIM_OBJS): Add sim-cpu.o.
83 * interp.c (m68hc11_pc_get, m68hc11_pc_set): New functions.
84 (sim_open): Declare new local var i. Call sim_cpu_alloc_all.
85 Call CPU_PC_FETCH & CPU_PC_STORE for all cpus.
86 (sim_pc_get): Delete.
87 * sim-main.h (SIM_CPU): Define.
88 (STATE_CPU): Drop &.
89 (struct sim_state): Change cpu to an array of pointers.
90
91 2015-04-06 Mike Frysinger <vapier@gentoo.org>
92
93 * Makefile.in (SIM_OBJS): Delete sim-engine.o and sim-hrw.o.
94
95 2015-03-31 Mike Frysinger <vapier@gentoo.org>
96
97 * m68hc11_sim.c (cpu_get_indexed_operand_addr,
98 cpu_get_indexed_operand8, cpu_get_indexed_operand16): Rename restrict
99 variable to restricted.
100 * sim-main.h (cpu_get_indexed_operand_addr): Likewise.
101
102 2015-03-24 Mike Frysinger <vapier@gentoo.org>
103
104 * interp.c (sim_pc_get): New function.
105
106 2015-03-24 Mike Frysinger <vapier@gentoo.org>
107
108 * compile.c (sim_set_profile, sim_set_profile_size, sim_set_callbacks,
109 sim_size, sim_trace): Delete.
110 * sim-main.h (sim_set_profile, sim_set_profile_size): Delete.
111
112 2015-03-24 Mike Frysinger <vapier@gentoo.org>
113
114 * configure: Regenerate.
115
116 2015-03-23 Mike Frysinger <vapier@gentoo.org>
117
118 * configure: Regenerate.
119
120 2015-03-23 Mike Frysinger <vapier@gentoo.org>
121
122 * configure: Regenerate.
123 * configure.ac (m68hc11_extra_objs): Delete.
124 * Makefile.in (SIM_OBJS): Delete SIM_EXTRA_OBJS.
125 (SIM_EXTRA_OBJS): Delete.
126
127 2015-03-16 Mike Frysinger <vapier@gentoo.org>
128
129 * config.in, configure: Regenerate.
130
131 2015-03-14 Mike Frysinger <vapier@gentoo.org>
132
133 * Makefile.in (SIM_RUN_OBJS): Delete.
134
135 2015-03-14 Mike Frysinger <vapier@gentoo.org>
136
137 * configure.ac (AC_CHECK_HEADERS): Delete.
138 * aclocal.m4, configure: Regenerate.
139
140 2014-08-19 Alan Modra <amodra@gmail.com>
141
142 * configure: Regenerate.
143
144 2014-08-15 Roland McGrath <mcgrathr@google.com>
145
146 * configure: Regenerate.
147 * config.in: Regenerate.
148
149 2014-03-04 Mike Frysinger <vapier@gentoo.org>
150
151 * configure: Regenerate.
152
153 2013-09-23 Alan Modra <amodra@gmail.com>
154
155 * configure: Regenerate.
156
157 2013-06-03 Mike Frysinger <vapier@gentoo.org>
158
159 * aclocal.m4, configure: Regenerate.
160
161 2013-05-10 Freddie Chopin <freddie_chopin@op.pl>
162
163 * configure: Rebuild.
164
165 2013-03-26 Mike Frysinger <vapier@gentoo.org>
166
167 * configure: Regenerate.
168
169 2013-03-23 Joel Sherrill <joel.sherrill@oarcorp.com>
170
171 * configure.ac: Use $SIM_DV_SOCKSER_O.
172 * configure: Regenerated.
173
174 2012-06-15 Joel Brobecker <brobecker@adacore.com>
175
176 * config.in, configure: Regenerate.
177
178 2012-03-24 Mike Frysinger <vapier@gentoo.org>
179
180 * aclocal.m4, config.in, configure: Regenerate.
181
182 2011-12-03 Mike Frysinger <vapier@gentoo.org>
183
184 * aclocal.m4: New file.
185 * configure: Regenerate.
186
187 2011-10-19 Mike Frysinger <vapier@gentoo.org>
188
189 * configure: Regenerate after common/acinclude.m4 update.
190
191 2011-10-17 Mike Frysinger <vapier@gentoo.org>
192
193 * configure.ac: Change include to common/acinclude.m4.
194
195 2011-10-17 Mike Frysinger <vapier@gentoo.org>
196
197 * configure.ac: Change AC_PREREQ to 2.64. Delete AC_CONFIG_HEADER
198 call. Replace common.m4 include with SIM_AC_COMMON.
199 * configure: Regenerate.
200
201 2011-07-05 Mike Frysinger <vapier@gentoo.org>
202
203 * interp.c (sim_do_command): Delete.
204
205 2010-01-09 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
206
207 * configure: Regenerate.
208
209 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
210
211 * config.in: Regenerate.
212 * configure: Likewise.
213
214 * configure: Regenerate.
215
216 2008-07-11 Hans-Peter Nilsson <hp@axis.com>
217
218 * configure: Regenerate to track ../common/common.m4 changes.
219 * config.in: Ditto.
220
221 2008-06-06 Vladimir Prus <vladimir@codesourcery.com>
222 Daniel Jacobowitz <dan@codesourcery.com>
223 Joseph Myers <joseph@codesourcery.com>
224
225 * configure: Regenerate.
226
227 2006-12-21 Hans-Peter Nilsson <hp@axis.com>
228
229 * config.in: Regenerate.
230
231 2006-06-13 Richard Earnshaw <rearnsha@arm.com>
232
233 * configure: Regenerated.
234
235 2006-06-05 Daniel Jacobowitz <dan@codesourcery.com>
236
237 * configure: Regenerated.
238
239 2006-05-31 Daniel Jacobowitz <dan@codesourcery.com>
240
241 * configure: Regenerated.
242
243 2006-03-29 Hans-Peter Nilsson <hp@axis.com>
244
245 * configure: Regenerate.
246
247 2005-03-23 Mark Kettenis <kettenis@gnu.org>
248
249 * configure: Regenerate.
250
251 2005-01-14 Andrew Cagney <cagney@gnu.org>
252
253 * configure.ac: Sinclude aclocal.m4 before common.m4. Add
254 explicit call to AC_CONFIG_HEADER.
255 * configure: Regenerate.
256
257 2005-01-11 Andrew Cagney <cagney@localhost.localdomain>
258
259 * configure: Regenerated to track ../common/aclocal.m4 changes.
260
261 2005-01-07 Andrew Cagney <cagney@gnu.org>
262
263 * configure.ac: Rename configure.in, require autoconf 2.59.
264 * configure: Re-generate.
265
266 2004-12-08 Hans-Peter Nilsson <hp@axis.com>
267
268 * configure: Regenerate for ../common/aclocal.m4 update.
269
270 2004-06-15 Alan Modra <amodra@bigpond.net.au>
271
272 * interp.c (sim_prepare_for_program): Use bfd_get_section_size
273 instead of bfd_get_section_size_before_reloc.
274
275 2003-08-08 Stephane Carrez <stcarrez@nerim.fr>
276
277 * dv-m68hc11tim.c (cycle_to_string): Add flags parameter to better
278 control the translation.
279 (m68hc11tim_print_timer): Update cycle_to_string conversion.
280 (m68hc11tim_timer_event): Fix handling of output
281 compare register with its interrupts.
282 (m68hc11tim_io_write_buffer): Check output compare
283 after setting M6811_TMSK1.
284 (m68hc11tim_io_read_buffer): Fix compilation warning.
285 * dv-m68hc11.c (m68hc11_option_handler): Likewise.
286 * dv-m68hc11spi.c (m68hc11spi_info): Likewise.
287 * dv-m68hc11sio.c (m68hc11sio_info): Likewise.
288 * interrupts.c (interrupts_info): Likewise.
289 (interrupts_reset): Recognize bootstrap mode.
290 * sim-main.h (PRINT_CYCLE, PRINT_TIME): New defines.
291 (_sim_cpu): Add cpu_start_mode.
292 (cycle_to_string): Add flags member.
293 * m68hc11_sim.c (OPTION_CPU_BOOTSTRAP): New option.
294 (cpu_options): Declare new option bootstrap.
295 (cpu_option_handler): Handle it.
296 (cpu_info): Update call to cycle_to_string.
297
298 2003-08-08 Stephane Carrez <stcarrez@nerim.fr>
299
300 * sim-main.h (phys_to_virt): Use memory bank parameters to translate
301 the physical address in virtual address.
302 (struct _sim_cpu): Add memory bank members.
303 * m68hc11_sim.c (cpu_initialize): Clear memory bank parameters.
304 * interp.c (sim_hw_configure): Create memory bank according to memory
305 bank parameters.
306 (sim_get_bank_parameters): New function to obtain memory bank config
307 from the symbol table.
308 (sim_prepare_for_program): Call it to obtain the memory bank parameters.
309 (sim_open): Call sim_prepare_for_program.
310 * dv-m68hc11.c (m68hc11cpu_io_write_buffer): Use memory bank parameters
311 to check if address is within bank window.
312 (m68hc11cpu_io_read_buffer): Likewise.
313 (attach_m68hc11_regs): Map the memory bank according to memory bank
314 parameters.
315
316 2003-08-08 Stephane Carrez <stcarrez@nerim.fr>,
317
318 * sim-main.h (PAGE_REGNUM, Z_REGNUM): Use same numbering as gdb.
319
320 2003-08-08 Stephane Carrez <stcarrez@nerim.fr>,
321 Gary Piercey <gpiercey@northstar-technical.com>
322
323 * m68hc11_sim.c (print_io_word): New function to print 16-bit value.
324 * sim-main.h (print_io_word): Declare.
325 * dv-m68hc11tim.c (tmsk1_desc): New description table for TMSK1.
326 (tflg1_desc): Likewise for TFLG1.
327 (m68hc11tim_info): Print input and output compare registers
328
329 2003-03-02 Stephane Carrez <stcarrez@nerim.fr>
330
331 * Makefile.in (SIM_EXTRA_CFLAGS): Set WITH_TARGET_ADDRESS_BITSIZE
332 to 32 to support memory bank switching; temporarily use 32-bit for
333 WORD_BITSIZE to avoid a bug in sim-common.
334
335 2003-03-01 Stephane Carrez <stcarrez@nerim.fr>
336
337 * interp.c (sim_fetch_register): Only store a single byte for
338 1 byte registers.
339
340 2003-02-27 Andrew Cagney <cagney@redhat.com>
341
342 * interp.c (sim_prepare_for_program, sim_open)
343 (sim_create_inferior): Rename _bfd to bfd.
344
345 2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
346
347 * dv-m68hc11eepr.c (struct m68hc11eepr ): Use const char* for filename.
348
349 2002-08-13 Marko Kohtala <marko.kohtala@luukku.com>
350
351 * interp.c (sim_prepare_for_program): Look up the image for the
352 reset vector and set cpu_use_elf_start to 1 if not found.
353 (sim_open): Do not set cpu_use_elf_start.
354
355 2002-08-13 Marko Kohtala <marko.kohtala@luukku.com>
356
357 * interp.c (sim_hw_configure): Return 1 for success.
358 (sim_prepare_for_program): Use the sim_hw_configure exit code to
359 return SIM_RC_FAIL.
360
361 2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
362
363 * dv-m68hc11.c (m68hc11cpu_io_read_buffer): Translate memory
364 bank window to some virtual address to read from extended memory.
365 (m68hc11cpu_io_write_buffer): Likewise for writing.
366 (attach_m68hc11_regs): When use_bank property is defined, attach
367 to the 68HC12 16K memory bank window.
368 * interp.c (sim_hw_configure): Create memory region for banked
369 memory.
370
371 2002-08-13 Stephane Carrez <Stephane.Carrez@nerim.fr>
372
373 * interp.c (sim_hw_configure): Connect port-X to cpu-write-port.
374 * dv-m68hc11.c (m68hc11cpu_ports): Add cpu-write-port input.
375 (m68hc11cpu_port_event): Handle CPU_WRITE_PORT event.
376
377 2002-08-13 Marko Kohtala <marko.kohtala@luukku.com>
378
379 * dv-m68hc11.c (m68hc11cpu_io_write): Fix to update IO mapping
380 when IO mapping changed, not when internal RAM mapping is changed.
381
382 2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
383
384 * m68hc11_sim.c (cpu_special): Handle call and rtc instructions.
385 * sim-main.h (M6812_CALL_INDIRECT): Add to enum.
386 (m6811_regs): Add page register.
387 (cpu_set_page, cpu_get_page): New macros.
388 (phys_to_virt): New function.
389 (cpu_get_indexed_operand_addr, cpu_return): Declare.
390 * gencode.c: Identify indirect addressing mode for call and fix daa.
391 (gen_function_entry): New param to tell if src8/dst8 locals are
392 necessary.
393 (gen_interpreter): Use it to avoid generation of unused variables.
394 * interp.c (sim_fetch_register): Allow to read page register; page
395 register, A, B and CCR are only 1 byte wide.
396 (sim_store_register): Likewise for writing.
397
398 2002-06-16 Andrew Cagney <ac131313@redhat.com>
399
400 * configure: Regenerated to track ../common/aclocal.m4 changes.
401
402 2002-06-09 Andrew Cagney <cagney@redhat.com>
403
404 * Makefile.in (INCLUDE): Update path to callback.h.
405 * sim-main.h: Include "gdb/callback.h" and "gdb/remote-sim.h".
406
407 2002-03-07 Stephane Carrez <Stephane.Carrez@worldnet.fr>
408
409 * m68hc11_sim.c (cpu_move8): Call sim_engine_abort in default case.
410 (cpu_move16): Likewise.
411 (sim_memory_error): Use sim_io_printf.
412 (cpu_option_handler): Fix compilation warning.
413 * interp.c (sim_hw_configure): Fix compilation warning;
414 remove m68hc12sio@2 device.
415 (sim_open): Likewise.
416 * dv-m68hc11tim.c (m68hc11tim_port_event): Fix clear of TFLG2
417 flags when reset.
418 (cycle_to_string): Improve convertion of cpu cycle number.
419 (m68hc11tim_info): Print info about PACNT.
420 (m68hc11tim_io_write_buffer): Fix clearing of TFLG2; handle
421 TCTL1 and TCTL2 registers.
422 * dv-m68hc11.c (m68hc11_info): Print 6811 current running mode.
423
424 2002-03-07 Stephane Carrez <Stephane.Carrez@worldnet.fr>
425
426 * interp.c (sim_hw_configure): Save the HW cpu pointer in the
427 cpu struct.
428 (sim_hw_configure): Connect the capture input/output events.
429 * sim-main.h (_sim_cpu): New member hw_cpu.
430 (m68hc11cpu_set_oscillator): Declare.
431 (m68hc11cpu_clear_oscillator): Declare.
432 (m68hc11cpu_set_port): Declare.
433 * dv-m68hc11.c (m68hc11_options): New for oscillator commands.
434 (m68hc11cpu_ports): New input ports and output ports to reflect
435 the HC11 IOs.
436 (m68hc11_delete): Cleanup any running oscillator.
437 (attach_m68hc11_regs): Create the input oscillators.
438 (make_oscillator): New function.
439 (find_oscillator): New function.
440 (oscillator_handler): New function.
441 (reset_oscillators): New function.
442 (m68hc11cpu_port_event): Handle the new input ports.
443 (m68hc11cpu_set_oscillator): New function.
444 (m68hc11cpu_clear_oscillator): New function.
445 (get_frequency): New function.
446 (m68hc11_option_handler): New function.
447 (m68hc11cpu_set_port): New function.
448 (m68hc11cpu_io_write): Post the port output events.
449 * dv-m68hc11spi.c (set_bit_port): Use m68hc11cpu_set_port to set
450 the output port value.
451 * dv-m68hc11tim.c (m68hc11tim_port_event): Handle CAPTURE event
452 by latching the TCNT value in the register.
453
454 2002-03-07 Stephane Carrez <Stephane.Carrez@worldnet.fr>
455
456 * sim-main.h (cpu_frame, cpu_frame_list): Remove.
457 (cpu_frame_reg, cpu_print_frame): Remove.
458 (cpu_m68hc11_push_uint8, cpu_m68hc11_pop_uint8): Cleanup.
459 (cpu_m68hc11_push_uint16, cpu_m68hc11_pop_uint16): Likewise.
460 (cpu_m68hc12_push_uint8, cpu_m68hc12_push_uint16): Likewise.
461 (cpu_m68hc12_pop_uint8, cpu_m68hc12_pop_uint16): Likewise.
462 * m68hc11_sim.c (cpu_find_frame): Remove.
463 (cpu_create_frame_list): Remove.
464 (cpu_remove_frame_list, cpu_create_frame, cpu_free_frame): Remove.
465 (cpu_frame_reg, cpu_print_frame, cpu_update_frame): Remove.
466 (cpu_call): Cleanup to remove #if HAVE_FRAME and calls to the above.
467 (cpu_update_frame): Likewise.
468 (cpu_return): Likewise.
469 (cpu_reset): Likewise.
470 (cpu_initialize): Likewise.
471 * interp.c (sim_do_command): Remove call to cpu_print_frame.
472
473 2002-03-07 Stephane Carrez <Stephane.Carrez@worldnet.fr>
474
475 * interrupts.c (interrupts_reset): New function, setup interrupt
476 vector address according to cpu mode.
477 (interrupts_initialize): Move reset portion to the above.
478 (interrupt_names): New table to give a name to interrupts.
479 (idefs): Handle pulse accumulator interrupts.
480 (interrupts_info): Print the interrupt history.
481 (interrupt_option_handler): New function.
482 (interrupt_options): New table of options.
483 (interrupts_update_pending): Keep track of when interrupts are
484 raised and implement breakpoint-on-raise-interrupt.
485 (interrupts_process): Keep track of when interrupts are taken
486 and implement breakpoint-on-interrupt.
487 * interrupts.h (struct interrupt_history): Define.
488 (struct interrupt): Keep track of the interrupt history.
489 (interrupts_reset): Declare.
490 (interrupts_initialize): Update prototype.
491 * m68hc11_sim.c (cpu_reset): Reset interrupts.
492 (cpu_initialize): Cleanup.
493
494 2001-07-28 Stephane Carrez <Stephane.Carrez@worldnet.fr>
495
496 * dv-m68hc11eepr.c (m68hc11eepr_info): Fix print of current write
497 address.
498 (m68hc11eepr_port_event): Fix detach/attach logic.
499
500 2001-07-22 Stephane Carrez <Stephane.Carrez@worldnet.fr>
501
502 * Makefile.in (SIM_OBJS): Remove sim-resume.o
503 * interp.c (sim_resume): New function from sim-resume.c, install
504 the stepping event after having processed the pending ticks.
505 (has_stepped): Likewise.
506 (sim_info): Produce an output only if verbose or STATE_VERBOSE_P.
507
508 2001-07-10 Andrew Cagney <ac131313@redhat.com>
509
510 * Makefile.in (gencode): Provide explicit path to gencode.c.
511
512 2001-05-20 Stephane Carrez <Stephane.Carrez@worldnet.fr>
513
514 * Makefile.in (M68HC11_OBJS): Add m68hc12int.o.
515 (m68hc12int.c): Generate using gencode -m6812.
516 (m68hc11int.c): Likewise with -m6811.
517
518 * gencode.c (m6811_opcode_patterns): New patterns for 68HC12.
519 (m6811_page1_opcodes): Remove duplicate entries.
520 (m6811_page2_opcodes): Likewise.
521 (m6811_page3_opcodes): Likewise.
522 (m6811_page4_opcodes): Likewise.
523 (m6812_page1_opcodes): New table for 68HC12 instructions.
524 (m6812_page2_opcodes): Likewise.
525 (gen_fetch_operands): New modes [] and &[] for 68HC12 operands.
526 (gen_save_result): Likewise.
527 (gen_interpreter_for_table): Handle 68HC11 and 68HC12 opcodes.
528 (cmp_opcode): New function for opcode comparision.
529 (prepare_table): Sort the opcodes.
530 (gen_interpreter): Prepare all the tables and generate either
531 a 68HC11 or a 68HC12 simulator.
532 (main): New options -m6811 and -m6812.
533
534 * m68hc11_sim.c (cpu_single_step): Use pointer to cpu interpretor.
535 (cpu_special): Simulation of some 68HC12 instructions.
536 (cpu_exg): New function.
537 (cpu_dbcc): Likewise.
538 (cpu_fetch_relbranch16): Likewise.
539 (cpu_push_all): Push according to 68HC11 or 68HC12.
540 (cpu_move16): Likewise.
541 (cpu_move8): Likewise.
542 (cpu_get_indexed_operand16): Likewise.
543 (cpu_get_indexed_operand8): Likewise.
544 (cpu_get_indexed_operand_addr): Likewise.
545 (cpu_set_reg, cpu_set_dst_reg, cpu_get_src_reg, cpu_get_reg): Likewise.
546 (cpu_reset): Setup INIT register according to architecture.
547
548 * sim-main.h (M6811_Special): Add 68HC12 specific instructions.
549 (_sim_cpu): Keep track of the cpu being simulated.
550 (cpu_get_tmp3, cpu_get_tmp2, cpu_set_tmp3, cpu_set_tmp2): New.
551 (cpu_m68hc11_push_uintxx): Rename of cpu_push_uintxx.
552 (cpu_m68hc11_pop_uint8): Likewise.
553 (cpu_m68hc12_push_uintxx): New functions for 68HC12.
554 (cpu_m68hc12_pop_uintxx): Likewise.
555 (cpu_exg, cpu_dbcc, cpu_move8, cpu_move16): Likewise,
556 (cpu_fetch_relbranch16): Likewise.
557 (cpu_interp_m6811): Rename of cpu_interp.
558 (cpu_interp_m6812): New function.
559 * interp.c (free_state): New function.
560 (dev_list_68hc12): New table.
561 (sim_board_reset): Reset depending on the cpu (HC11 or HC12).
562 (sim_hw_configure): New function.
563 (sim_prepare_for_program): New function.
564 (sim_open): Use above new functions.
565 (sim_close): Call free_state().
566 (sim_info): Print info according to cpu.
567 (sim_create_inferior): Use sim_prepare_for_program.
568 (sim_do_command): Configure the hardware after a change of the
569 architecture.
570
571 2001-05-20 Stephane Carrez <Stephane.Carrez@worldnet.fr>
572
573 * dv-m68hc11sio.c (m68hc11sio_tx_poll): Always check for
574 pending interrupts.
575 * interrupts.c (interrupts_process): Keep track of the last number
576 of masked insn cycles.
577 (interrupts_initialize): Clear last number of masked insn cycles.
578 (interrupts_info): Report them.
579 (interrupts_update_pending): Compute clear and set masks of
580 interrupts and clear the interrupt bits before setting them
581 (due to SCI interrupt sharing).
582 * interrupts.h (struct interrupts): New members last_mask_cycles
583 and xirq_last_mask_cycles.
584
585 2000-11-26 Stephane Carrez <Stephane.Carrez@worldnet.fr>
586
587 * dv-m68hc11.c (m68hc11cpu_io_read_buffer): Use attach_size
588 instead of a hard-coded value.
589 (m68hc11cpu_io_write_buffer): Likewise.
590 (dv_m68hc11_descriptor): Define a 68hc12 device.
591 * dv-m68hc11eepr.c (dv_m68hc11eepr_descriptor): Likewise.
592 * dv-m68hc11tim.c (dv_m68hc11tim_descriptor): Likewise.
593 * dv-m68hc11spi.c (dv_m68hc11spi_descriptor): Likewise.
594 * dv-m68hc11sio.c (dv_m68hc11sio_descriptor): Likewise.
595
596 2000-11-22 Stephane Carrez <Stephane.Carrez@worldnet.fr>
597
598 * dv-m68hc11.c (attach_m68hc11_regs): Register a delete handler.
599 (m68hc11cpu_delete): Delete handler to detach the address space.
600
601 2000-11-24 Stephane Carrez <Stephane.Carrez@worldnet.fr>
602
603 * dv-m68hc11eepr.c (attach_m68hc11eepr_regs): Use hw_malloc.
604 * dv-nvram.c (attach_nvram_regs): Use hw_free and hw_malloc
605 instead of free and malloc.
606
607 2000-09-11 Stephane Carrez <Stephane.Carrez@worldnet.fr>
608
609 * Makefile.in: Was missing from initial patch.
610
611 2000-09-10 Stephane Carrez <Stephane.Carrez@worldnet.fr>
612
613 * interp.c (sim_store_register): Remove soft register hack.
614 (sim_fetch_register): Likewise.
615 (sim_create_inferior): Likewise.
616 * sim-main.h: Likewise.
617
618 2000-09-10 Stephane Carrez <Stephane.Carrez@worldnet.fr>
619
620 * interrupts.c (interrupts_update_pending): Clear the mask of
621 pending interrupts here.
622 (interrupts_get_current): Don't clear the mask of pending interrupts.
623
624 2000-09-10 Stephane Carrez <Stephane.Carrez@worldnet.fr>
625
626 * sim-main.h: Define cycle_to_string.
627 * dv-m68hc11tim.c (cycle_to_string): New function to translate
628 the cpu cycle into some formatted time string.
629 (m68hc11tim_print_timer): Use it.
630 * dv-m68hc11sio.c (m68hc11sio_info): Use cycle_to_string.
631 * dv-m68hc11spi.c (m68hc11spi_info): Likewise.
632 * interrupts.c (interrupts_info): Likewise.
633 * m68hc11_sim.c (cpu_info): Likewise.
634
635 2000-09-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
636
637 * dv-m68hc11tim.c (m68hc11tim_timer_event): Compute the overflow
638 interrupt and compare events accurately. Take into account the
639 pending ticks not processed by the simulator yet (introduced a shift).
640 (m68hc11_port_event): Reset the timer interrupt delays.
641 (m68hc11tim_io_read_buffer): Be able to read several bytes.
642 (m68hc11tim_io_write_buffer): Likewise for write.
643 (m68hc11tim_io_write_buffer): Recompute the timer overflow interrupt.
644
645 2000-09-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
646
647 * dv-m68hc11spi.c (m68hc11spi_io_read_buffer): Clear the interrupts.
648 (m68hc11spi_io_write_buffer): Likewise and fix the spi frame.
649 (m68hc11spi_info): Clarify the status report
650 of the SPI when a byte is being sent.
651 (m68hc11spi_clock): Fix the spi send frame.
652
653 2000-08-11 Stephane Carrez <Stephane.Carrez@worldnet.fr>
654
655 * sim-main.h (m68hc11_map_level): Define level of address mappings.
656 * dv-m68hc11eepr.c (struct m68hc11eepr ): New flag to indicate
657 whether the eeprom is currently mapped or not.
658 (m68hc11eepr_port_event): Use the flag to see if we must unmap
659 or map the eeprom. Update the flag to reflect the current state.
660 Use M6811_EEPROM_LEVEL when mapping the eeprom.
661 (m68hc11eepr_finish): Remove overlap hack.
662 (attach_m68hc11eepr_regs): Use M6811_IO_LEVEL when mapping the
663 config and control registers.
664 * dv-m68hc11.c (m68hc11cpu_finish): Remove overlap hack.
665 (attach_m68hc11_regs): Use M6811_IO_LEVEL.
666 (m68hc11cpu_io_write): Likewise when unmapping and re-mapping.
667 * dv-m68hc11spi.c (m68hc11spi_finish): Likewise.
668 (attach_m68hc11spi_regs): Likewise.
669 * dv-m68hc11tim.c (m68hc11tim_finish): Likewise.
670 (attach_m68hc11tim_regs): Likewise.
671 * dv-m68hc11sio.c (m68hc11sio_finish): Likewise.
672 (attach_m68hc11sio_regs): Likewise.
673 * interp.c (sim_open): Likewise.
674 * dv-nvram.c (attach_nvram_regs): Likewise.
675
676 Thu Jul 27 21:27:25 2000 Andrew Cagney <cagney@b1.cygnus.com>
677
678 * configure, config.in: Regenerate.
679
680 2000-06-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>
681
682 * Makefile.in (SIM_RUN_OBJS): Define to use nrun.c
683 * dv-m68hc11.c (m68hc11cpu_finish): Register detach address callback.
684 (dv_m6811_detach_address_callback): New function to detach a
685 device from an address space.
686 * dv-m68hc11eepr.c (m68hc11eepr_port_event): Initialize
687 config register according to --cpu-config option.
688 * sim-main.h (_sim_cpu): Add cpu_config member.
689 * interp.c (sim_open): Delete specific simulator options.
690 * m68hc11_sim.c (cpu_option_handler): New options
691 --emulos and -cpu-config <val> to configure the simulator.
692 (cpu_initialize): Initialize cpu_config member.
693
694 2000-06-24 Stephane Carrez <Stephane.Carrez@worldnet.fr>
695
696 * emulos.c: Fix indentation and comments.
697 * gencode.c: Likewise.
698 * dv-m68hc11tim.c (m68hc11tim_timer_event): Handle COMPARE_EVENT.
699 (m68hc11tim_io_write_buffer): Write compare registers and
700 setup compare event.
701 * interp.c: Remove unused global variables.
702 * interrupts.c (idefs): New compare interrupts.
703 Fix indentation and comments.
704 * interrupts.h: Likewise.
705
706 2000-06-18 Stephane Carrez <Stephane.Carrez@worldnet.fr>
707
708 * dv-m68hc11sio.c: Fix indentation and comments.
709 Remove INT_PORT.
710 * dv-m68hc11.c: Fix indentation and comments.
711 (m68hc11cpu_port_event): Move initialization of M6811_HPRIO from here.
712 * m68hc11_sim.c (cpu_reset): To here.
713 * dv-m68hc11eepr.c: Fix indentation and comments.
714
715 2000-06-17 Stephane Carrez <Stephane.Carrez@worldnet.fr>
716
717 * dv-nvram.c: New file, rename from dv-pram.c.
718 * dv-pram.c: Delete file.
719 * sim-main.h: Incorporate m68hc11_sim.h.
720 * m68hc11_sim.h: Delete file.
721 * configure.in: Rename pram into nvram.
722 * interp.c (sim_open): Likewise in creation of device tree.
723
724 2000-05-31 Stephane Carrez <Stephane.Carrez@worldnet.fr>
725
726 * interp.c (sim_open): Create the SPI device.
727 * dv-m68hc11spi.c: New file for SPI device simulation.
728 * configure.in (hw_extra_devices): Add SPI device.
729
730 2000-05-28 Stephane Carrez <Stephane.Carrez@worldnet.fr>
731
732 * interrupts.c (interrupts_initialize): Clear XIRQ accounting.
733 (interrupts_process): Separate IRQ and XIRQ accounting.
734 (interrupts_info): Report XIRQ accounting.
735 * interrupts.h (struct interrupts): Added accounting for XIRQ.
736
737 2000-04-16 Stephane Carrez <stcarrez@worldnet.fr>
738
739 * dv-pram.c (attach_pram_regs): Fix the 'save-modified' mode.
740 * m68hc11_sim.h (_sim_cpu): Allow configuration of cpu mode.
741 * dv-m68hc11.c (attach_m68hc11_regs): Get the cpu MODA,MODB
742 configuration from the 'mode' device tree property.
743 (m68hc11cpu_port_event): Reset M6811_HPRIO to the cpu MODA, MODB
744 configuration.
745
746 2000-02-24 Stephane Carrez <stcarrez@worldnet.fr>
747
748 * sim-main.h: Remove WITH_TARGET_* defines.
749 * Makefile.in (SIM_EXTRA_CFLAGS): Specify the WITH_TARGET_* flags.
750
751 2000-02-08 Stephane Carrez <stcarrez@worldnet.fr>
752
753 * dv-m68hc11sio.c (m68hc11sio_port_event): Setup the SCI to
754 1200 baud when cpu is in bootstrap mode.
755
756 * dv-m68hc11tim.c (m68hc11tim_io_write_buffer): Be able to
757 write in the TCTN timer register.
758
759 * dv-m68hc11sio.c (m68hc11sio_io_write_buffer): Divide cpu clock
760 by 4 to obtain the E clock frequency.
761 (sccr2_desc): Use M6811_TIE for TIE bit.
762 (m68hc11sio_info): Fix baud rate report.
763
764 * dv-m68hc11tim.c (to_realtime): Likewise.
765
766 * interp.c (sim_open): When building device tree, only provide
767 devices that do not exist yet.
768
769 * emulos.c: Fix compilation pb under Windows.
770
771 * dv-m68hc11.c (attach_m68hc11_regs): Get the clock frequency
772 from the 'clock' property.
773
774 2000-01-02 Stephane Carrez <stcarrez@worldnet.fr>
775
776 * m68hc11_sim.h (*_REGNUM): Define.
777 (_sim_cpu): New member cpu_page0_reg table.
778 * interp.c (sim_create_inferior): Fill the cpu_page0_reg table with
779 addresses of soft registers in .page0.
780 (sim_fetch_register, sim_store_register): Use cpu_page0_reg table
781 to get/set soft registers.
782
783 1999-12-31 Stephane Carrez <stcarrez@worldnet.fr>
784
785 * dv-m68hc11.c (m68hc11cpu_io_write_buffer): Clear byte to avoid
786 returning random values.
787
788 1999-12-17 Stephane Carrez <stcarrez@worldnet.fr>
789
790 * gencode.c: Fix "subb N,x" that used a instead of b.
791
792 1999-09-09 Stephane Carrez <stcarrez@worldnet.fr>
793
794 * gencode.c: Fixed sbc8 and adc8 when there was a initial carry.
795
796 1999-09-01 Stephane Carrez <stcarrez@worldnet.fr>
797
798 * sim-main.h (SIM_HANDLES_LMA): Define to enable loading using lma.
799
800 1999-08-14 Stephane Carrez <stcarrez@worldnet.fr>
801
802 * dv-m68hc11.c (attach_m68hc11_regs): Save the size of the
803 register region in the m68hc11cpu struct.
804 (m68hc11cpu_io_write): When the IO mapping addres changes,
805 detach the register region and re-attach it at the new address.
806 (m68hc11cpu_io_read_buffer): Renamed base_address into
807 attach_address.
808 (m68hc11cpu_io_write_buffer): Likewise. Pass the hw pointer
809 to m68hc11cpu_io_write.
810
811 1999-08-13 Stephane Carrez <stcarrez@worldnet.fr>
812
813 * gencode.c: For sbc8, check the carry and increment the source
814 before trying to set the carry for the result.
815
816 1999-05-24 John S. Kallal <kallal@voicenet.com>
817
818 * interp.c (sim_get_info): Don't crash if the command line is 0.
819 Define prototype for sim_get_info() and init_system().
820 (sim_info): Correct call to sim_get_info().
821
822 1999-05-16 Stephane Carrez <stcarrez@worldnet.fr>
823
824 * configure.in: Recognize m6811-*-*.
825 * configure: Regenerate.
826 * m68hc11_sim.h (cpu_ccr_update_add8, cpu_ccr_update_add16,
827 cpu_ccr_update_sub8, cpu_ccr_update_sub16):
828 Correct the computation of carry of 8 and 16-bits add and subtract.
829 * gencode.c: Use cpu_ccr_update_sub8 for subtraction (carry and
830 overflow set in a different manner than add).
831
832 1999-05-14 Stephane Carrez <stcarrez@worldnet.fr>
833
834 * dv-m68hc11.c (dv_m6811_attach_address_callback): Removed a
835 trace message.
836 * interp.c (sim_open, sim_create_inferior): Initialize the
837 cpu_elf_start from the ELF header.
838 * m68hc11_sim.c (cpu_initialize): Clear the new data members.
839 (cpu_restart): Use cpu_elf_start as the starting address when
840 the flag is set.
841 (cpu_special): When cpu_use_elf_start is set, the WAI instruction
842 exits the simulator (exit status is in D).
843 * m68hc11_sim.h (_sim_cpu): Added members cpu_use_elf_start and
844 cpu_elf_star to start execution at address specified in ELF file.
845
846 1999-05-02 Stephane Carrez <stcarrez@worldnet.fr>
847
848 * Makefile.in, config.in, configure, configure.in: New files.
849 * gencode.c: New file, generation of 68HC11 interpreter.
850 * m68hc11_sim.h, m68hc11_sim.c: New files, specific operations
851 for interpreter.
852 * interrupts.c, interrupts.h: New files, management of interrupts.
853 * interp.c, sim-main.h,
854 * dv-m68hc11.c, dv-m68hc11eepr.c, dv-m68hc11sio.c,
855 dv-m68hc11tim.c, dv-pram.c: New files representing devices for
856 68HC11 (dv-pram.c is generic and could probably migrate to common).
857 * emulos.c: New file, basic emulation of some os.