From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751320Ab1GYG0c (ORCPT ); Mon, 25 Jul 2011 02:26:32 -0400 Received: from mx3.mail.elte.hu ([157.181.1.138]:56487 "EHLO mx3.mail.elte.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750987Ab1GYG02 (ORCPT ); Mon, 25 Jul 2011 02:26:28 -0400 Date: Mon, 25 Jul 2011 08:25:42 +0200 From: Ingo Molnar To: Anton Blanchard Cc: Peter Zijlstra , Paul Mackerras , Arnaldo Carvalho de Melo , emunson@mgebm.net, linux-kernel@vger.kernel.org Subject: Re: [PATCH] perf: Fix symbol resolution on old ppc64 ABI Message-ID: <20110725062542.GA694@elte.hu> References: <20110725142356.0c722c6b@kryten> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110725142356.0c722c6b@kryten> User-Agent: Mutt/1.5.21 (2010-09-15) X-ELTE-SpamScore: -2.0 X-ELTE-SpamLevel: X-ELTE-SpamCheck: no X-ELTE-SpamVersion: ELTE 2.0 X-ELTE-SpamCheck-Details: score=-2.0 required=5.9 tests=BAYES_00 autolearn=no SpamAssassin version=3.3.1 -2.0 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Anton Blanchard wrote: > The synthetic symbol creation code has an issue with the old ppc64 > ABI. We end up with duplicate symbols of different sizes that > overlap. > > To fix this, walk all of the symbols and remove any duplicates that > are the length of a function descriptor. > I'd prefer not to add a ppc64 specific hack here, but I'm not sure > how we can fix this in a simpler way. Symbol space problems are common on other architectures as well. We could use a heuristic: when symbols are overlapping then we could throw away the one that is smaller. This would implicitly cover the ppc64 case, right? I'd also suggest we warn somewhere that a symbol has been thrown away, if verbosity is turned off. (i.e. don't warn by default.) Thanks, Ingo