From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3298 invoked by alias); 10 Jan 2014 02:17:32 -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 3280 invoked by uid 89); 10 Jan 2014 02:17:27 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.5 required=5.0 tests=AWL,BAYES_00,GARBLED_BODY autolearn=no version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 10 Jan 2014 02:17:27 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1W1Rf1-0000Hw-Lf from Yao_Qi@mentor.com ; Thu, 09 Jan 2014 18:17:23 -0800 Received: from SVR-ORW-FEM-02.mgc.mentorg.com ([147.34.96.206]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Thu, 9 Jan 2014 18:17:23 -0800 Received: from qiyao.dyndns.org (147.34.91.1) by svr-orw-fem-02.mgc.mentorg.com (147.34.96.168) with Microsoft SMTP Server id 14.2.247.3; Thu, 9 Jan 2014 18:17:22 -0800 Message-ID: <52CF57CF.9030503@codesourcery.com> Date: Fri, 10 Jan 2014 02:17:00 -0000 From: Yao Qi User-Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130110 Thunderbird/17.0.2 MIME-Version: 1.0 To: Sergio Durigan Junior CC: GDB Patches Subject: Re: [PATCH] Fix gdb.trace/mi-traceframe-changed.exp to check for target trace support References: <52CF4B40.3030500@codesourcery.com> In-Reply-To: <52CF4B40.3030500@codesourcery.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2014-01/txt/msg00266.txt.bz2 On 01/10/2014 09:22 AM, Yao Qi wrote: > On 01/10/2014 05:21 AM, Sergio Durigan Junior wrote: >> > gdb.trace/mi-traceframe-changed.exp was running without actually >> > checking if the target supported tracing or not. So I wrote this patch >> > to fix the issue. > The patch looks a right fix. Any tracepoint related tests should check > whether target supports tracing or not at first. > > I did it through an oversight when I wrote this case. Ah, I read the patch and mi-traceframe-change.exp again, and find my last comment is wrong. Sorry for the confusion. 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. 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. -- Yao (齐尧)