From patchwork Fri Dec 5 09:16:10 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Evans X-Patchwork-Id: 4078 Received: (qmail 31433 invoked by alias); 5 Dec 2014 09:17:06 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 31419 invoked by uid 89); 5 Dec 2014 09:17:05 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL, BAYES_00, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-pd0-f177.google.com Received: from mail-pd0-f177.google.com (HELO mail-pd0-f177.google.com) (209.85.192.177) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Fri, 05 Dec 2014 09:17:04 +0000 Received: by mail-pd0-f177.google.com with SMTP id ft15so342351pdb.22 for ; Fri, 05 Dec 2014 01:17:02 -0800 (PST) X-Received: by 10.68.230.10 with SMTP id su10mr33278919pbc.129.1417771022449; Fri, 05 Dec 2014 01:17:02 -0800 (PST) Received: from seba.sebabeach.org.gmail.com (173-13-178-50-sfba.hfc.comcastbusiness.net. [173.13.178.50]) by mx.google.com with ESMTPSA id ny9sm28615559pab.25.2014.12.05.01.17.00 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 05 Dec 2014 01:17:01 -0800 (PST) From: Doug Evans To: gdb-patches@sourceware.org Subject: [COMMITTED PATCH] Revert fix to symtab/17602, bigger fix needed Date: Fri, 05 Dec 2014 01:16:10 -0800 Message-ID: MIME-Version: 1.0 X-IsSubscribed: yes Hi. This patch caused a regression in gdb.ada/operator_bp.exp. https://sourceware.org/ml/gdb-patches/2014-11/msg00642.html There's still a bug here, but the deeper I dig the bigger the problem I find. Wrong comments, confusing code, and on and on ... [More than once I've gotten to the point of wondering "How does this work at all?" :-(] So I'm going to revert this patch for now and work on a better fix. 2014-12-05 Doug Evans Revert: PR symtab/17602 * linespec.c (iterate_name_matcher): Fix arguments to symbol_name_cmp. diff --git a/gdb/linespec.c b/gdb/linespec.c index af958dc..82384ca 100644 --- a/gdb/linespec.c +++ b/gdb/linespec.c @@ -982,12 +982,7 @@ iterate_name_matcher (const char *name, void *d) { const struct symbol_matcher_data *data = d; - /* The order of arguments we pass to symbol_name_cmp is important as - strcmp_iw, a typical value for symbol_name_cmp, only performs special - processing of '(' to remove overload info on the first argument and not - the second. The first argument is what the user provided, the second - argument is what came from partial syms / .gdb_index. */ - if (data->symbol_name_cmp (data->lookup_name, name) == 0) + if (data->symbol_name_cmp (name, data->lookup_name) == 0) return 1; /* Expand this symbol's symbol table. */ return 0; /* Skip this symbol. */ }