Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp390520ybe; Thu, 12 Sep 2019 22:48:56 -0700 (PDT) X-Google-Smtp-Source: APXvYqxT+M+ngbGP0hAsYc0zmu4pKReRFadQIci0cVuYPYZdpakXh7uX63g3wjOEfE7YmqFoNuyO X-Received: by 2002:a50:9e65:: with SMTP id z92mr45677890ede.49.1568353735914; Thu, 12 Sep 2019 22:48:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568353735; cv=none; d=google.com; s=arc-20160816; b=HiOhb1fav7aDtioWIuPgR6k7MqakdysdnINoI4MqBQoaJmv/aQea1Fifm14T54auGz 6wda/MEndDmPGkNZz4EHbrWoX8gyly7k4arzpGUffRAadzMDDvpUctfrxQPu4ZjhMZBE gNOygwSMENX/rEpNSuRK0Fdh8g1ZX6QTaNaei/5sSJJ5ctxW+ziVRQK6CdXmB+rwItJh SJPpWUParHDa/mRPZrk8bp0+YNrBo0XUnGNxZrjvx05wvZsAxGBGK0/ajpmHuZ5TGMqY /hsnYp04KiNhyePuNFXYD84bMWxdVez1++PxkwM3MRkwRXNrdS2wApvE0U+gI+P4yBBh Eybg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=LSlNtFgitt14dDGHoASb+NTexJIytOoP8ixydWWFIH8=; b=ek69NoiSvn87QpBMWYzRu9FKGkrZCC44JbDAVeaV/dDnbrZsehxNepmNXUeLo+49w1 XOR1YByZ46jPAQh9LuQbhupScANdFfeCJrkJhy43XMWGXacjttzKuF7DVFwCTwXiw7G3 vA7dKH/y5rRU4Bq/FoVkexUEGAkDsHU2jrrKlzkOcy2Mz9tCrJTSKrUqUeJ0CfctO4bC Y18ZK+MFcIAFwKmN5y5ie54w41VD8HymGOLeO84jT+n5C+rpLueubPSSvOrGZu/K1sIS MDA5HPAjpi9C2vSMyK3wSFhn+MSQfaxuqzF45xEZUEvt+nDscmXb8TXGOBfLNkghbb+i xzVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=mC1t5L+2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f17si20235627edf.328.2019.09.12.22.48.32; Thu, 12 Sep 2019 22:48:55 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=mC1t5L+2; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727136AbfIMFmU (ORCPT + 99 others); Fri, 13 Sep 2019 01:42:20 -0400 Received: from mail-wr1-f67.google.com ([209.85.221.67]:40032 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726203AbfIMFmU (ORCPT ); Fri, 13 Sep 2019 01:42:20 -0400 Received: by mail-wr1-f67.google.com with SMTP id l3so7992817wru.7 for ; Thu, 12 Sep 2019 22:42:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=LSlNtFgitt14dDGHoASb+NTexJIytOoP8ixydWWFIH8=; b=mC1t5L+2lz1Hw1YIv2BhKKIkjwR5PK0ME+T3ztDo6YWqH+2oZ05VaG0vCcdyBY5QU+ VeCxoxmLs4XcPdfzUIrxHjDJRv0PYdHUFYlG+l36yO3spe96pca/YBrF17ekuyhhe00N 9BNXPjzIpXbBigy+lqkQ3+gL0MB5bxzJh+vC3E+K/ENBv5qVFbb868OAiFKm6rxYTExf L1Qnzz5XnrOCeWFjXUREeMxEC8AplbBezsaHiR7M4GUXACwhqss/Mo0bfn9JJcLHVCWK rh+DbZtAALXcpp7Bv9jNJar955HILMxMuSox8VJPe/aIurBGBWFG/anyP/wh45iruqvc JDOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=LSlNtFgitt14dDGHoASb+NTexJIytOoP8ixydWWFIH8=; b=P6DW/KOJFj02x/iMN2Sk9QK41OBLGMTQjNkwFJGVTKGA0YV9FWss04HXanQT24OWuq dzg6QUcUse57alTXc02I4z2PT+yuKTSZkrOCLf9LtzZDMAy24ZCgCWvbSf9jeesCh6Ot 8vtgKEOCQHC6oZ34bYC1ChB3y092klGdlEwkgbmnKIEDOfrYbYSdDoiGdnODych+N+mY m7ba03lvqrmEkCApQ+HB3QHzgvXZr5asu4i9oxEQN6BOVRAONZGj19ardjZjX0ziVd01 5ZvEFG4Iy0BrhKi9qAQDykmd7MvktI71tw2IUa4qicanccqfsyDFSOckYunUF/ILHHkB rYrQ== X-Gm-Message-State: APjAAAVc3DdwedxflQ12EBFrZ08aDmVlIXk3wuROXvGqMv+z/ArSTSQN pA0wT1tgAcQTVPFxAo6n6D4= X-Received: by 2002:adf:a357:: with SMTP id d23mr10178038wrb.18.1568353338557; Thu, 12 Sep 2019 22:42:18 -0700 (PDT) Received: from gmail.com (2E8B0CD5.catv.pool.telekom.hu. [46.139.12.213]) by smtp.gmail.com with ESMTPSA id s19sm40392869wrb.14.2019.09.12.22.42.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 Sep 2019 22:42:18 -0700 (PDT) Date: Fri, 13 Sep 2019 07:42:15 +0200 From: Ingo Molnar To: Rasmus Villemoes Cc: Miguel Ojeda , ndesaulniers@google.com, Masahiro Yamada , Greg Kroah-Hartman , Ingo Molnar , Linus Torvalds , Nadav Amit , x86@kernel.org, linux-kernel@vger.kernel.org, Borislav Petkov Subject: Re: [PATCH v3 6/6] x86: bug.h: use asm_inline in _BUG_FLAGS definitions Message-ID: <20190913054215.GB118828@gmail.com> References: <20190830231527.22304-1-linux@rasmusvillemoes.dk> <20190912221927.18641-1-linux@rasmusvillemoes.dk> <20190912221927.18641-7-linux@rasmusvillemoes.dk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190912221927.18641-7-linux@rasmusvillemoes.dk> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Rasmus Villemoes wrote: > This helps preventing a BUG* or WARN* in some static inline from > preventing that (or one of its callers) being inlined, so should allow > gcc to make better informed inlining decisions. > > For example, with gcc 9.2, tcp_fastopen_no_cookie() vanishes from > net/ipv4/tcp_fastopen.o. It does not itself have any BUG or WARN, but > it calls dst_metric() which has a WARN_ON_ONCE - and despite that > WARN_ON_ONCE vanishing since the condition is compile-time false, > dst_metric() is apparently sufficiently "large" that when it gets > inlined into tcp_fastopen_no_cookie(), the latter becomes too large > for inlining. > > Overall, if one asks size(1), .text decreases a little and .data > increases by about the same amount (x86-64 defconfig) > > $ size vmlinux.{before,after} > text data bss dec hex filename > 19709726 5202600 1630280 26542606 195020e vmlinux.before > 19709330 5203068 1630280 26542678 1950256 vmlinux.after > > while bloat-o-meter says > > add/remove: 10/28 grow/shrink: 103/51 up/down: 3669/-2854 (815) > ... > Total: Before=14783683, After=14784498, chg +0.01% > > Signed-off-by: Rasmus Villemoes Acked-by: Ingo Molnar Thanks, Ingo