From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29742 invoked by alias); 28 Apr 2016 17:28:20 -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 29731 invoked by uid 89); 28 Apr 2016 17:28:19 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=BAYES_00,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2 spammy=agent X-HELO: usplmg20.ericsson.net Received: from usplmg20.ericsson.net (HELO usplmg20.ericsson.net) (198.24.6.45) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Thu, 28 Apr 2016 17:28:18 +0000 Received: from EUSAAHC002.ericsson.se (Unknown_Domain [147.117.188.78]) by usplmg20.ericsson.net (Symantec Mail Security) with SMTP id ED.81.09012.9E042275; Thu, 28 Apr 2016 18:57:13 +0200 (CEST) Received: from [142.133.110.144] (147.117.188.8) by smtp-am.internal.ericsson.com (147.117.188.80) with Microsoft SMTP Server id 14.3.248.2; Thu, 28 Apr 2016 13:28:15 -0400 Subject: Re: [PATCH] ftrace: Fix gdbserver crash when doing tstatus after detach or process exit To: References: <1459344024-2260-1-git-send-email-simon.marchi@ericsson.com> <57224295.6050504@ericsson.com> From: Simon Marchi Message-ID: <5722482F.20904@ericsson.com> Date: Thu, 28 Apr 2016 17:28:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <57224295.6050504@ericsson.com> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2016-04/txt/msg00643.txt.bz2 On 16-04-28 01:04 PM, Simon Marchi wrote: >> +# Check that the target supports trace. >> +if { [gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { I just saw that I used gdb_compile_pthreads. As Yao mentioned in another thread, it should be gdb_compile instead. >> + untested "Couldn't compile test program" >> + return -1 >> +} >> + >> +clean_restart ${testfile} >> + >> +if ![runto_main] { >> + fail "Can't run to main to check for trace support" >> + return -1 >> +} >> + >> +if $use_gdb_stub { >> + # This test is about testing commands after detaching from a process or >> + # after letting a process exit, so it doesn't make sense to run it if the >> + # target is stub-like. >> + unsupported "This test is not supported for GDB stub targets." >> + return -1 >> +} >> + >> +if ![gdb_target_supports_trace] { >> + unsupported "target does not support trace" >> + return -1 >> +} >> + >> +# Compile the test case with the in-process agent library. >> +set libipa [get_in_proc_agent] >> +gdb_load_shlibs $libipa >> + >> +lappend options shlib=$libipa >> + >> +if { [gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $options] != "" } { Same here.