From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19434 invoked by alias); 10 Jan 2014 03:58:02 -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 19288 invoked by uid 89); 10 Jan 2014 03:58:02 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.5 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 10 Jan 2014 03:58:01 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s0A3vwN9005408 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 9 Jan 2014 22:57:59 -0500 Received: from psique (ovpn-113-176.phx2.redhat.com [10.3.113.176]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s0A3vuPA011753 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Thu, 9 Jan 2014 22:57:57 -0500 From: Sergio Durigan Junior To: Yao Qi Cc: GDB Patches Subject: Re: [PATCH] Fix gdb.trace/mi-traceframe-changed.exp to check for target trace support References: <52CF4B40.3030500@codesourcery.com> <52CF57CF.9030503@codesourcery.com> X-URL: http://www.redhat.com Date: Fri, 10 Jan 2014 03:58:00 -0000 In-Reply-To: <52CF57CF.9030503@codesourcery.com> (Yao Qi's message of "Fri, 10 Jan 2014 10:15:43 +0800") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-IsSubscribed: yes X-SW-Source: 2014-01/txt/msg00270.txt.bz2 On Friday, January 10 2014, Yao Qi wrote: > Ah, I read the patch and mi-traceframe-change.exp again, and find my > last comment is wrong. Sorry for the confusion. Thank you! I was secretly wondering whether my patch was correct or not, because I thought the testcase was intended to be run partially on native debugging, as you explained. I was going to e-mail something about it tomorrow, but you were faster :-). > The first half of mi-traceframe-changed.exp (test_tfind_tfile) is to > test "=traceframe-changed" on tfile target, which is produced by > tfile.c. It is expected to run on native debugging. The second half > of mi-traceframe-changed.exp (test_tfile_remote) is to test > "=traceframe-changed" on remote target with a gdbserver connected. We > can see mi-traceframe-changed.exp has already have the code to check > target supports tracing or not. > > The root cause is that tfile.c isn't portable and unable to produce > trace file properly for s390x. Search FIXME in it. Indeed, thanks for pointing that. > We should skip test_find_tfile for targets other than x86-linux or > x86_64-linux. Alternatively, we can modify tfile.c for s390x, but I > think "generating tfile on a unsupported-tracing target" isn't useful. OK, WDYT of this version then? -- Sergio 2014-01-10 Sergio Durigan Junior * gdb.trace/mi-traceframe-changed.exp: Only run test_find_tfile if the target is x86_64 or i*86 running the Linux kernel. diff --git a/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp b/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp index 4bcf379..f2f5224 100644 --- a/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp +++ b/gdb/testsuite/gdb.trace/mi-traceframe-changed.exp @@ -88,7 +88,11 @@ proc test_tfind_tfile { } { } } -test_tfind_tfile +if { [istarget "x86_64-*-linux*"] || [istarget "i*86-*-linux*"] } { + # This test only works on x86_64 and i*86 targets running the Linux + # kernel. See the FIXME's on gdb.trace/tfile.c for more details. + test_tfind_tfile +} # Change to a different test case in order to run it on target, and get # several traceframes.