Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@cygnus.com>
To: Daniel Jacobowitz <drow@mvista.com>
Cc: gdb@sources.redhat.com
Subject: Re: Regcache changes broke MIPS
Date: Sun, 09 Dec 2001 13:59:00 -0000	[thread overview]
Message-ID: <3C13D5AF.3020700@cygnus.com> (raw)
In-Reply-To: <20011208234027.A12988@nevyn.them.org>

>  mips_register_raw_size (int reg_nr)
> 420     {
> 421       if (mips64_transfers_32bit_regs_p)
> 422         return REGISTER_VIRTUAL_SIZE (reg_nr);
> 423       else if (reg_nr >= FP0_REGNUM && reg_nr < FP0_REGNUM + 32
> 424                && FP_REGISTER_DOUBLE)
> 425         /* For MIPS_ABI_N32 (for example) we need 8 byte floating point
> 426            registers.  */
> 427         return 8;
> 428       else
> 
> 
> I assume that this is because the target has not been initialized yet:
> #if GDB_MULTI_ARCH
> #undef FP_REGISTER_DOUBLE
> #define FP_REGISTER_DOUBLE (gdbarch_tdep (current_gdbarch)->mips_fp_register_double)
> #endif
> 
> You can't use multi-arched macros from _initialize_regcache, I think.


Grumph.

Because GDB isn't 100% multi-arch, it ends up having to use target 
macros from within _initialize_*().  Otherwize non- multi-arch code 
won't start up right.  When multi-arch is enabled, a dummy multi-arch 
vector is used.

Anyway, I think there is something even more messed up here.  First, I'm 
not sure why that function was called from within an _initialize*() 
function.  Secondly, the logic just looks backwards.

I'll do some pokeing.

enjoy,
Andrew


  reply	other threads:[~2001-12-09 21:59 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-12-08 20:41 Daniel Jacobowitz
2001-12-09 13:59 ` Andrew Cagney [this message]
2001-12-09 14:52   ` Andrew Cagney
2001-12-09 15:34     ` Daniel Jacobowitz
2001-12-09 19:09       ` Andrew Cagney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3C13D5AF.3020700@cygnus.com \
    --to=ac131313@cygnus.com \
    --cc=drow@mvista.com \
    --cc=gdb@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox