From: Tom Tromey <tromey@redhat.com>
To: gdb-patches@sources.redhat.com
Subject: Re: [6/7] Introduce per-type architecture
Date: Fri, 26 Jun 2009 17:16:00 -0000 [thread overview]
Message-ID: <m3vdmidifv.fsf@fleche.redhat.com> (raw)
In-Reply-To: <200906261642.n5QGgLnP003891@d12av02.megacenter.de.ibm.com>
>>>>> "Ulrich" == Ulrich Weigand <uweigand@de.ibm.com> writes:
Ulrich> this patch finally adds an architecture reference to each type.
I read through this patch series. Well... I skimmed most of it, since
it mostly seemed mechanical.
It all seems reasonable to me.
Ulrich> In order to avoid growing the space-critical "struct type" or
Ulrich> "struct main_type", the existing reference to the objfile
Ulrich> associated with a type is replaced by a union that refers to
Ulrich> either an objfile or a gdbarch, depending on a new type flag.
Ulrich> The existing type allocation routines alloc_type and init_type
Ulrich> now always create per-objfile types; it is now a bug to call
Ulrich> them with a NULL objfile parameter. The helpers init_float_type,
Ulrich> init_complex_type, init_flags_type, and init_composite_type are
Ulrich> removed (and replaced by per-arch variants).
Ulrich> There is new routine alloc_type_arch that allocates a non-
Ulrich> objfile related type; you have to specify a (non-NULL) gdbarch
Ulrich> argument instead. A number of helper routines are provided
Ulrich> to simplify architecture-specific type creation (arch_type,
Ulrich> arch_integer_type, arch_character_type, arch_boolean_type,
Ulrich> arch_float_type, arch_complex_type, arch_flags_type, and
Ulrich> arch_composite_type).
Ulrich> Finally, if you want to allocate a new type with the same
Ulrich> ownership information (objfile or architecture) as an existing
Ulrich> type, you can use alloc_type_copy to do so.
I noticed that many of the new functions don't have introductory
comments. We've been asking everybody to write these recently; and I
think the quoted text here would be good to have in the code
somewhere. So, I would like to ask that this be split up and attached
to the appropriate functions.
Tom
next prev parent reply other threads:[~2009-06-26 17:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-26 16:42 Ulrich Weigand
2009-06-26 17:16 ` Tom Tromey [this message]
2009-06-26 17:30 Ulrich Weigand
2009-06-29 13:29 ` Ulrich Weigand
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=m3vdmidifv.fsf@fleche.redhat.com \
--to=tromey@redhat.com \
--cc=gdb-patches@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