From: Tom Tromey <tromey@redhat.com>
To: asmwarrior <asmwarrior@gmail.com>
Cc: gdb@sourceware.org, pmuldoon@redhat.com, andre.poenitz@nokia.com
Subject: Re: gdb with python support still get crash on showing uninitialized local variables
Date: Fri, 15 Oct 2010 22:37:00 -0000 [thread overview]
Message-ID: <m3tykn2id8.fsf@fleche.redhat.com> (raw)
In-Reply-To: <4CB66700.3000907@gmail.com> (asmwarrior@gmail.com's message of "Thu, 14 Oct 2010 10:12:16 +0800")
>>>>> ">" == Asm gmail <asmwarrior@gmail.com> writes:
>> Hi, I still get gdb crashed when showing local variables.
>> stdStr = Traceback (most recent call last):
>> File "D:\code\mingw451tdm\bin\libstdcxx\v6\printers.py", line 549, in
>> to_string
>> return self.val['_M_dataplus']['_M_p'].lazy_string (length = len)
>> OverflowError: long int too large to convert to int
Interesting. Maybe a bug in valpy_lazy_string.
Could you file this as a bug report?
>> m = std::map with 2009251885 elementsTraceback (most recent call last):
>> File "D:\code\mingw451tdm\bin\libstdcxx\v6\printers.py", line 353, in next
>> n = self.rbiter.next()
>> File "D:\code\mingw451tdm\bin\libstdcxx\v6\printers.py", line 297, in next
>> if node.dereference()['_M_right']:
>> RuntimeError: Attempt to dereference a generic pointer.
I am going to guess g++ bug here, but I don't know for sure.
ISTR an open bug where sometimes g++ erroneously emits "void *".
>> stdStrRef =
>> s = std::stack wrapping: std::deque with -521291805 elements = {<error
>> reading variable s (Cannot access memory at address 0x80)>
I am working on a fix for this.
Currently all gdb exceptions are convert to a Python RuntimeError. But,
I think we should differentiate a little more. In particular, I think a
gdb MEMORY_ERROR should be a separate class, and should be handled
specially by the pretty-printing code (basically by omitting the stack
trace).
I think this, along with the default settings for limiting array and
string print sizes, should solve most cases of "corrupt data makes gdb
barf all over".
>> 3. gdb bugzilla
>> http://sourceware.org/bugzilla/show_bug.cgi?id=11407
I think this bug was specifically about errors causing the backtrace to
stop too early.
Please file bug reports when you run across oddities like these.
Although it sometimes takes a while, we do try to address them all.
Tom
next prev parent reply other threads:[~2010-10-15 22:37 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-14 2:16 asmwarrior
2010-10-14 18:30 ` André Pönitz
2010-10-15 3:55 ` asmwarrior
2010-10-15 22:38 ` Tom Tromey
2010-11-05 17:14 ` André Pönitz
2010-10-15 22:37 ` Tom Tromey [this message]
2010-10-16 1:14 ` asmwarrior
[not found] ` <m3fww2ued0.fsf_-_@fleche.redhat.com>
2010-10-20 5:19 ` asmwarrior
2010-10-20 5:33 ` asmwarrior
2010-10-22 19:13 ` Tom Tromey
2010-10-22 21:22 ` Eli Zaretskii
2010-10-29 19:18 ` Joel Brobecker
2010-10-29 22:01 ` Eli Zaretskii
2010-10-31 2:24 ` asmwarrior
2010-11-09 2:06 ` asmwarrior
2010-11-12 18:07 ` Tom Tromey
[not found] ` <4CE0C149.6090609@gmail.com>
2010-11-15 18:10 ` Tom Tromey
2010-12-14 2:13 ` asmwarrior
[not found] ` <4D06D1DB.1070501@gmail.com>
2010-12-14 15:00 ` Tom Tromey
2010-12-16 8:48 ` asmwarrior
[not found] ` <AANLkTinsJLTZT0ws=LbpYcq85_Z9_R=fcXz+J+kqScJU@mail.gmail.com>
2010-12-17 19:04 ` RFA: add python exception subclasses Tom Tromey
2010-12-18 2:26 ` asmwarrior
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=m3tykn2id8.fsf@fleche.redhat.com \
--to=tromey@redhat.com \
--cc=andre.poenitz@nokia.com \
--cc=asmwarrior@gmail.com \
--cc=gdb@sourceware.org \
--cc=pmuldoon@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