From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7695 invoked by alias); 26 Oct 2013 04:29:08 -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 7681 invoked by uid 89); 26 Oct 2013 04:29:07 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Sat, 26 Oct 2013 04:29:06 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id E5F3C116646; Sat, 26 Oct 2013 00:29:30 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id LApcsenXbFlU; Sat, 26 Oct 2013 00:29:30 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id 8B2A6116648; Sat, 26 Oct 2013 00:29:30 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id 302F9E069D; Sat, 26 Oct 2013 08:29:02 +0400 (RET) Date: Sat, 26 Oct 2013 04:29:00 -0000 From: Joel Brobecker To: Luis Machado Cc: "'gdb-patches@sourceware.org'" Subject: Re: checked in: Re: RFC: solib.c:solib_map_sections so->so_name clobbering Message-ID: <20131026042902.GE4769@adacore.com> References: <526B2936.3080208@codesourcery.com> <526B2A53.7080905@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <526B2A53.7080905@codesourcery.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-SW-Source: 2013-10/txt/msg00840.txt.bz2 > >So it looks like we've lost information about the shared library's path > >on the host, which may not be a big deal for CLI GDB, but may confuse > >consumers of MI output. Agreed. Can you also check the output of "info shared" in GDB/CLI mode? I suspect that you might have a change in behavior there as well. Whether this change is actually a Good Thing or not, is unclear, as the manual does not say whether the names are expected to be host-side paths, or target-side paths. > >I gave this a quick thought, but reverting the change seemed like the > >most obvious solution. > > > >But since this change affects darwin, maybe Joel has a different idea? This would also affect AIX. It might probably need more thought, but at first sight, I am wondering whether the real issue is that the solib backend created an entry where "so_name" does not match the field description: /* Shared object file name, expanded to something GDB can open. */ My suspicion is that the bfd_open callback takes care of the path translation, so the backend was allowing itself to defer it. I am not sure how difficult it would be to move that part to each backend. Reverting the patch would be a real issue, because it would mean that any given solib backend cannot set the so_name, and commands such as "info shared" would print a bogus shared library name. Nevertheless, if we did revert it, I think we can work around the issue by using the same trick as the one we used for the 7.6 branch IIRC. -- Joel