From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 41527 invoked by alias); 27 Jul 2015 12:22:36 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 41495 invoked by uid 89); 27 Jul 2015 12:22:35 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RP_MATCHES_RCVD,SPF_HELO_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 (AES256-GCM-SHA384 encrypted) ESMTPS; Mon, 27 Jul 2015 12:22:34 +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 (Postfix) with ESMTPS id CD2B0359D3E; Mon, 27 Jul 2015 12:22:32 +0000 (UTC) Received: from blade.nx (ovpn-116-19.ams2.redhat.com [10.36.116.19]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t6RCEt65026055; Mon, 27 Jul 2015 08:14:56 -0400 Received: by blade.nx (Postfix, from userid 1000) id CC1C1264EF6; Mon, 27 Jul 2015 13:14:54 +0100 (BST) Date: Mon, 27 Jul 2015 12:22:00 -0000 From: Gary Benson To: Sandra Loosemore Cc: Pedro Alves , Paul_Koning@Dell.com, gdb@sourceware.org Subject: Re: GDB now takes 4 minutes to start up with remote gdbserver target Message-ID: <20150727121454.GA15226@blade.nx> References: <55B1768E.9090309@codesourcery.com> <55B1A4FC.9010403@codesourcery.com> <20150724085244.GB22673@blade.nx> <55B2444C.106@codesourcery.com> <2906903F-7478-4B9D-8A9A-A6256F8076EF@dell.com> <20150724151148.GA18553@blade.nx> <55B26267.4060905@redhat.com> <55B27348.1020104@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <55B27348.1020104@codesourcery.com> X-IsSubscribed: yes X-SW-Source: 2015-07/txt/msg00059.txt.bz2 Sandra Loosemore wrote: > On 07/24/2015 10:05 AM, Pedro Alves wrote: > > On 07/24/2015 04:27 PM, Paul_Koning@Dell.com wrote: > > > But having sysroot default to target is also a bad idea for lots > > > of other people. Consider embedded systems: you presumably have > > > stripped images there, but unstripped ones on your build host. > > > > But in that scenario, with the old default sysroot, how was gdb > > finding the binaries on the build host? The binaries on the > > equilalent locations on the host's root will certainly not match > > the embedded/target system's. In that scenario, you must have > > been pointing the "set sysroot" somewhere local? And if you do > > that, nothing changes in 7.10, gdb will still access the files on > > the local filesystem. > > > > From the discussion so far, it seems that the only case that ends > > up regressing is the case where the host and target share both the > > filesystem, and the host/target paths match. I don't know off > > hand how to make gdb aware of that automatically. > > There's also the case where the host and target sysroot locations do > not match at all. As I said, this used to work reasonably well for > application debugging, where the user isn't interested in debugging > shared libraries and doesn't care if the shared library symbol > information isn't available to GDB. It used to print a helpful > message suggesting using "set sysroot" if the user wants the shared > library information, instead of hanging on startup with no > indication of what the trouble is or how to fix it. I can't see the > new default behavior as an improvement over the old. > > > That seems like enough of a special case that could well be > > handled by an explicit "set sysroot /" in e.g., the toolchain's > > system-gdbinit, or by building gdb with "--with-sysroot=/". > > There are a bunch of possible workarounds for this, but why can't we > make GDB "just work" by default, as it used to, instead of requiring > users to build GDB differently or install a workaround or issue > extra commands manually that they didn't used to need at all? I have an idea for a solution to this. I should know in a few hours if it can work. Tomorrow morning at the very latest. Thanks, Gary -- http://gbenson.net/