From: Jim Ingham <jingham@apple.com>
To: Daniel Jacobowitz <drow@false.org>
Cc: gdb-patches@sources.redhat.com
Subject: Re: Bug Fix: make_cv_type
Date: Thu, 13 May 2004 01:50:00 -0000 [thread overview]
Message-ID: <D3D75AF0-A47F-11D8-9F0A-000A277A8808@apple.com> (raw)
In-Reply-To: <20040512222914.GA6551@nevyn.them.org>
Grr... I keep forgetting the ChangeLog. Here:
2004-05-12 Jim Ingham <jingham@apple.com>
* gdbtypes.c (make_cv_type): We may be resolving an opaque
type as well as a stub type. So include that in the assert
when we are copying over a type from one objfile to another.
I don't have a simple test case - the bug showed up in DVD Studio Pro
which is anything but simple... You have to make a C++ shared library
with a type that gets exported in the main program as an opaque type,
not stub. I don't have time to construct this beast right now, I'll
try to get around to it when WWDC is over.
Jim
On May 12, 2004, at 3:29 PM, Daniel Jacobowitz wrote:
On Wed, May 12, 2004 at 03:24:16PM -0700, Jim Ingham wrote:
make_cv_type actually gets called in two ways that require it to fix
up
an unresolved type which could potentially get its complete type from
another objfile. One is then the input type is a stub. The other is
when the input type is an opaque type (TYPE_IS_OPAQUE). For an
instance of the latter, see check_typedef where is calls
lookup_transparent_type when it sees an opaque type.
But the second case in not accounted for in the gdb_assert in
make_cv_type. It should read:
Do you have a testcase (or ChangeLog entry :) for this?
Index: gdbtypes.c
===================================================================
RCS file: /cvs/src/src/gdb/gdbtypes.c,v
retrieving revision 1.82
diff -p -p -r1.82 gdbtypes.c
*** gdbtypes.c 9 Mar 2004 17:08:25 -0000 1.82
--- gdbtypes.c 12 May 2004 22:18:34 -0000
*************** make_cv_type (int cnst, int voltl, struc
*** 525,531 ****
to do is to copy the core type into the new objfile. */
gdb_assert (TYPE_OBJFILE (*typeptr) == TYPE_OBJFILE (type)
! || TYPE_STUB (*typeptr));
if (TYPE_OBJFILE (*typeptr) != TYPE_OBJFILE (type))
{
TYPE_MAIN_TYPE (*typeptr)
--- 525,531 ----
to do is to copy the core type into the new objfile. */
gdb_assert (TYPE_OBJFILE (*typeptr) == TYPE_OBJFILE (type)
! || (TYPE_STUB (*typeptr) || TYPE_IS_OPAQUE
(*typeptr)));
if (TYPE_OBJFILE (*typeptr) != TYPE_OBJFILE (type))
{
TYPE_MAIN_TYPE (*typeptr)
Jim
--
Jim Ingham jingham@apple.com
Developer Tools
Apple Computer
--
Daniel Jacobowitz
_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-
Jim Ingham
jingham@apple.com
Developer Tools - gdb
prev parent reply other threads:[~2004-05-13 1:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1AA36FBA-A463-11D8-9DB9-000A958F4C44@apple.com>
2004-05-12 22:29 ` Daniel Jacobowitz
2004-05-13 1:50 ` Jim Ingham [this message]
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=D3D75AF0-A47F-11D8-9F0A-000A277A8808@apple.com \
--to=jingham@apple.com \
--cc=drow@false.org \
--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