From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21388 invoked by alias); 16 Jan 2008 09:13:53 -0000 Received: (qmail 21380 invoked by uid 22791); 16 Jan 2008 09:13:52 -0000 X-Spam-Check-By: sourceware.org Received: from mx2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 16 Jan 2008 09:13:32 +0000 Received: from Relay1.suse.de (mail2.suse.de [195.135.221.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id 9961B30405; Wed, 16 Jan 2008 10:13:29 +0100 (CET) From: Andreas Schwab To: Eli Zaretskii Cc: uweigand@de.ibm.com, brobecker@adacore.com, msnyder@specifix.com, mark.kettenis@xs4all.nl, gdb-patches@sourceware.org Subject: Re: [RFC/RFA?] Should break FILE:LINENO skip prologue? References: <200801152140.m0FLeMha003566@d12av02.megacenter.de.ibm.com> X-Yow: Put FIVE DOZEN red GIRDLES in each CIRCULAR OPENING!! Date: Wed, 16 Jan 2008 09:13:00 -0000 In-Reply-To: (Eli Zaretskii's message of "Wed\, 16 Jan 2008 06\:21\:16 +0200") Message-ID: User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-IsSubscribed: yes 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 X-SW-Source: 2008-01/txt/msg00388.txt.bz2 Eli Zaretskii writes: >> From: Andreas Schwab >> Cc: eliz@gnu.org, brobecker@adacore.com (Joel Brobecker), >> msnyder@specifix.com, mark.kettenis@xs4all.nl, >> gdb-patches@sourceware.org >> Date: Wed, 16 Jan 2008 00:23:45 +0100 >> >> "Ulrich Weigand" writes: >> >> > The set of valid expressions varies with the language, but none of >> > them support any string of the form FILENAME:FUNCTION as expression. >> > However, for *some* languages (e.g. C, but not Ada), a function name >> > happens to be a valid expression that evaluates to the address of >> > that function. It is only due to that "accident" that >> > break *FUNCTION >> > does indeed set a breakpoint at the address of FUNCTION (assuming >> > the current language is C). >> >> Note that the value of FUNCTION is even target dependent. On ppc64 >> ordinary function symbols point to function descriptors, whereas code >> addresses have symbols that start with a '.'. > > Are you saying that "break *FUNCTION" will not work on a ppc64, even > in a C program? It works if you use the correct symbol. In the absence of debug information the non-dot symbol will give the wrong result. Andreas. -- Andreas Schwab, SuSE Labs, schwab@suse.de SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."