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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6EDD0C001E0 for ; Mon, 14 Aug 2023 08:13:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232943AbjHNINY convert rfc822-to-8bit (ORCPT ); Mon, 14 Aug 2023 04:13:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57166 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234663AbjHNINT (ORCPT ); Mon, 14 Aug 2023 04:13:19 -0400 Received: from eu-smtp-delivery-151.mimecast.com (eu-smtp-delivery-151.mimecast.com [185.58.85.151]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D65CD10EB for ; Mon, 14 Aug 2023 01:13:09 -0700 (PDT) Received: from AcuMS.aculab.com (156.67.243.121 [156.67.243.121]) by relay.mimecast.com with ESMTP with both STARTTLS and AUTH (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id uk-mta-72-b-sFahrIMv2qrldd8e66mA-1; Mon, 14 Aug 2023 09:13:06 +0100 X-MC-Unique: b-sFahrIMv2qrldd8e66mA-1 Received: from AcuMS.Aculab.com (10.202.163.6) by AcuMS.aculab.com (10.202.163.6) with Microsoft SMTP Server (TLS) id 15.0.1497.48; Mon, 14 Aug 2023 09:12:55 +0100 Received: from AcuMS.Aculab.com ([::1]) by AcuMS.aculab.com ([::1]) with mapi id 15.00.1497.048; Mon, 14 Aug 2023 09:12:55 +0100 From: David Laight To: 'Andy Shevchenko' CC: 'Petr Mladek' , Marco Elver , "linux-kernel@vger.kernel.org" , "kasan-dev@googlegroups.com" , "linux-mm@kvack.org" , Steven Rostedt , Rasmus Villemoes , "Sergey Senozhatsky" , Alexander Potapenko , Dmitry Vyukov , Andrew Morton Subject: RE: [PATCH v2 2/3] lib/vsprintf: Split out sprintf() and friends Thread-Topic: [PATCH v2 2/3] lib/vsprintf: Split out sprintf() and friends Thread-Index: AQHZycNoqz0YrpkIvk2kVFpZOdRD+K/hpuuggAHNtgCABgRJkA== Date: Mon, 14 Aug 2023 08:12:55 +0000 Message-ID: References: <20230805175027.50029-1-andriy.shevchenko@linux.intel.com> <20230805175027.50029-3-andriy.shevchenko@linux.intel.com> <900a99a7c90241698c8a2622ca20fa96@AcuMS.aculab.com> In-Reply-To: Accept-Language: en-GB, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.202.205.107] MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: aculab.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Andy Shevchenko > Sent: 10 August 2023 14:14 > > On Wed, Aug 09, 2023 at 08:48:54AM +0000, David Laight wrote: > > ... > > > If you split headers into so many small pieces then all > > > source files will start with 3 screens of includes. I do not see > > > how this helps with maintainability. > > > > You also slow down compilations. > > Ingo's patches showed the opposite. Do you have actual try and numbers? The compiler has to open the extra file on every compile. If you include it from lots of different places it has to open it for each one (to find the include guard). Any attempted compiler optimisations have the same much the same problem as #pragma once. With a long -I list even finding the file can take a while. Probably most obvious when using NFS mounted filesystems. Especially the 'traditional' NFS protocol that required a message 'round trip' for each element of the directory path. David - Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK Registration No: 1397386 (Wales)