From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24192 invoked by alias); 25 Oct 2004 16:32:40 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 24036 invoked from network); 25 Oct 2004 16:32:34 -0000 Received: from unknown (HELO us.ibm.com) (32.97.110.142) by sourceware.org with SMTP; 25 Oct 2004 16:32:34 -0000 Received: by us.ibm.com (Postfix, from userid 1000) id 6DF00F0AA; Mon, 25 Oct 2004 09:30:09 -0700 (PDT) From: Paul Gilliam Reply-To: pgilliam@us.ibm.com To: gdb-patches@sources.redhat.com Subject: Re: [patch] New test for set backtrace related functionality Date: Mon, 25 Oct 2004 16:32:00 -0000 User-Agent: KMail/1.6.2 Cc: Michael Chastain References: <200410141539.22560.pgilliam@us.ibm.com> <200410220957.46790.pgilliam@us.ibm.com> <41798044.nailDG51QLXJD@mindspring.com> In-Reply-To: <41798044.nailDG51QLXJD@mindspring.com> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200410250930.09088.pgilliam@us.ibm.com> X-SW-Source: 2004-10/txt/msg00406.txt.bz2 Michael, On Friday 22 October 2004 14:48, Michael Chastain wrote: > The design is good, but there are simple implementation nits, > and one implementation problem that I haven't got to the bottom > of yet. > > In setbacktrace.c, add a line "#include " to get the > declaration of atoi. gcc HEAD does not warn about it today > but it might eventually. :-/ > > When you name the tests, don't use "(...)" as part of the test name: > > set test "set backtrace" > set test "full backtrace" > set test "full backtrace (exact)" > set test "partial backtrace" > set test "partial backtrace (using limit)" > > Test names that differ only in that way are hard to talk about. > Similarly, it's bad when one name is a prefix of another name. > > How about: > > set test "set backtrace" > set test "full backtrace, ignore extra" > set test "full backtrace, exact" > set test "partial backtrace, with argument" > set test "partial backtrace, with limit" Looks good to me. > > There's a problem with the "partial backtrace (using limit)" test: > > set extra_frames [lrange $expected_frames 0 [expr $subr_depth + 2]] > > $expected_frames has 22 elements in it, and this call to lrange > asks for elements 0 to 22, which is 23 elements. > > Here's the tough problem. I'm getting a weird random timeout on the > "partial backtrace (using limit)" test. In a group of 12 > configurations, I saw 2 PASS and 12 FAIL/timeout. I suspect some ".*" > or "[^foo]*" that is too greedy and eating more than it should, leaving > the later bits of the expect_list out to dry. gdb_expect_list is > matching them one at a time so there is no backtracking if an early r.e. > mistakenly eats too much. Specifically, it might be a problem with the > definition of $leadin. I'll take a close look at this. As a dejagnu/expect tyro, the 'greedy RE' problem has been a tough one. I hate getting timeouts because they make the testsuite run so s-l-o-w. > > Michael > > === > > 2004-10-14 Paul Gilliam > > * gdb.base/setbacktrace.c gdb.base/setbacktrace.exp: New files. Thanks for your review/input: I'll try to turn this around today. -=# Paul #=-