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