From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 106422 invoked by alias); 21 Jan 2016 10:42:41 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 106355 invoked by uid 89); 21 Jan 2016 10:42:40 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.8 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE autolearn=no version=3.3.2 spammy=dejagnu X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Thu, 21 Jan 2016 10:42:40 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 9CD65117CF4; Thu, 21 Jan 2016 05:42:26 -0500 (EST) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id V8chig9fNQRf; Thu, 21 Jan 2016 05:42:26 -0500 (EST) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id DDDF8117D0C; Thu, 21 Jan 2016 05:42:18 -0500 (EST) Received: by joel.gnat.com (Postfix, from userid 1000) id D042B45017; Thu, 21 Jan 2016 14:42:14 +0400 (RET) Date: Thu, 21 Jan 2016 10:42:00 -0000 From: Joel Brobecker To: Simon Marchi Cc: Pedro Alves , dejagnu@gnu.org, gdb-patches Subject: Re: How to abort a test? Message-ID: <20160121104214.GF5146@adacore.com> References: <56958359.8070708@ericsson.com> <5697CC09.8010306@redhat.com> <5697D721.1000305@ericsson.com> <5697DABA.8010008@redhat.com> <5697FA6C.7060703@ericsson.com> <5697FB9E.3080906@redhat.com> <56991FB0.5090109@ericsson.com> <20160117082709.GC4059@adacore.com> <569D163D.7060609@ericsson.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <569D163D.7060609@ericsson.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-SW-Source: 2016-01/txt/msg00509.txt.bz2 > --status does no really impact how a timeout is handled. What happens > when a timeout occurs in gdb_test is defined by us. Right now, it > produces a test "fail": > > testsuite/lib/gdb.exp: > 937 timeout { > 938 if ![string match "" $message] then { > 939 fail "$message (timeout)" > 940 } > 941 set result 1 > 942 } > > So you see, for example: > > FAIL: gdb.base/break.exp: some test (timeout) > > and the test case carries on. A gdb_test timeout is no different than > a regular fail. If you replace the "fail" at line 939 with "error", > which throws a TCL exception, then the current test case will abort, > although in this quite ugly way: Argh. I was hoping that we would be able to add something at the end of the timeout handler to abort, but in a nice way. So, IIUC, without help from dejagnu, there is no way we know of to abort testcases... Thanks for having looked into this! -- Joel