From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2084 invoked by alias); 3 May 2012 13:13:20 -0000 Received: (qmail 1920 invoked by uid 22791); 3 May 2012 13:13:18 -0000 X-SWARE-Spam-Status: No, hits=-4.1 required=5.0 tests=AWL,BAYES_00,FROM_12LTRDOM,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL X-Spam-Check-By: sourceware.org Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 03 May 2012 13:13:05 +0000 Received: from svr-orw-fem-01.mgc.mentorg.com ([147.34.98.93]) by relay1.mentorg.com with esmtp id 1SPvqA-0005OM-GJ from Yao_Qi@mentor.com for gdb-patches@sourceware.org; Thu, 03 May 2012 06:13:02 -0700 Received: from SVR-ORW-FEM-02.mgc.mentorg.com ([147.34.96.206]) by svr-orw-fem-01.mgc.mentorg.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Thu, 3 May 2012 06:13:02 -0700 Received: from localhost.localdomain (147.34.91.1) by svr-orw-fem-02.mgc.mentorg.com (147.34.96.168) with Microsoft SMTP Server id 14.1.289.1; Thu, 3 May 2012 06:12:52 -0700 From: Yao Qi To: Subject: [PATCH 13/14] ia64-sigill.exp: Don't assume there's no infrun output after the prompt Date: Thu, 03 May 2012 13:13:00 -0000 Message-ID: <1336050869-29605-14-git-send-email-yao@codesourcery.com> In-Reply-To: <1336050869-29605-1-git-send-email-yao@codesourcery.com> References: <1336050869-29605-1-git-send-email-yao@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain X-IsSubscribed: yes 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 X-SW-Source: 2012-05/txt/msg00075.txt.bz2 From: Pedro Alves In async mode, we can still see TARGET_WAITKIND_IGNORE and TARGET_WAITKIND_NORESUMED events after displaying the prompt, breaking this test with timeouts, due to the anchor in "$gdb_prompt $" This fixes it. v2: - new in v2. gdb/testsuite/ 2011-12-16 Pedro Alves * gdb.threads/ia64-sigill.exp: Don't assume there's no infrun output after the prompt. --- gdb/testsuite/gdb.threads/ia64-sigill.exp | 26 ++++++++++++++++++++------ 1 files changed, 20 insertions(+), 6 deletions(-) diff --git a/gdb/testsuite/gdb.threads/ia64-sigill.exp b/gdb/testsuite/gdb.threads/ia64-sigill.exp index e14c685..4b2ebae 100644 --- a/gdb/testsuite/gdb.threads/ia64-sigill.exp +++ b/gdb/testsuite/gdb.threads/ia64-sigill.exp @@ -55,21 +55,35 @@ gdb_test_no_output {set $sigill_bpnum=$bpnum} gdb_breakpoint [gdb_get_line_number "break-at-exit"] +# The ia64 SIGILL signal is only visible in the infrun debug output. +# Note we can't assume there's no infrun output after the prompt from +# here on. gdb_test_no_output "set debug infrun 1" -# The ia64 SIGILL signal is visible only in the lin-lwp debug. - -gdb_test "continue" "Breakpoint \[0-9\]+,( .* in)? thread_func .*" +set test "continue to thread_func" +gdb_test_multiple "continue" $test { + -re "Breakpoint \[0-9\]+,( .* in)? thread_func .*$gdb_prompt " { + pass $test + } +} -gdb_test_no_output {delete $sigill_bpnum} +set test {delete $sigill_bpnum} +gdb_test_multiple "continue" $test { + -re "$gdb_prompt " { + pass $test + } +} set test "continue for the pending signal" gdb_test_multiple "continue" $test { - -re "Breakpoint \[0-9\]+, .*break-at-exit.*\r\n$gdb_prompt $" { + -re "Breakpoint \[0-9\]+, .*break-at-exit.*\r\n$gdb_prompt " { # Breakpoint has been skipped in the other thread. pass $test } - -re "Program received signal .*\r\n$gdb_prompt $" { + -re "Program received signal .*\r\n$gdb_prompt " { + fail $test + } + -re "$gdb_prompt " { fail $test } } -- 1.7.0.4