From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8129 invoked by alias); 29 Nov 2001 07:31:26 -0000 Mailing-List: contact gdb-help@sourceware.cygnus.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 7889 invoked from network); 29 Nov 2001 07:31:16 -0000 Received: from unknown (HELO paysurfmail.sunrise.ch) (194.230.0.21) by hostedprojects.ges.redhat.com with SMTP; 29 Nov 2001 07:31:16 -0000 Received: from steg_1 (194.230.10.108) by paysurfmail.sunrise.ch (5.5.034) id 3BA89A72000BACE1; Thu, 29 Nov 2001 08:25:30 +0100 Message-Id: <4.2.0.58.20011129081742.00bdf940@pop.abatron.ch> X-Sender: abatron3@pop.abatron.ch X-Mailer: QUALCOMM Windows Eudora Pro Version 4.2.0.58 Date: Fri, 23 Nov 2001 08:56:00 -0000 To: Shaun Jackman From: Ruedi Dummermuth Subject: Re: gdb signal normal termination of program Cc: bgat@billgatliff.com,gdb@sources.redhat.com In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-SW-Source: 2001-11/txt/msg00225.txt.bz2 Hello Shaun The BDI cannot detect when you enter the exit() function unless you set a breakpoint in it. The BDI cannot generate the message "Program terminated normally" because it has no information about when this event happens. Also an embedded application normally does not terminate. When you finally burn you application into flash, it should run continuously and will never terminate via exit(). You may change your exit() function and code-in the opcode of a software breakpoint. If you did not change it within the BDI configuration, the opcode for a breakpoint is 0xE7FFDEFE. Regards, Ruedi At 09:24 28.11.2001 -0700, you wrote: >Hello, > >I have an arm-elf target connected to a bdi2000 jtag debugger. Is there any >instruction I can compile that indicates to the debugger or gdb that >my program has reached normal termination. When main returns exit() is called >which then hangs the processor. I have to interrupt it with ctrl-c. I'd like >gdb to break to the prompt on its own and display the message "Program >terminated normally". Do you know how I go about this? > >Thanks, >Shaun ============================== Ruedi Dummermuth Abatron AG Lettenstrasse 9 CH-6343 Rotkreuz Switzerland mailto:ruedi@abatron.ch http://www.abatron.ch Tel ++41 41 792 09 55 Fax ++41 41 792 09 60 From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ruedi Dummermuth To: Shaun Jackman Cc: bgat@billgatliff.com, gdb@sources.redhat.com Subject: Re: gdb signal normal termination of program Date: Wed, 28 Nov 2001 23:31:00 -0000 Message-ID: <4.2.0.58.20011129081742.00bdf940@pop.abatron.ch> References: X-SW-Source: 2001-11/msg00332.html Message-ID: <20011128233100.SxWS51IsGL4vAaSj13cfvOT5Z76Q8Xa28QYFqrjaHaM@z> Hello Shaun The BDI cannot detect when you enter the exit() function unless you set a breakpoint in it. The BDI cannot generate the message "Program terminated normally" because it has no information about when this event happens. Also an embedded application normally does not terminate. When you finally burn you application into flash, it should run continuously and will never terminate via exit(). You may change your exit() function and code-in the opcode of a software breakpoint. If you did not change it within the BDI configuration, the opcode for a breakpoint is 0xE7FFDEFE. Regards, Ruedi At 09:24 28.11.2001 -0700, you wrote: >Hello, > >I have an arm-elf target connected to a bdi2000 jtag debugger. Is there any >instruction I can compile that indicates to the debugger or gdb that >my program has reached normal termination. When main returns exit() is called >which then hangs the processor. I have to interrupt it with ctrl-c. I'd like >gdb to break to the prompt on its own and display the message "Program >terminated normally". Do you know how I go about this? > >Thanks, >Shaun ============================== Ruedi Dummermuth Abatron AG Lettenstrasse 9 CH-6343 Rotkreuz Switzerland mailto:ruedi@abatron.ch http://www.abatron.ch Tel ++41 41 792 09 55 Fax ++41 41 792 09 60