Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@cygnus.com>
To: Jim Blandy <jimb@cygnus.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: RFA: relax restrictions on per-architecture data registration
Date: Wed, 06 Jun 2001 04:59:00 -0000	[thread overview]
Message-ID: <3B1E1B37.10209@cygnus.com> (raw)
In-Reply-To: <20010601233233.C19845E9CB@zwingli.cygnus.com>

> This is supposed to fix G++ V3 on non-multiarch targets.  Not sure
> this is right yet, just posting for the curious.
> 
> 2001-06-01  Jim Blandy  <jimb@redhat.com>
> 
> Expand the gdbarch per-architecture data vector as needed, rather
> 	than requiring that all per-architecture data be registered before
> 	the first gdbarch object is allocated.
> 	* gdbarch.sh: Changes to effect the following:
> 	* gdbarch.c (alloc_gdbarch_data, init_gdbarch_data): Delete
> 	declarations and definitions.
> 	(check_gdbarch_data): New function, and declaration.
> 	(gdbarch_alloc): Don't call alloc_gdbarch_data; leaving the fields
> 	zero is good enough.
> 	(free_gdbarch_data): Tolerate a null data pointer.  Free only
> 	those data items gdbarch->data actually has allocated.
> 	(set_gdbarch_data, gdbarch_data): Call check_gdbarch_data.
> 	(gdbarch_update_p): No need to call init_gdbarch_data.
> 
> 

Jim,

I think this is wrong.  GDB's startup sequence is currently something like:

	o	_initialize_*() registers any
		per-architecture data

	o	GDB creates the initial architecture

So that data buffer size would never change.

	Andrew

PS: xmalloc(size) == zrealloc (NULL, size)






  parent reply	other threads:[~2001-06-06  4:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20010601233233.C19845E9CB@zwingli.cygnus.com>
2001-06-01 20:54 ` PATCH: " Jim Blandy
2001-06-06  4:59 ` Andrew Cagney [this message]
2001-06-06  7:39   ` RFA: " Jim Blandy
2001-06-06  9:35     ` Andrew Cagney
2001-06-06  6:34 ` Andrew Cagney
2001-06-06  9:59   ` RFA: initialize per-arch data in startup_gdbarch Jim Blandy
2001-06-06 10:13     ` 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=3B1E1B37.10209@cygnus.com \
    --to=ac131313@cygnus.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=jimb@cygnus.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