From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26459 invoked by alias); 20 Nov 2009 19:48:05 -0000 Received: (qmail 26395 invoked by uid 22791); 20 Nov 2009 19:48:03 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from hrndva-omtalb.mail.rr.com (HELO hrndva-omtalb.mail.rr.com) (71.74.56.124) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 20 Nov 2009 19:46:51 +0000 Received: from [192.168.23.10] (really [74.67.89.75]) by hrndva-omta04.mail.rr.com with ESMTP id <20091120194649381.ZSTH20219@hrndva-omta04.mail.rr.com>; Fri, 20 Nov 2009 19:46:49 +0000 Subject: Re: [PATCH][GIT PULL][v2.6.32] tracing/x86: Add check to detect GCC messing with mcount prologue From: Steven Rostedt Reply-To: rostedt@goodmis.org To: Andrew Haley Cc: Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , LKML , Andrew Morton , Heiko Carstens , feng.tang@intel.com, Peter Zijlstra , Frederic Weisbecker , David Daney , Richard Guenther , jakub@redhat.com, gcc , Linus Torvalds In-Reply-To: <4B06EF6F.2050507@redhat.com> References: <20091119072040.GA23579@elte.hu> <1258694593.22249.1012.camel@gandalf.stny.rr.com> <1258736456.22249.1032.camel@gandalf.stny.rr.com> <4B06EF6F.2050507@redhat.com> Content-Type: text/plain Date: Fri, 20 Nov 2009 19:48:00 -0000 Message-Id: <1258746406.22249.1035.camel@gandalf.stny.rr.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2009-11/txt/msg00583.txt.bz2 On Fri, 2009-11-20 at 19:35 +0000, Andrew Haley wrote: > Steven Rostedt wrote: > > Ingo, Thomas and Linus, > > > > I know Thomas did a patch to force the -mtune=generic, but just in case > > gcc decides to do something crazy again, this patch will catch it. > > > > Should we try to get this in now? > > I'm sure this makes sense, but a gcc test case would be even better. > If this can be detected in the gcc test suite it'll be found and > fixed long before y'all in kernel land get to see it. That's the > only way to guarantee this never bothers you again. > > H.J., who wrote the code in question, is hopefully looking at why > this odd code is being generated. Once he's done I can put a > suitable test case in the gcc test suite. Yes a gcc test suite will help new instances of gcc. But we need to worry about the instances of gcc that people have on their desktops now. This test case will catch the discrepancy between gcc and the function graph tracer. I'm not 100% convince that just adding -mtune=generic will help in all cases. If we miss another instance, then the function graph tracer may crash someone's kernel. -- Steve