[hatari-devel] DSP debugging and breakpoints

npomarede at corp.free.fr npomarede at corp.free.fr
Sun Jun 7 19:24:02 CEST 2009


On Sun, 7 Jun 2009, Eero Tamminen wrote:

> Hi,
>
> On Sunday 07 June 2009, npomarede at corp.free.fr wrote:
>>>> I think we could have a command 'bl' that lists all breakpoint with
>>>> its index number.
>>>
>>> I.e. they would need to be stored also in the ascii format...
>>
>> Not necessarily, you could also "parse" the breakpoint structure and
>> generate the corresponding breakpoint ; this would not be exactly what
>> the user typed, but it should give the same result.
>
> It could be done much more conveniently when parsing the string.
> (at the same time it could output errors so that they point out *where*
> in the string the error is.)

I may have misexpressed myself ; the string must be parsed first, to build 
the corresponding breakpoint structure and report errors.

But if we later want to print the ascii representation of the structure, 
we can do it on the fly (but we could also save the input text, that would 
only be a few bytes anyway).


> Is the convenience the main point or them being independent from
> each other?
>
> If the independency, then I guess the break conditions would need
> to state whether the next condition continues the breakpoint (with
> AND) or is it a separate breakpoint.  That would avoid having multiple
> levels of structures for breakpoints, but all code dealing with them
> needs to handle it.
>

The independancy ; when specifying breakpoints from the command line, we 
could do :

./hatari -bp 'pc=1234 && d0=1' -bp 'pc=4567' -bp 'pc=7845'

This would create 3 breakpoints (thus using entries 0, 1 and 2 in 
CpuBreakPoint[]), the first one would be a 2 conditions breakpoint, while 
the 2 others ones would have only one condition (on a maximum of 6 
conditions per breakpoint for example)


Nicolas




More information about the hatari-devel mailing list