[hatari-devel] Command completion added to debugger

Eero Tamminen eerot at users.berlios.de
Sun Sep 13 20:31:41 CEST 2009


HI,

On Friday 11 September 2009, Thomas Huth wrote:
> Eero Tamminen <eerot at users.berlios.de> wrote:
> > Btw. As debugger will at some point get IKBD debugging support, maybe
> > it would make sense to split the debugger code up a bit?
> >
> > I was thinking that I could (next week) move stuff to a "debugger/"
> > subdirectory where would eventually be following files:
> > 	breakcond.c
> > 	debugcpu.c
> > 	debugdsp.c
> > 	debugikbd.c
> > 	debugui.c  -- just the parsing
>
> Do you just want to split up debugui.c, or do you also want to move the
> code from falcon/dps_disasm.c and uae/newcpu.c? I wouldn't do the
> latter since this code comes from external projects, so it's easier to
> sync changes when you don't change it too much.

This meant the Hatari specific code in dsp.c which is not shared with
anything.  (register value printing etc which for m68k is currently in
debugui.c)



> Also, I would call that directory just "debug" instead of "debugger",
> then would could consider to move log.c there, too.

Good idea, I'll do that.


Btw.  It was a bit more work than I though because some things were directly
referring to some things.  For example uae-cpu/* stuff refers directly to
includes/*.h headers although uae-cpu/Makefile uses "-I../includes":
---------
$ grep includes */*.h
uae-cpu/hatari-glue.h:#include "../includes/cycles.h"
$ grep includes */*.c
uae-cpu/hatari-glue.c:#include "../includes/main.h"
uae-cpu/hatari-glue.c:#include "../includes/configuration.h"
uae-cpu/hatari-glue.c:#include "../includes/int.h"
uae-cpu/hatari-glue.c:#include "../includes/tos.h"
uae-cpu/hatari-glue.c:#include "../includes/gemdos.h"
uae-cpu/hatari-glue.c:#include "../includes/cart.h"
uae-cpu/hatari-glue.c:#include "../includes/vdi.h"
uae-cpu/hatari-glue.c:#include "../includes/stMemory.h"
uae-cpu/hatari-glue.c:#include "../includes/ikbd.h"
uae-cpu/hatari-glue.c:#include "../includes/video.h"
uae-cpu/memory.c:#include "../includes/main.h"
uae-cpu/memory.c:#include "../includes/tos.h"
uae-cpu/memory.c:#include "../includes/ide.h"
uae-cpu/memory.c:#include "../includes/ioMem.h"
uae-cpu/memory.c:#include "../includes/reset.h"
uae-cpu/memory.c:#include "../includes/stMemory.h"
uae-cpu/memory.c:#include "../includes/m68000.h"
uae-cpu/newcpu.c:#include "../includes/main.h"
uae-cpu/newcpu.c:#include "../includes/m68000.h"
uae-cpu/newcpu.c:#include "../includes/int.h"
uae-cpu/newcpu.c:#include "../includes/mfp.h"
uae-cpu/newcpu.c:#include "../includes/tos.h"
uae-cpu/newcpu.c:#include "../includes/vdi.h"
uae-cpu/newcpu.c:#include "../includes/cart.h"
uae-cpu/newcpu.c:#include "../includes/dialog.h"
uae-cpu/newcpu.c:#include "../includes/bios.h"
uae-cpu/newcpu.c:#include "../includes/xbios.h"
uae-cpu/newcpu.c:#include "../includes/video.h"
uae-cpu/newcpu.c:#include "../includes/options.h"
------------

Maybe "../includes/" prefix could be removed from these?


> > I'll add also a separate "t" / "trace" command for setting tracing
> > flags (it will make it easier to implement showing/completion for
> > trace flags).
>
> That's a good idea, always typing "setopt --trace ..." is quite
> annoying.
>
> > I could maybe also move:
> > * test stuff from breakcond.c to top level tests/ dir.
>
> Fine for me.
>
> > * number base and range parsing from str.c back to debugui.c as that
> > is only used in the debugger.
>
> I don't think that they will be used for something else, so you could
> move them back to the debugger, yes.

Ok, great!


> > * some of the stuff from falcon/dsp.c to debugger/debugdsp.c if I at
> > some point add support for completing DSP register names (more of
> >   a newbie "TAB" help command than really useful).
>
> Register names are three letters max ... is it really useful to have
> tab completion for that?

Not that much, I'll skip it.


	- Eero



More information about the hatari-devel mailing list