This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC] New GDB Port CR16
- From: Pedro Alves <palves at redhat dot com>
- To: Kaushik Phatak <Kaushik dot Phatak at kpitcummins dot com>
- Cc: Mike Frysinger <vapier at gentoo dot org>, "gdb-patches at sourceware dot org" <gdb-patches at sourceware dot org>, Yao Qi <yao at codesourcery dot com>, Pedro Alves <palves at redhat dot com>
- Date: Fri, 07 Sep 2012 18:47:11 +0100
- Subject: Re: [RFC] New GDB Port CR16
- References: <C6CA53A2A46BA7469348BDBD663AB65845B27868@KCHJEXMB03.kpit.com> <503B9E59.6050502@codesourcery.com> <C6CA53A2A46BA7469348BDBD663AB65845B28084@KCHJEXMB03.kpit.com> <CAJaTeTrp4cCM6-0WybhzQnH_ZDBoa9xDhnW4+QGtaS7Un3Zv=Q@mail.gmail.com> <C6CA53A2A46BA7469348BDBD663AB65845B2866D@KCHJEXMB03.kpit.com> <504478D0.4040202@redhat.com> <CAJaTeTpaq+Z-K-21rht8MaTqoAcntMfd8mWRw9vVnFCU33ww6Q@mail.gmail.com> <C6CA53A2A46BA7469348BDBD663AB65845B296C5@KCHJEXMB03.kpit.com>
On 09/04/2012 07:49 AM, Kaushik Phatak wrote:
> Hi Pedro,
>> Is this dependency on host signal defines what is done on other sims?
> This was probably added when breakpoint support was being added to this
> sim port with reference of the SH port I believe.
>
>> there is cruft like this in other sims. it probably would be desirable to clean it up.
> Yes Mike, I agree. I have tested it without this hunk and breakpoints seem to
> work as expected. Please see below the patch that reverts this in sim.
> I am rearranging some code to create cr16-linux-tdep.c file as suggested by Yao
> and will post the gdb related patches soon.
> Thanks!
>
>
> 2012-09-03 Kaushik Phatak<kaushik.phatak@kpitcummins.com>
>
> sim/cr16/ChangeLog:
> * interp.c: Clean SIGBUS related macro.
>
> --- gdb_src.orig/sim/cr16/interp.c 2012-09-04 12:08:34.000000000 +0530
> +++ gdb_src/src/sim/cr16/interp.c 2012-06-18 05:04:17.000000000 +0530
> @@ -1192,11 +1192,7 @@ sim_resume (SIM_DESC sd, int step, int s
> iaddr = imem_addr ((uint32)PC);
> if (iaddr == State.mem.fault)
> {
> -#ifdef SIGBUS
> State.exception = SIGBUS;
> -#else
> - State.exception = SIGSEGV;
> -#endif
> break;
> }
Looks obvious enough to me.
Though, we should really get away with using host signals for this stuff,
using sim/gdb's own signal numbers instead. For a rainy day, perhaps...
--
Pedro Alves