From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 46195 invoked by alias); 2 May 2016 18:28:16 -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 46155 invoked by uid 89); 2 May 2016 18:28:16 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=c_global, launches, connects, UD:solib-display.exp 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 (AES256-GCM-SHA384 encrypted) ESMTPS; Mon, 02 May 2016 18:28:15 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 0B67B81F03; Mon, 2 May 2016 18:28:14 +0000 (UTC) Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u42ISCpx000992; Mon, 2 May 2016 14:28:13 -0400 Subject: Re: [PATCH 4/4] Fix solib-display.exp remote check To: Simon Marchi References: <1459912543-15328-1-git-send-email-simon.marchi@polymtl.ca> <1459912543-15328-4-git-send-email-simon.marchi@polymtl.ca> <570BECA8.3050801@redhat.com> <581c3da12dacfd50cfbbe4dbd31a981a@simark.ca> Cc: gdb-patches@sourceware.org From: Pedro Alves Message-ID: Date: Mon, 02 May 2016 18:28:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.0 MIME-Version: 1.0 In-Reply-To: <581c3da12dacfd50cfbbe4dbd31a981a@simark.ca> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-SW-Source: 2016-05/txt/msg00021.txt.bz2 On 05/02/2016 07:19 PM, Simon Marchi wrote: > On 2016-04-11 14:27, Pedro Alves wrote: >> On 04/06/2016 04:15 AM, Simon Marchi wrote: >> >>> The test uses "run" >> >> Does it have to? Can't we use "kill" followed by runto_main >> again, instead of gdb_start_cmd ? > > I tried to change the test so that it uses kill, followed with > gdb_run_cmd combined with a breakpoint at main (runto_main wouldn't > work, since it doesn't expect the variable display before the prompt). > > The problem with native-gdbserver (and probabley any stub target) is > that when you run again, it launches a new gdbserver and connects to it. > Right after connecting, gdb tries to display the variables, but since > we're stopped before the libs are loaded, we get: > > warning: Unable to display "a_global": No symbol "a_global" in current > context. > warning: Unable to display "b_global": No symbol "b_global" in current > context. > warning: Unable to display "c_global": No symbol "c_global" in current > context. > > and gdb trashes the displays. The rest of the test fails because it > expects the displays to be there (I think that's the point of that > test). So for now at least, I'd keep the test like this, disabled for > stub targets. Thanks for the investigation. I think it'd be nice to add this info as a comment in the test file. Thanks, Pedro Alves