Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751622AbbFKGLF (ORCPT ); Thu, 11 Jun 2015 02:11:05 -0400 Received: from mail-wi0-f176.google.com ([209.85.212.176]:34606 "EHLO mail-wi0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750737AbbFKGKz (ORCPT ); Thu, 11 Jun 2015 02:10:55 -0400 Date: Thu, 11 Jun 2015 08:10:50 +0200 From: Ingo Molnar To: Josh Poimboeuf Cc: Andy Lutomirski , Michal Marek , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "linux-kernel@vger.kernel.org" , Andi Kleen , live-patching@vger.kernel.org, X86 ML , "H. Peter Anvin" , Linus Torvalds , Peter Zijlstra Subject: Re: [PATCH v5 02/10] x86: Compile-time asm code validation Message-ID: <20150611061050.GB30720@gmail.com> References: <20150610175320.GD29724@treble.redhat.com> <20150610185845.GA1125@treble.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150610185845.GA1125@treble.redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1057 Lines: 24 * Josh Poimboeuf wrote: > > I imagine that an automatic CFI annotation adder would walk through functions > > one instruction at a time and keep track of the frame state. If so, then it > > could verify that common jump targets had identical state and continue walking > > through them and annotating. I think this would get this case right, and it > > might be necessary anyway to handle jumps within functions. > > This would definitely add complexity to both asmvalidate and the CFI generator. > In fact it sounds like it would push the CFI generator out of its current awk > script territory and more into complex C code territory. I'd count that as a plus: awk isn't a common skillset while C is, and properly written it doesn't have to be _that_ complex. Thanks, Ingo -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/