From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.2 required=3.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_IN_DEF_DKIM_WL autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E415FC64E7B for ; Tue, 1 Dec 2020 19:52:44 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8550520870 for ; Tue, 1 Dec 2020 19:52:44 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="MU1J+Qtj" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730253AbgLATwn (ORCPT ); Tue, 1 Dec 2020 14:52:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39906 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726148AbgLATwj (ORCPT ); Tue, 1 Dec 2020 14:52:39 -0500 Received: from mail-pf1-x441.google.com (mail-pf1-x441.google.com [IPv6:2607:f8b0:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AEACCC0613CF for ; Tue, 1 Dec 2020 11:51:53 -0800 (PST) Received: by mail-pf1-x441.google.com with SMTP id o9so1777406pfd.10 for ; Tue, 01 Dec 2020 11:51:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=zJhY8u/xgI3NwUsMsFhtkWUYc2YVhnaebCX5nl2Ru6Q=; b=MU1J+QtjrMYect596h5eTpeHLQFqd4jbXkWpVSHILQafJ7WMP2JUuLbw0ninWQShV1 Eh1Oe/+AnHFQzAMXF+YolY5+IBS2Npa01AwORUkDKXWV9fN6mS0YrWE5aM6a3pZYPx6S JLerU25sXGp+vfE+oYX7kBAjMthNKxUcPBJv4x/QoiEHeCXBcp3zAnCtjXZmaSO6WA2s HCB+4snvQenMBOz4d/v8seIQWfzmgrh8oq6LB4iz4kseuvkRm/7U5F/adejklVLvC9oT HdfZ7iGJOuo4/PghZ//tjUdn1EGf0Y+yB9oLCUzML8c2pG3EpRP8Bmp/oVwP0eJ/gaA0 55pQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=zJhY8u/xgI3NwUsMsFhtkWUYc2YVhnaebCX5nl2Ru6Q=; b=Ha0kI2TfNrure3tuFTRSZnS6a3oZtu9yZQyY17iOSOjDmWgnECpSam0J6x2ARkEO4u uzSIYLOZt6HVGXUpmsrpSGScKtXOMbGc/mw2iOceQDe/lNNO896OUv1OLV8zQ3AWDNhE pgclJPDZkphdYj+PeZ7VSMRsiZQsd0qbK4l2ZjIJYECFexErS2SGAiIbHLokV+tHzPRF 3RvGQNGdpNUbRRLH66SlZp4/3Msf7e+WcyBhLTOw5T+QotcnHzXqxa4N1L8KzIsiVrFs hIlTIh04/ayb8BVc4X856iWcpPjOLQDNcXo1TNR7nsUDDGLlv0U9INHDd00Csxxcm1RU hhBg== X-Gm-Message-State: AOAM530GBo8nAq5y3bOcJ5HQgj92RM8lyYl4QLPoBX1wy8gP2TmWtgU5 /CUOJowRaMdiEQ8ZjdL9DNOfiyzMI9Td/QmlXMdcsQ== X-Google-Smtp-Source: ABdhPJx3Xdxr6ftEvN+BqvqUknUxbXtsaIoy9RJVA4UseQm3v6s7H1av1h3KcgjU/+t+wKVVMgBfbefs2TutGOwyb1w= X-Received: by 2002:a62:1896:0:b029:197:491c:be38 with SMTP id 144-20020a6218960000b0290197491cbe38mr3997304pfy.15.1606852312900; Tue, 01 Dec 2020 11:51:52 -0800 (PST) MIME-Version: 1.0 References: <20201118220731.925424-1-samitolvanen@google.com> <20201130120130.GF24563@willie-the-truck> <202012010929.3788AF5@keescook> In-Reply-To: <202012010929.3788AF5@keescook> From: Nick Desaulniers Date: Tue, 1 Dec 2020 11:51:41 -0800 Message-ID: Subject: Re: [PATCH v7 00/17] Add support for Clang LTO To: Kees Cook Cc: Will Deacon , Sami Tolvanen , Masahiro Yamada , Steven Rostedt , Josh Poimboeuf , Peter Zijlstra , Greg Kroah-Hartman , "Paul E. McKenney" , clang-built-linux , Kernel Hardening , linux-arch , Linux ARM , Linux Kbuild mailing list , LKML , PCI Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Dec 1, 2020 at 9:31 AM Kees Cook wrote: > > On Mon, Nov 30, 2020 at 12:01:31PM +0000, Will Deacon wrote: > > Hi Sami, > > > > On Wed, Nov 18, 2020 at 02:07:14PM -0800, Sami Tolvanen wrote: > > > This patch series adds support for building the kernel with Clang's > > > Link Time Optimization (LTO). In addition to performance, the primary > > > motivation for LTO is to allow Clang's Control-Flow Integrity (CFI) to > > > be used in the kernel. Google has shipped millions of Pixel devices > > > running three major kernel versions with LTO+CFI since 2018. > > > > > > Most of the patches are build system changes for handling LLVM bitcode, > > > which Clang produces with LTO instead of ELF object files, postponing > > > ELF processing until a later stage, and ensuring initcall ordering. > > > > > > Note that v7 brings back arm64 support as Will has now staged the > > > prerequisite memory ordering patches [1], and drops x86_64 while we work > > > on fixing the remaining objtool warnings [2]. > > > > Sounds like you're going to post a v8, but that's the plan for merging > > that? The arm64 parts look pretty good to me now. > > I haven't seen Masahiro comment on this in a while, so given the review > history and its use (for years now) in Android, I will carry v8 (assuming > all is fine with it) it in -next unless there are objections. I had some minor stylistic feedback on the Kconfig changes; I'm happy for you to land the bulk of the changes and then I follow up with patches to the Kconfig after. -- Thanks, ~Nick Desaulniers