From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751720AbbEZXGd (ORCPT ); Tue, 26 May 2015 19:06:33 -0400 Received: from mga14.intel.com ([192.55.52.115]:35861 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751230AbbEZXGa (ORCPT ); Tue, 26 May 2015 19:06:30 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,502,1427785200"; d="scan'208";a="700631742" From: Andi Kleen To: Ingo Molnar Cc: Linus Torvalds , Josh Poimboeuf , Andy Lutomirski , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Michal Marek , Peter Zijlstra , X86 ML , live-patching@vger.kernel.org, "linux-kernel\@vger.kernel.org" , Andy Lutomirski , Denys Vlasenko , Brian Gerst , Peter Zijlstra , Borislav Petkov , Andrew Morton Subject: Re: [PATCH v4 0/3] Compile-time stack frame pointer validation References: <20150520103339.GA22205@gmail.com> <20150520141331.GA16995@treble.redhat.com> <20150520144810.GA10374@gmail.com> <20150520162537.GD16995@treble.redhat.com> <20150521075228.GA20782@gmail.com> Date: Tue, 26 May 2015 16:06:28 -0700 In-Reply-To: <20150521075228.GA20782@gmail.com> (Ingo Molnar's message of "Thu, 21 May 2015 09:52:28 +0200") Message-ID: <87lhgb0wi3.fsf@tassilo.jf.intel.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Ingo Molnar writes: > > Especially on modern x86 CPUs with stack engines (latest Intel and AMD > CPUs) that keeps ESP updates out of the later stages of execution > pipelines, going from RBP framepointers to direct ESP use is > beneficial to performance and compresses I$ footprint as well: Note that Atom doesn't have this stack engine, so you'll likely see even more difference there. > So the performance advantages of not doing framepointers is not > something we can ignore IMHO: Agreed. > but obviously performance isn't > everything - so if stack unwinding is unrobust, then we need and > want frame pointers. It wasn't that bad in the old days with the approx stack traces. In fact I bet it would be possible to write an automated tool that weeds out many (most?) false positives automatically with a static compile-time callgraph. It would be good to at least make it easier building without them again. Currently it's very difficult because a lot of subsystems force select frame pointers. -Andi -- ak@linux.intel.com -- Speaking for myself only