From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5524 invoked by alias); 15 Sep 2003 14:36:43 -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 5515 invoked from network); 15 Sep 2003 14:36:42 -0000 Received: from unknown (HELO concert.shout.net) (204.253.184.25) by sources.redhat.com with SMTP; 15 Sep 2003 14:36:42 -0000 Received: from duracef.shout.net (duracef.shout.net [204.253.184.12]) by concert.shout.net (8.12.9/8.12.9) with ESMTP id h8FEaeuv010145; Mon, 15 Sep 2003 09:36:40 -0500 Received: from duracef.shout.net (localhost [127.0.0.1]) by duracef.shout.net (8.12.9/8.12.9) with ESMTP id h8FEaeHK014471; Mon, 15 Sep 2003 09:36:40 -0500 Received: (from mec@localhost) by duracef.shout.net (8.12.9/8.12.9/Submit) id h8FEaeK3014470; Mon, 15 Sep 2003 10:36:40 -0400 Date: Mon, 15 Sep 2003 14:36:00 -0000 From: Michael Elizabeth Chastain Message-Id: <200309151436.h8FEaeK3014470@duracef.shout.net> To: ac131313@redhat.com, andwes-8@student.luth.se Subject: Re: thread debugging problem Cc: gdb@sources.redhat.com X-SW-Source: 2003-09/txt/msg00194.txt.bz2 aw> I've switched to redhat9 and now I get thread info, but I'm having other aw> problems instead. Strange behaviour which I believe shouldn't happen. aw> When I step forward in the code it seems to be running into somekind of aw> loop running the same lines of code several times when it shouldn't, as aw> you can see in the gdb session below. This is with gdb 5.3.91 but I saw aw> the same behaviour with 5.3 on my gentoo box at home. This is normal gdb behavior when the code is optimized (compiled with -O or -O1 or -O2 or -O3). The compiler interleaves instructions from different source lines to improve performance. You can get used to it, which takes a few days, or you can compile your code with -O0 and get simpler "next" behavior at the cost of more object code. Michael C