Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp2489980rdh; Wed, 27 Sep 2023 04:27:16 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEaKGJ6IRZMkkLDLu9/m5FM/TBQDEnMLymWIBEzhWDe43UhI8W9O+poFDLbobm2qUbBFpxU X-Received: by 2002:a05:6a21:78a5:b0:14c:7021:b3f1 with SMTP id bf37-20020a056a2178a500b0014c7021b3f1mr8390141pzc.21.1695814035925; Wed, 27 Sep 2023 04:27:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695814035; cv=none; d=google.com; s=arc-20160816; b=FTKMqdasqcA3Yapeoq5Pez6oE7+iJe5+juu0/uhICN/T8JtiImDUGOfz6ZKTBHONWT 3TXP21yd4MZIe5UwT3L5tmtI90LWNCZk0KjB1ERLPYiJTZmlmGVByFAOZOsDBZDJzdhS wH3kRWTrn5Q3PC+hOG3OkHvbxUMpokk6SW9k1ZT/jYExW/2I8OUQlwGyzGylwT/gYSXs PFltGYCwkghZZQJtAoO6DjWIF0I1DJOaSxrRrqB8JOjIedbKatFnifK4f3RqtdAsN8Bv SsWkR0Arp3j8omDYNbVB6q2UREnztZnkXgYDDFcUXcj/n0CgKGluO7qiHC8XOgBVXLhd Ex7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:subject:cc:to:from:date:references:in-reply-to :message-id:mime-version:user-agent:feedback-id:dkim-signature :dkim-signature; bh=8eyX8AE9ekmLAMHsyT0GeS5BenFeWtINVJaFHwwMKHA=; fh=cr92EGwv8ObDoQQ3qXQD66zCBsuzuhaIlvjChjoMbFM=; b=btB8rMZbQt8bDvvYAFIFenMdXpodi1M+39nWINdBQA7RfL3Ii1y5ky0LUQxQIwnu8w VSjnb6bWoqeKsNArY9ydueE/oJJbiKOU0SA84a4+7YY4ycrE8qhjWuEOdR09v09hOve6 3SamVRcTsBZJyScQRPyxePccWwWJEDIe80rmNWSD/uvy/5uq5FJXnGM7QEaPXHxV1IC8 jpVJI645KhI0ZHass9hkz8UY1PVsYOPM8M/HoERbp1r/LIGohMOPFUApNzmwRuQmCsV+ exo1IdH9GPcQn7aivBT0pQoF6OG/oflONHS1rbzWk7aa7MPJ/Xx4PYs2eXXwZhwkXnUx z5ig== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (expired) header.i=@arndb.de header.s=fm1 header.b=cx8XGgkM; dkim=neutral (expired) header.i=@messagingengine.com header.s=fm2 header.b=pKJsOAmf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id x191-20020a6386c8000000b0057cf9be76c2si13372944pgd.580.2023.09.27.04.27.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Sep 2023 04:27:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=neutral (expired) header.i=@arndb.de header.s=fm1 header.b=cx8XGgkM; dkim=neutral (expired) header.i=@messagingengine.com header.s=fm2 header.b=pKJsOAmf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 7EC98828EC3D; Tue, 26 Sep 2023 04:25:03 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231754AbjIZLY4 (ORCPT + 99 others); Tue, 26 Sep 2023 07:24:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54040 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229726AbjIZLYz (ORCPT ); Tue, 26 Sep 2023 07:24:55 -0400 Received: from wout2-smtp.messagingengine.com (wout2-smtp.messagingengine.com [64.147.123.25]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C761AE9; Tue, 26 Sep 2023 04:24:44 -0700 (PDT) Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailout.west.internal (Postfix) with ESMTP id 27AAC320091E; Tue, 26 Sep 2023 07:24:43 -0400 (EDT) Received: from imap51 ([10.202.2.101]) by compute6.internal (MEProxy); Tue, 26 Sep 2023 07:24:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arndb.de; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:sender :subject:subject:to:to; s=fm1; t=1695727482; x=1695813882; bh=8e yX8AE9ekmLAMHsyT0GeS5BenFeWtINVJaFHwwMKHA=; b=cx8XGgkMMAcNeF+sP0 Xg3n1R6IWF1+SXDGfWQApF4gZU9gK98wjZ0TUjZLFzYcgq8P2RRJCuEdBdODa4hG LwKYI47Zd+dAN2sC7uN5feNdegP+GZb7mb4cJX3pFg4zNHKKCNFUQVkLrJt7eOGy av9AhHq7+EzE3QAK4jK325rz1w3OUvVLfAw7DSQa/RpNs7kW2gOSTtEgEjLwdWtt 7feAoyTVZ6ZTf8BytvH5XSxMWdPKa/nb5dXvC6xyPHZVayjpYoBqiW4jAorTVJja tKWHNOJnDGBH7Oyl+MKk4DD1HRisrJ2FlsDSQ2niXV/P7ghs31CB4+l+dtJ2ytA4 zyTA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; t=1695727482; x=1695813882; bh=8eyX8AE9ekmLA MHsyT0GeS5BenFeWtINVJaFHwwMKHA=; b=pKJsOAmfVoi/4sfxkVCOWL4nh8SdI vTNfaOPB2+Cy4Ja/lQ3Dgdcqqf/JHimuqu1zmUPu1MzuyGpR4BlyFO2fOSqdBrJD dG/SXyM6XoU2sGTJ/NWIMZUJyoecgPZl0b6nkj8lpNQjaLInMfKBHXpPk9o0zZ8N f2+asD/QlnYjipjgbC2xO89dl7+ZJh/tBYo16z1ZVbUowwfDtPnG8XSWj18p/jjv meBDvYSJBIu94daupGg0yGr0/hZUoiL/siu6JSFMX15KLH3A7lYiXNIDrCUb5iLE h/XNs2TVtz2eqKBcgk+145ybDYVcHPe7ZyW0WxZitiwz6DTkzvjhbteiw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvjedrtddtgdduudcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefofgggkfgjfhffhffvvefutgesthdtredtreertdenucfhrhhomhepfdetrhhn ugcuuegvrhhgmhgrnhhnfdcuoegrrhhnugesrghrnhgusgdruggvqeenucggtffrrghtth gvrhhnpeffheeugeetiefhgeethfejgfdtuefggeejleehjeeutefhfeeggefhkedtkeet ffenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrrh hnugesrghrnhgusgdruggv X-ME-Proxy: Feedback-ID: i56a14606:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id 716E8B60089; Tue, 26 Sep 2023 07:24:41 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.9.0-alpha0-957-ga1ccdb4cff-fm-20230919.001-ga1ccdb4c MIME-Version: 1.0 Message-Id: In-Reply-To: References: Date: Tue, 26 Sep 2023 13:24:21 +0200 From: "Arnd Bergmann" To: "Zhangjin Wu" , linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-riscv@lists.infradead.org Cc: "Palmer Dabbelt" , "Paul Walmsley" , paulburton@kernel.org, "Paul E. McKenney" , "Thomas Bogendoerfer" , "Willy Tarreau" , =?UTF-8?Q?Thomas_Wei=C3=9Fschuh?= , "Tim Bird" , "Geert Uytterhoeven" , "Nicolas Pitre" Subject: Re: [PATCH v1 0/7] DCE/DSE: Add Dead Syscalls Elimination support, part1 Content-Type: text/plain X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Tue, 26 Sep 2023 04:25:03 -0700 (PDT) On Tue, Sep 26, 2023, at 09:14, Arnd Bergmann wrote: > On Tue, Sep 26, 2023, at 00:33, Zhangjin Wu wrote: > > It would be nice to include some size numbers here for at least > one practical use case. If you have a defconfig for a shipping > product with a small kernel, what is the 'size -B' output you > see comparing with and without DCE and, and with DCE+DSE? To follow up on this myself, for a very rough baseline, I tried a riscv tinyconfig build with and without CONFIG_LD_DEAD_CODE_DATA_ELIMINATION (this is currently not supported on arm, so I did not try it there), and then another build with simply *all* system calls stubbed out by hacking asm/syscall-wrapper.h: $ size build/tmp/vmlinux-* text data bss dec hex filename 754772 220016 71841 1046629 ff865 vmlinux-tinyconfig 717500 223368 71841 1012709 f73e5 vmlinux-tiny+nosyscalls 567310 176200 71473 814983 c6f87 vmlinux-tiny+gc-sections 493278 170752 71433 735463 b38e7 vmlinux-tiny+gc-sections+nosyscalls 10120058 3572756 493701 14186515 d87813 vmlinux-defconfig 9953934 3529004 491525 13974463 d53bbf vmlinux-defconfig+gc 9709856 3500600 489221 13699677 d10a5d vmlinux-defconfig+gc+nosyscalls This would put us at an upper bound of 10% size savings (80kb) for tinyconfig, which is clearly significant. For defconfig, it's still 2.0% or 275kb size reduction when all syscalls are dropped. Arnd