[gdbserver/rfa] CRIS/CRISv32 gdbserver support (part 2)
Orjan Friberg
orjan.friberg@axis.com
Tue Feb 1 14:31:00 GMT 2005
Daniel Jacobowitz wrote:
>
> - cris and crisv32 appear to have, from point of view of gdbserver, not
> much more in common than cris and mips. How about having
> linux-crisv32-low.c instead? There can be additional file for common
> code if it becomes necessary in the future.
Good idea; I split them up as suggested.
>>static CORE_ADDR
>>cris_reinsert_addr ()
>>{
>> unsigned long pc;
>> collect_register_by_name ("srp", &pc);
>> return pc;
>>}
>
>
> I gather that you don't have PTRACE_SINGLESTEP on cris; not even on
> crisv32?
On CRISv32 I do; thanks for catching this (I removed reinsert_addr for CRISv32).
>>#ifdef __arch_v32
>>void
>>cris_write_data_breakpoint (int bp, unsigned long start, unsigned long end)
>>{
>> switch (bp)
>> {
>> case 0:
>> supply_register_by_name("s3", &start);
>> supply_register_by_name("s4", &end);
>> break;
>
>
> What to do about the threaded case? GDB is having so much trouble
> getting it right that I'd like to make sure gdbserver does from the
> start.
>
> I guess this can be handled completely in the linux-low wrapper
> functions by switching the current thread and setting watchpoints for
> each. I think that is correct for all Linux targets using hardware
> watchpoints, because of the nature of Linux threading.
For CRISv32, there might be an additional problem lurking in the shadows: we
treat the watchpoint registers as global (i.e., only one process at a time can
use them, and thus they are not saved/restored on context switches etc).
Anyway, is this something you want resolved before I commit the CRIS/CRISv32
support? (Here's an updated ChangeLog entry and updated patches if not.)
2005-02-01 Orjan Friberg <orjanf@axis.com>
* linux-cris-low.c: New file with support for CRIS.
* linux-crisv32-low.c: Ditto for CRISv32.
* Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
(clean): Add reg-cris.c and reg-crisv32.c.
Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
reg-crisv32.o, and reg-crisv32.c to make rules.
* configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
recognized targets.
--
Orjan Friberg
Axis Communications
-------------- next part --------------
A non-text attachment was scrubbed...
Name: linux-cris-low.c
Type: text/x-csrc
Size: 2878 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20050201/6df39f90/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: linux-crisv32-low.c
Type: text/x-csrc
Size: 9614 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20050201/6df39f90/attachment-0001.bin>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20050201/6df39f90/attachment.ksh>
More information about the Gdb-patches
mailing list