From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29196 invoked by alias); 20 Sep 2004 16:55:35 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 29189 invoked from network); 20 Sep 2004 16:55:34 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 20 Sep 2004 16:55:34 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.11/8.12.10) with ESMTP id i8KGtYhs005181 for ; Mon, 20 Sep 2004 12:55:34 -0400 Received: from zenia.home.redhat.com (sebastian-int.corp.redhat.com [172.16.52.221]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i8KGtRr01333; Mon, 20 Sep 2004 12:55:28 -0400 To: gdb-patches@sources.redhat.com Subject: PATCH: note that minsyms can have duplicate demangled names From: Jim Blandy Date: Mon, 20 Sep 2004 16:55:00 -0000 Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2004-09/txt/msg00315.txt.bz2 2004-09-19 Jim Blandy * minsyms.c (lookup_minimal_symbol): Doc fix. Index: gdb/minsyms.c =================================================================== RCS file: /cvs/src/src/gdb/minsyms.c,v retrieving revision 1.43 diff -c -p -r1.43 minsyms.c *** gdb/minsyms.c 20 May 2004 09:51:33 -0000 1.43 --- gdb/minsyms.c 20 Sep 2004 00:50:38 -0000 *************** add_minsym_to_demangled_hash_table (stru *** 145,151 **** Note: One instance where there may be duplicate minimal symbols with the same name is when the symbol tables for a shared library and the symbol tables for an executable contain global symbols with the same ! names (the dynamic linker deals with the duplication). */ struct minimal_symbol * lookup_minimal_symbol (const char *name, const char *sfile, --- 145,159 ---- Note: One instance where there may be duplicate minimal symbols with the same name is when the symbol tables for a shared library and the symbol tables for an executable contain global symbols with the same ! names (the dynamic linker deals with the duplication). ! ! It's also possible to have minimal symbols with different mangled ! names, but identical demangled names. For example, the GNU C++ v3 ! ABI requires the generation of two (or perhaps three) copies of ! constructor functions --- "in-charge", "not-in-charge", and ! "allocate" copies; destructors may be duplicated as well. ! Obviously, there must be distinct mangled names for each of these, ! but the demangled names are all the same: S::S or S::~S. */ struct minimal_symbol * lookup_minimal_symbol (const char *name, const char *sfile,