From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22264 invoked by alias); 30 Aug 2013 11:20:31 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 22255 invoked by uid 89); 30 Aug 2013 11:20:31 -0000 Received: from mailrelay012.isp.belgacom.be (HELO mailrelay012.isp.belgacom.be) (195.238.6.179) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 30 Aug 2013 11:20:31 +0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=3.7 required=5.0 tests=BAYES_00,CK_HELO_DYNAMIC_SPLIT_IP,HELO_DYNAMIC_SPLIT_IP,SPF_SOFTFAIL,TVD_RCVD_IP autolearn=no version=3.3.2 X-HELO: mailrelay012.isp.belgacom.be X-Belgacom-Dynamic: yes X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvEBAKl/IFJtgbcb/2dsb2JhbAANTYc0vl9tglWBCwImAl+uQnSSGYEpkTqBNAOsew Received: from 27.183-129-109.adsl-dyn.isp.belgacom.be (HELO [192.168.1.6]) ([109.129.183.27]) by relay.skynet.be with ESMTP; 30 Aug 2013 13:20:26 +0200 Subject: random-sig randomly failing with gdbserver From: Philippe Waroquiers To: "gdb@sourceware.org" Content-Type: text/plain; charset="UTF-8" Date: Fri, 30 Aug 2013 11:20:00 -0000 Message-ID: <1377861628.2127.28.camel@soleil> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-SW-Source: 2013-08/txt/msg00128.txt.bz2 gdb.base/random-sig.exp (frequently) randomly fails when running with gdbserver, when running multiple times make check RUNTESTFLAGS="--target_board native-gdbserver random-signal.exp" It looks like it can fail for at least three reasons A successful run gives: (gdb) PASS: gdb.base/random-signal.exp: watch v continue Continuing. PASS: gdb.base/random-signal.exp: continue ^C Program received signal SIGINT, Interrupt. main () at ./gdb.base/random-signal.c:28 28 ; (gdb) PASS: gdb.base/random-signal.exp: stop with control-c A failing run gives: (gdb) PASS: gdb.base/random-signal.exp: watch v continue Continuing. PASS: gdb.base/random-signal.exp: continue ^Cmain () at ./gdb.base/random-signal.c:28 28 ; Quit (gdb) FAIL: gdb.base/random-signal.exp: stop with control-c testcase ./gdb.base/random-signal.exp completed in 1 seconds It can also fail with: (gdb) PASS: gdb.base/random-signal.exp: watch v continue Continuing. PASS: gdb.base/random-signal.exp: continue ^CFAIL: gdb.base/random-signal.exp: stop with control-c (timeout) testcase ./gdb.base/random-signal.exp completed in 11 seconds Or fail with (gdb) PASS: gdb.base/random-signal.exp: watch v continue Continuing. PASS: gdb.base/random-signal.exp: continue ^CError evaluating expression for watchpoint 2 Quit Watchpoint 2 deleted. main () at ./gdb.base/random-signal.c:28 28 ; (gdb) FAIL: gdb.base/random-signal.exp: stop with control-c testcase ./gdb.base/random-signal.exp completed in 1 seconds Unclear what exactly happens. I suspect a race condition between gdbserver reporting that the inferior stopped (to examine the software watchpoint) and gdb sending at the same time the interrupt, and expecting a SIGINT, but instead receiving the stopped condition from gdbserver. Philippe