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=-10.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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 12F39C4361A for ; Thu, 3 Dec 2020 18:49:22 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 92650207AD for ; Thu, 3 Dec 2020 18:49:21 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 92650207AD Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=+TvNQVVnfW/ruZkiLuztZBDPrI3ghp2N2mDwEhfPF38=; b=yxL+MQAjZhmm6cQyBap5SovP1 mJk72Xa5nk7PNy8DRuwFFQsrLpMSBX2Tn3Kv0f41cbFbjDB4LyLQzzOIQ5DgKs1i935qrtdLGm5M+ Exd3krq0G6God4kZUWmZ9cEWce93UIlolYLGGos7+K6GxU3MNjMTWuWZbxDttHXRTYaBBWjPkCqRW bTeX0YKiVBy7znBbdWPfQ1FgPGy9uLphYOaLQdUbACV6j5S+PGGGeZbn8eYMn7+KbdOE+J+5DLIFE hQPZtJ71aShR+mrDtA/IVSyIHEVp549hCCcoWkwDgtOHbZqcvL61lPYEOowVN30hGDLzHs8aHo/dy fXg+YziNw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kkte8-0004qM-29; Thu, 03 Dec 2020 18:48:04 +0000 Received: from mail-vs1-xe41.google.com ([2607:f8b0:4864:20::e41]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kkte5-0004pP-Jo for linux-arm-kernel@lists.infradead.org; Thu, 03 Dec 2020 18:48:02 +0000 Received: by mail-vs1-xe41.google.com with SMTP id h6so1827117vsr.6 for ; Thu, 03 Dec 2020 10:48:01 -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=Ah+rD4wk+k3lncQwfhIaQxiXkvEJG1Frpy4Nqe+0q0U=; b=SKhZH7li060XYzleaCahQbBQsMynLjFbQa3EhTv77mq3GHRmSi61KzLCOLC1Z4ksaj pSJDPGDFnV9Yx/X3ETP86ugtkVzY02GZAgoZstjnPNK8KrdI1fjRRRcqwKuLoZ+iGFnw Mfp9TStTmlP08QQnKRNmpPAPNNvtn/NE5MsBi6vL6DIXPVYtfI8exjpC70eIc1jAi6hr IWUJKbfX69GJkb8hVQ58bQnKSKy9x1UkfpKRekYoEUXT0JpoySwIrh8/YFahuMWMIznf +OWbSKuFcovO+Pj5wPAfXa07brxfPV5prt3FbyqI8tm/0XTPi+MmqG20rvrPzlHjF8XG lj8w== 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=Ah+rD4wk+k3lncQwfhIaQxiXkvEJG1Frpy4Nqe+0q0U=; b=WKleKpXBC4wRIL1/jSZb3f8LX/GudnYB5AWeOooNj27/O70POJU6/P9jhl6otKakxT qhWvAoCSDVOy8DGNqWqbfA3j29frj+BgH383TgWtdnA2vwd3Rx6YCeq9KaQhayBLy6l4 dFSzwghMeeTlrmP9DJIWdPFfnljlty6mPbVZTo6wgAXGXy8kFOlGAMJcvodh9u/4hkM7 rGM0+hvZKIgdAJ3YVEP4UmeDdi6dt69kAsKu1gOn4TZFN5ZDAn4M6ysyE81xq0t9leD+ iTiGDQZwkt+GLEm+3KWQqZixRxp5VzcILxCy1BSnD8qAHFaH2G17Q7E/umXZFI9+2QZh 9q7g== X-Gm-Message-State: AOAM530Qq3yT1Uu+RlyErwNREU1/P4txR3BWWTEoyNma2prZF8sIj0Vi 2P0WS9lJf4nlOXr8evA17OPuTO59ENB63Ls0GGHTBA== X-Google-Smtp-Source: ABdhPJwWZ3eYDNgK+tyHhs3o/e9jTvYAkoSVCUaRgclpcuqt9dH748zpq6nj5Jt+rgjXHu/FF8NKz82dnl1j7RfAePA= X-Received: by 2002:a67:f74f:: with SMTP id w15mr696164vso.54.1607021279552; Thu, 03 Dec 2020 10:47:59 -0800 (PST) MIME-Version: 1.0 References: <20201013003203.4168817-1-samitolvanen@google.com> <20201013003203.4168817-15-samitolvanen@google.com> <202010141549.412F2BF0@keescook> In-Reply-To: From: Sami Tolvanen Date: Thu, 3 Dec 2020 10:47:48 -0800 Message-ID: Subject: Re: [PATCH v6 14/25] kbuild: lto: remove duplicate dependencies from .mod files To: Masahiro Yamada X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201203_134801_685555_B17C97DB X-CRM114-Status: GOOD ( 24.13 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arch , X86 ML , Kees Cook , "Paul E. McKenney" , Kernel Hardening , Peter Zijlstra , Greg Kroah-Hartman , Linux Kbuild mailing list , Nick Desaulniers , Linux Kernel Mailing List , Steven Rostedt , clang-built-linux , PCI , Will Deacon , linux-arm-kernel Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Dec 3, 2020 at 10:00 AM Masahiro Yamada wrote: > > On Thu, Oct 15, 2020 at 7:50 AM Kees Cook wrote: > > > > On Mon, Oct 12, 2020 at 05:31:52PM -0700, Sami Tolvanen wrote: > > > With LTO, llvm-nm prints out symbols for each archive member > > > separately, which results in a lot of duplicate dependencies in the > > > .mod file when CONFIG_TRIM_UNUSED_SYMS is enabled. When a module > > > consists of several compilation units, the output can exceed the > > > default xargs command size limit and split the dependency list to > > > multiple lines, which results in used symbols getting trimmed. > > > > > > This change removes duplicate dependencies, which will reduce the > > > probability of this happening and makes .mod files smaller and > > > easier to read. > > > > > > Signed-off-by: Sami Tolvanen > > > Reviewed-by: Kees Cook > > > > Hi Masahiro, > > > > This appears to be a general improvement as well. This looks like it can > > land without depending on the rest of the series. > > It cannot. > Adding "sort -u" is pointless without the rest of the series > since the symbol duplication happens only with Clang LTO. > > This is not a solution. > "reduce the probability of this happening" well describes it. > > I wrote a different patch. Great, thanks for looking into this. I'll drop this patch from the next version. Sami _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel