From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13699 invoked by alias); 16 May 2007 14:48:15 -0000 Received: (qmail 13690 invoked by uid 22791); 16 May 2007 14:48:14 -0000 X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.45.13) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 16 May 2007 14:48:02 +0000 Received: from zps38.corp.google.com (zps38.corp.google.com [172.25.146.38]) by smtp-out.google.com with ESMTP id l4GElqW1001564; Wed, 16 May 2007 07:47:52 -0700 Received: from smtp.corp.google.com (spacemonkey2.corp.google.com [192.168.120.114]) by zps38.corp.google.com with ESMTP id l4GEljRP025868 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 16 May 2007 07:47:45 -0700 Received: from localhost.localdomain.google.com (6.sub-75-208-60.myvzw.com [75.208.60.6]) (authenticated bits=0) by smtp.corp.google.com (8.13.8/8.13.8) with ESMTP id l4GEleRf010975 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 16 May 2007 07:47:43 -0700 To: "Rob Keeney" Cc: gcc-help@gcc.gnu.org Subject: Re: ld link map file format References: <28e2f86d0705160628r4d20e386gf674193655126690@mail.gmail.com> From: Ian Lance Taylor Date: Wed, 16 May 2007 14:48:00 -0000 In-Reply-To: <28e2f86d0705160628r4d20e386gf674193655126690@mail.gmail.com> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2007-05/txt/msg00150.txt.bz2 "Rob Keeney" writes: > I have searched and searched and have not been able to find any > documentation of the map file format output by ld. I need to know if > there is anyway to determine if a symbol is a function, and if a > symbol was provided by the linker. The linker is part of the GNU binutils, not gcc, and questions about it should be directed to the binutils@sourceware.org mailing list. See http://sourceware.org/binutils/. The map file does not tell you whether a symbol is a function. You can of course use objdump or readelf on the linked executable to find that out. The map file will tell you whether a symbol was defined by the linker: it will be in a section not associated with any input file, and will have a linker script command on it. E.g., 0x08049578 _end = . Ian