From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6671 invoked by alias); 23 Jun 2010 12:30:43 -0000 Received: (qmail 6648 invoked by uid 22791); 23 Jun 2010 12:30:39 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,TW_DB,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: sourceware.org Received: from mail-pw0-f41.google.com (HELO mail-pw0-f41.google.com) (209.85.160.41) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 23 Jun 2010 12:30:35 +0000 Received: by pwi7 with SMTP id 7so6368687pwi.0 for ; Wed, 23 Jun 2010 05:30:29 -0700 (PDT) Received: by 10.115.81.7 with SMTP id i7mr7486854wal.115.1277295811229; Wed, 23 Jun 2010 05:23:31 -0700 (PDT) Received: from [172.16.157.131] ([60.12.143.14]) by mx.google.com with ESMTPS id f11sm41743278wai.11.2010.06.23.05.23.27 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 23 Jun 2010 05:23:30 -0700 (PDT) Message-ID: <4C21FCDC.5050503@gmail.com> Date: Wed, 23 Jun 2010 12:30:00 -0000 From: asmwarrior User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.10) Gecko/20100512 Thunderbird/3.0.5 MIME-Version: 1.0 To: tromey@redhat.com CC: gdb@sourceware.org, libstdc++@gcc.gnu.org, Matthias Klose Subject: Re: Re: About the "info locals" command of gdb and python pretty printer References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2010-06/txt/msg00110.txt.bz2 Hi, I have two things to say: (it is both related to python pretty printer and the gdb, so I send it to both mail lists, sorry for the incovience) ------------------------------------------------------------------------------ 1, It seems the current SVN std python script didn't works any more. So, this my be a regression. svn://gcc.gnu.org/svn/gcc/trunk/libstdc++-v3/python It seems there is a commit in Revision: 161233 Author: doko Message: 2010-06-22 Matthias Klose * python/libstdcxx/v6/printers.py: Don't use string exceptions. ---- Modified : /trunk/libstdc++-v3/ChangeLog Modified : /trunk/libstdc++-v3/python/libstdcxx/v6/printers.py But I found that this revision didn't work any more, I try to print out some vector, list. (I have tested under Windows XP, MinGW 4.5 and MinGW 4.4.4, GDB cvs 20100623) All the response from gdb just gives the same as print /r XXXX. ------------------------------------------------------------------------------ 2, @tom On 3:59, Tom Tromey wrote: >>>>>> ">" == Asm gmail writes: > >>> At this time, if we run the "info locals" with python stl pretty >>> printer enabled, as you see, if you breakpoint is still at the first >>> line "int aaa = 1;", then bbbb and cccc are not initialized, this may >>> cause the python script to plot random values, some times, gdb or >>> python will get crashed. > > I think the real problem here is that gdb crashed. That should not > happen. Can you find out what went wrong? > > Python exceptions are "normal" in the sense that they should not cause > gdb any problems. > > We should fix the problem that exceptions during pretty-printing can > cause problems. I think there are a few parts to this. We > should differentiate the different types of gdb exception in Python, so > that things like memory errors can cause nicer behavior. We should also > make lazy strings truly lazy during printing. This will eliminate some > problems when trying to print a lazy string with length==-1. > > Tom Today, I have build gdb-cvs-20100623 , and try to make gdb crash on printing some uninitialized stl containers by pretty printers. But it stands through all the cases, so, it seems the gdb-cvs-20100623 is quite stable than the gdb-cvs-20100619. I'm not sure what has changed. It seems it more stable now. By the way, I will report if it crashed again. Thanks Asmwarrior ollydbg from codeblocks' forum.