From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ingo Molnar Subject: Re: [PATCH 1/2] vsprintf: introduce %pT format specifier Date: Wed, 23 Mar 2011 14:12:13 +0100 Message-ID: <20110323131213.GA25467@elte.hu> References: <1300884395-13835-1-git-send-email-namhyung@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mx3.mail.elte.hu ([157.181.1.138]:58446 "EHLO mx3.mail.elte.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932671Ab1CWNMY (ORCPT ); Wed, 23 Mar 2011 09:12:24 -0400 Content-Disposition: inline In-Reply-To: <1300884395-13835-1-git-send-email-namhyung@gmail.com> Sender: linux-arch-owner@vger.kernel.org List-ID: To: Namhyung Kim Cc: Andrew Morton , Frederic Weisbecker , Steven Rostedt , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org * Namhyung Kim wrote: > The %pT format specifier is for stack backtrace. Its handler > sprint_trace() does symbol lookup using (address-1) to ensure > the address will not point outside of the function. > > If there is a tail-call to the function marked "noreturn", > gcc optimized out the code after the call then causes saved > return address points outside of the function (i.e. the start > of the next function), so pollutes call trace somewhat. > This patch will fix it. > > Signed-off-by: Namhyung Kim > Cc: linux-arch@vger.kernel.org > --- > include/linux/kallsyms.h | 7 +++++++ > kernel/kallsyms.c | 40 ++++++++++++++++++++++++++++++++++++++++ > lib/vsprintf.c | 7 ++++++- > 3 files changed, 53 insertions(+), 1 deletions(-) Looks useful. Please include before/after stack dump examples in the changelog, to show the difference. Thanks, Ingo