* [RFA] sim/ppc: stopgap for AltiVec
@ 2002-04-15 9:06 Elena Zannoni
2002-04-15 9:28 ` Andrew Cagney
0 siblings, 1 reply; 3+ messages in thread
From: Elena Zannoni @ 2002-04-15 9:06 UTC (permalink / raw)
To: gdb-patches
psim AltiVec support has not been committed yet, being still in
copyright limbo.
In the meantime, gdb will try to fetch/store AltiVec registers and the
simulator will error out. This happens for all the powerpc-*sim
targets.
As a stopgap, how about this patch?
Elena
2002-04-15 Elena Zannoni <ezannoni@redhat.com>
* sim_calls.c (sim_fetch_register, sim_store_register): Return -1 for
AltiVec registers as a temporary stopgap.
Index: sim_calls.c
===================================================================
RCS file: /cvs/src/src/sim/ppc/sim_calls.c,v
retrieving revision 1.3
diff -u -p -r1.3 sim_calls.c
--- sim_calls.c 15 Dec 2001 05:08:44 -0000 1.3
+++ sim_calls.c 15 Apr 2002 16:04:51 -0000
@@ -194,7 +194,11 @@ sim_fetch_register (SIM_DESC sd, int reg
But there are loops that just walk through the entire list of
names and try to get everything. */
regname = gdbarch_register_name (current_gdbarch, regno);
- if (! regname || regname[0] == '\0')
+ /* FIXME: ezannoni 2002/04/15 Remove the 'vr' and 'vscr' check
+ once AltiVec support is committed. */
+ if (! regname || regname[0] == '\0'
+ || (regname[0] == 'v' && regname[1] == 'r')
+ || (strcmp (regname, "vscr") == 0))
return -1;
TRACE(trace_gdb, ("sim_fetch_register(regno=%d(%s), buf=0x%lx)\n",
@@ -215,7 +219,11 @@ sim_store_register (SIM_DESC sd, int reg
/* See comments in sim_fetch_register, above. */
regname = gdbarch_register_name (current_gdbarch, regno);
- if (! regname || regname[0] == '\0')
+ /* FIXME: ezannoni 2002/04/15 Remove the 'vr' and 'vscr' check
+ once AltiVec support is committed. */
+ if (! regname || regname[0] == '\0'
+ || (regname[0] == 'v' && regname[1] == 'r')
+ || (strcmp (regname, "vscr") == 0))
return -1;
TRACE(trace_gdb, ("sim_store_register(regno=%d(%s), buf=0x%lx)\n",
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [RFA] sim/ppc: stopgap for AltiVec
2002-04-15 9:06 [RFA] sim/ppc: stopgap for AltiVec Elena Zannoni
@ 2002-04-15 9:28 ` Andrew Cagney
2002-04-15 9:33 ` Elena Zannoni
0 siblings, 1 reply; 3+ messages in thread
From: Andrew Cagney @ 2002-04-15 9:28 UTC (permalink / raw)
To: Elena Zannoni; +Cc: gdb-patches
Yes, thanks.
Andrew
> 2002-04-15 Elena Zannoni <ezannoni@redhat.com>
>
> * sim_calls.c (sim_fetch_register, sim_store_register): Return -1 for
> AltiVec registers as a temporary stopgap.
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [RFA] sim/ppc: stopgap for AltiVec
2002-04-15 9:28 ` Andrew Cagney
@ 2002-04-15 9:33 ` Elena Zannoni
0 siblings, 0 replies; 3+ messages in thread
From: Elena Zannoni @ 2002-04-15 9:33 UTC (permalink / raw)
To: Andrew Cagney; +Cc: Elena Zannoni, gdb-patches
Andrew Cagney writes:
> Yes, thanks.
> Andrew
> > 2002-04-15 Elena Zannoni <ezannoni@redhat.com>
> >
> > * sim_calls.c (sim_fetch_register, sim_store_register): Return -1 for
> > AltiVec registers as a temporary stopgap.
> >
> >
>
OK, it's in.
Elena
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2002-04-15 16:33 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-04-15 9:06 [RFA] sim/ppc: stopgap for AltiVec Elena Zannoni
2002-04-15 9:28 ` Andrew Cagney
2002-04-15 9:33 ` Elena Zannoni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox