From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8566 invoked by alias); 13 Jul 2005 12:53:40 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 8297 invoked by uid 22791); 13 Jul 2005 12:53:34 -0000 Received: from pluton.ispras.ru (HELO pluton.ispras.ru) (83.149.199.253) by sourceware.org (qpsmtpd/0.30-dev) with SMTP; Wed, 13 Jul 2005 12:53:34 +0000 Received: (qmail 56671 invoked from network); 13 Jul 2005 12:50:11 -0000 Received: from unknown (HELO truba.ispras.ru) (83.149.198.41) by pluton.ispras.ru with SMTP; 13 Jul 2005 12:50:11 -0000 Received: from truba.ispras.ru (root@localhost) by truba.ispras.ru (8.13.1/8.13.1) with SMTP id j6DCXCac013192 for ; Wed, 13 Jul 2005 16:33:12 +0400 Received: from ispserv.ispras.ru (ispserv [83.149.198.72]) by truba.ispras.ru (8.13.1/8.13.1) with ESMTP id j6DCXCan013186 for ; Wed, 13 Jul 2005 16:33:12 +0400 Received: from ispserv.ispras.ru (localhost [127.0.0.1]) by ispserv.ispras.ru (8.12.8/8.12.8) with ESMTP id j6DCctwg006661 for ; Wed, 13 Jul 2005 16:38:55 +0400 Received: from localhost (kostik@localhost) by ispserv.ispras.ru (8.12.8/8.12.8/Submit) with ESMTP id j6DCctDs006657 for ; Wed, 13 Jul 2005 16:38:55 +0400 Date: Wed, 13 Jul 2005 12:53:00 -0000 From: Konstantin Karganov To: gdb@sources.redhat.com Subject: GDB is stepping past main() In-Reply-To: <42D62354.5090607@sakuraindustries.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SpamTest-Version: SMTP-Filter Version 2.0.0 [0125], KAS/Release SMTP-Filter Version 2.0.0 [0125], KAS/Release X-Spamtest-Info: Pass through X-SW-Source: 2005-07/txt/msg00145.txt.bz2 Hello, all. Why doesn't gdb stop at the main() end and continues to step further? Ok, it's not a big problem for human, but what should the frontend debugger do with unknown functions w/o source file positions? Test case: gcc 3.2.2 and gdb 6.3 on RH Linux, session log here: (gdb) br main Breakpoint 1 at 0x8048618: file tmp.cpp, line 7. (gdb) run Starting program: /home/kostik/Work/a.out Breakpoint 1, main (argc=1, argv=0xbffff2f4) at tmp.cpp:7 7 cout<<" Hello world! "<