Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: "André Pönitz" <apoenitz@trolltech.com>
To: gdb@sourceware.org
Subject: Re: problem with gdb's 'call'
Date: Tue, 12 Aug 2008 21:10:00 -0000	[thread overview]
Message-ID: <200808121727.40394.apoenitz@trolltech.com> (raw)
In-Reply-To: <20080812143945.GA5050@caradoc.them.org>

On Tuesday 12 August 2008 16:39:45 Daniel Jacobowitz wrote:
> On Tue, Aug 12, 2008 at 04:36:40PM +0200, André Pönitz wrote:
> >   (gdb) p _Z3fooIiET_v
> >   $1 = {int (void)} 0x400544 <int foo<int>()>
> > 
> >   (gdb) call _Z3fooIiET_v()
> >    /build/buildd/gdb-6.8/gdb/valops.c:2069: internal-error: find_oload_champ_namespace_loop:
> >    Assertion    `new_oload_champ != -1' failed.
> >    A problem internal to GDB has been detected,
> 
> I've seen this error recently, with pointers to members.  I don't
> think my patches will fix this particular case (the OP_VAR_VALUE
> rather than STRUCTOP_MPTR case).
> 
> > I already use the mangled name of the symbol as I did not find a way to
> > quote  'call  foo<int>()' in a way that looks acceptable to gdb.
> 
> It's because of the templated return type.  The quoting that works
> today is (gross, I know):
> 
>   p 'int foo<int>'()
> 
> But it doesn't help, there's the same error.

I noticed in the mean time that

  set demangle-style none 

helps to prevent the crash. Together with your hint this might
already be 'some kind of "solution"' ;-)

> > Is there a way to make the gdb core accept the mangled name without
> > attempting to demangling it (to avoid the crash)?
> 
> The crash has nothing to do with demangling, but you can disable
> overload resolution and that should help.  "set overload-resolution
> off".

Is there somewhere a description in what code paths setting variables
like   overload-resolution  or   demangle-style  has an effect?

> Or just fix the bug :-)

;-} That's certainly the best solution for the long run. In the short term
I have to live with debuggers that are already released....

André




  reply	other threads:[~2008-08-12 15:25 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-12 15:30 André Pönitz
2008-08-12 16:12 ` Daniel Jacobowitz
2008-08-12 21:10   ` André Pönitz [this message]
2008-08-12 22:51     ` Daniel Jacobowitz
2008-08-12 19:30 ` Andreas Schwab

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=200808121727.40394.apoenitz@trolltech.com \
    --to=apoenitz@trolltech.com \
    --cc=gdb@sourceware.org \
    /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