From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web08.2887.1646095680835186270 for ; Mon, 28 Feb 2022 16:48:01 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=eFKOIJzf; spf=pass (domain: intel.com, ip: 192.55.52.93, mailfrom: guomin.jiang@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1646095680; x=1677631680; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=yqUlZ5KvA9Z+s19++TdbfmB5oY4wTi8t2/XUePRjxII=; b=eFKOIJzfm3IK/oaaKLxdEXHkeJabeuCzaDWqOhfOeT/Xg08Rm7bqLVi9 CgNwHJpB3LWHul+ijZuUaS0cSpe8ichkapX4jZDYK8Pe1hty8dCNnU0EJ VJGZtESP/x5csVnY5nwby9npm9IfX+sKJFb7eOGbR24NVmFnSlpc7vFrd nKyK4QxR4JQMCKUA110HxlJcTOzS5cW2ZO+PDlIvema3gjQhi0TNnHne9 s5xfDMOMW5If3CnmiRVZzQNnjLk/aEtguCSFy1hp7DMbdAkbBwpqV4S53 P/UBBuMspT+zJAKIw9sDE3kMqwQvSLycZcW/+oBOPTU2O8WPYeAnWDZlU g==; X-IronPort-AV: E=McAfee;i="6200,9189,10272"; a="250606556" X-IronPort-AV: E=Sophos;i="5.90,144,1643702400"; d="scan'208";a="250606556" Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Feb 2022 16:47:50 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.90,144,1643702400"; d="scan'208";a="507618230" Received: from fmsmsx601.amr.corp.intel.com ([10.18.126.81]) by orsmga002.jf.intel.com with ESMTP; 28 Feb 2022 16:47:49 -0800 Received: from fmsmsx608.amr.corp.intel.com (10.18.126.88) by fmsmsx601.amr.corp.intel.com (10.18.126.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Mon, 28 Feb 2022 16:47:49 -0800 Received: from fmsmsx602.amr.corp.intel.com (10.18.126.82) by fmsmsx608.amr.corp.intel.com (10.18.126.88) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Mon, 28 Feb 2022 16:47:48 -0800 Received: from FMSEDG603.ED.cps.intel.com (10.1.192.133) by fmsmsx602.amr.corp.intel.com (10.18.126.82) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21 via Frontend Transport; Mon, 28 Feb 2022 16:47:48 -0800 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.169) by edgegateway.intel.com (192.55.55.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.20; Mon, 28 Feb 2022 16:47:48 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=VxoB2n/uFzhejXGUwhE5xE2sRwGL2Ki6o1c96bFKpri2nhHM0yllwP8FghsN7YngdRrb6dYDbTVZkrrc6d8EvLye5fL05DqBJYPbCqfLupfXE7qnJiglFBB13d4OTR0yTkQppNlZaiAlGlWeOF+OiFoOYAi+gMV6cx7Y69TqzVXqbn8bLiJPsgvlPUybzWzrGitn/kVOd988+Bb2WSdm6Iic6wrGU1tKuyMJEBGRs4lqgYp4WabZek04+6TzIdaVWGDTUf+fQpyrwxXrwN/u4ir7MpvsTs8kOvEF0//RNNO+LnZq7P7mUeAVOuXfsIMNVdBeCL+oEsWXZEQvrZmAIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=cPaalBTwAqQT2bYAlKeaOspgLcstESljtij5949yUrw=; b=HwkpfbAuqgTXstujBsq3Mj0OFE/PaAhrOxunoj6H8RtnZu9VQ3L8ABa7WEcjMQWvXlVRY6VPZGKkqmhHMzK6Htal4rWHuFVw+Gg9n2H4IZGZtouX2TLjFam2mEBmcN7j0JPJX2DEqKK33ZLJFpH2NM5Q3xoWB58CavENhMp3m/++KO8rweshYwEaMIcwGrmfzGyTl+KxFPqKwuTH5NOXf/V87erNnHyPITJPoDCptLcMm4B3Rc5vjaUDfY8SdEC8rfsXZ7/rQyNfbdS+c2QQRgQx57rZjqD9vefnxCbfDILXribHFab8kW8iaWGCvwX8ayACXxoWRZiAkisklWak/g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from BN0PR11MB5696.namprd11.prod.outlook.com (2603:10b6:408:14b::11) by DM6PR11MB2715.namprd11.prod.outlook.com (2603:10b6:5:be::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.21; Tue, 1 Mar 2022 00:47:44 +0000 Received: from BN0PR11MB5696.namprd11.prod.outlook.com ([fe80::f80c:f1ef:6d46:20ec]) by BN0PR11MB5696.namprd11.prod.outlook.com ([fe80::f80c:f1ef:6d46:20ec%2]) with mapi id 15.20.5017.027; Tue, 1 Mar 2022 00:47:44 +0000 From: "Guomin Jiang" To: "Feng, Bob C" , "devel@edk2.groups.io" CC: "Gao, Liming" , "Chen, Christine" Subject: Re: [PATCH 1/2] BaseTools/Conf: Reduce the ASSERT patch to save the binary size Thread-Topic: [PATCH 1/2] BaseTools/Conf: Reduce the ASSERT patch to save the binary size Thread-Index: AQHYJG+giTf6OkgmkUqHfIfPee1/oqyoyKsAgAD6FYA= Date: Tue, 1 Mar 2022 00:47:44 +0000 Message-ID: References: <20220218023008.1347-1-guomin.jiang@intel.com> <20220218023008.1347-2-guomin.jiang@intel.com> In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.5.1.3 dlp-product: dlpe-windows dlp-reaction: no-action authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: acaa9907-9499-491a-8902-08d9fb1d192c x-ms-traffictypediagnostic: DM6PR11MB2715:EE_ x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: BqDY2DFYh42IL9gtVItxDS0S0RCcRUF9E10dHXZxOWrM4p/dUlok5JXycxdqvrQGAV1ccusm63CCJZUlLqma41t6qAZb9Pma4I/HWnR+dRgVkg5pTwGm3cm3zN1zSRMzAZBcu8mQQogUDrDrj+VbnGi4l2fqcgfaP86Ut2YNro+T2+zRzhuKSBYA5SLVy4Q2eiDH7NTmMQkzroFcEDUuumiW9LlE5e/v0e69B4Tm2sHSSpJJMi4IMzn6tZoVH1WGcgjHOSWydUXRP7JPDi6Hr9/EFHDdTrqZojT/b/1+XwZWVHvuhq1LtpUsiRNhb+6PUT4dULSyn2iHu3mtm5cMU/jei1LGsf1K8VLfGsnXzvBaIRlRHAoxmm9bN31IrBjljShF6s7IjB2uXq4cu7BLglep+EW8/2m9DYFj7iPUVH8g6Jajn7c5278ujtXPqh9SW948X0cF4qj5fW+J/z4bWDF2ukzje0me+OBO9+aWm7jwwryuKMJagEfHbAtH2Rzm3R9FSbN4FI/dQbplhMmnPNYSHlxRkgC9MwS3Fk9HiCvbUoc0Fvi+6qxGR4SuGQ3dop1sPZeBb0Zdq8szT38T1EvJjLqNoYdoqicOX254YCktjRVXqFih+vctCVa8RJxt95B+5BVFFgFVpEI+nqA58mfpcQF4Wy2gTDKIdAODx+fYPXSDdgpEAhEG8bv7rBd0EodfY0VX878fIXdzokTNtqENXioOc3he7tCbLPse4m7BifFakwHH2Y83l3KQhMIMAYGuEE3Rk3ckvqmFcyMBkGXuh4DhFra+s6Xx4rTqQOg= x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BN0PR11MB5696.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230001)(366004)(64756008)(6506007)(7696005)(71200400001)(8676002)(66446008)(53546011)(316002)(83380400001)(54906003)(76116006)(66946007)(8936002)(52536014)(4326008)(66556008)(5660300002)(55016003)(110136005)(66476007)(9686003)(2906002)(86362001)(33656002)(38100700002)(508600001)(26005)(186003)(107886003)(966005)(38070700005)(82960400001)(122000001);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?UVH/OiNix8ZFOH89b/ziNDxE1fG3qceIEz9kSVnus1lpuWgYw9ErqJluKERv?= =?us-ascii?Q?ze1chRM0fxDD62tiS0k+AM5aRzTpveJCZYjDDqX8Wfoc+tHe9iH9kk0VJMOg?= =?us-ascii?Q?j2Xt+C4lFHd4ZA6yIHhBGtKwILNDbZw1TorDZrWezMysbPs3f25QzQYUCqVp?= =?us-ascii?Q?YoZO+3fnIoveFWiJ2+7v0prTTHmB6csbKEuF+oGVEbmhNQd4byHsx+Iji3bK?= =?us-ascii?Q?L6kUOSL7ql7wLHD+/XbIO/M0Dc+er0XIY51wJs5+DMT61Dk/IqzTIQ6gopxh?= =?us-ascii?Q?R5y1EEYseBvkOgTtY51AOUYxLVpduaEnm90yeTuN1q8udk+f80BKsEpAamIP?= =?us-ascii?Q?BauEh9yUOG6o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ascii?Q?2wcJs68MS6d+vILcxArjfCCAi2G2+tf45rTuxpPIPpzDuHEZuNr4S+qRyqBD?= =?us-ascii?Q?y8GX3yAOxxaT5pHytvR2rXEvkCpHdEFh1H2aiBpUhwU5r68VRDS1ISSnbsGD?= =?us-ascii?Q?pCBfF8vSp6hxZAVW+tZjhhLZwgG6oNAsbDdapE+aYEfO0jgVW2x9RtgoLsTJ?= =?us-ascii?Q?3KXsgXZUMJmosu9le285AIHoZVNrqI4B6FmpPb5xG2p2CU7PFVhBooRhtfzj?= =?us-ascii?Q?mrtZUxpvXmGAq50M0XeStBklEMyMMSIJE+etgevKZzSGlx4i+lRws7kVq2lJ?= =?us-ascii?Q?KRKY0QXOMre3jkxSigJZ/MSfdtxb5eQ+PDrz5yciUTbRgNzn6tzs3HafpYnH?= =?us-ascii?Q?D+s/xL4URcG2cpsW/ON5HCc=3D?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BN0PR11MB5696.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: acaa9907-9499-491a-8902-08d9fb1d192c X-MS-Exchange-CrossTenant-originalarrivaltime: 01 Mar 2022 00:47:44.3358 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 082lFuO8JE0bud8cy4eDpVXD9OBsWd39dBKENiLWSArRl0CUPR65C0rlerlOOe2XSx0I/IpPqEiAewir76GpXg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR11MB2715 Return-Path: guomin.jiang@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi Bob, Have and the review link to the Bugzilla. Thanks > -----Original Message----- > From: Feng, Bob C > Sent: Monday, February 28, 2022 5:52 PM > To: Jiang, Guomin ; devel@edk2.groups.io > Cc: Gao, Liming ; Chen, Christine > > Subject: RE: [PATCH 1/2] BaseTools/Conf: Reduce the ASSERT patch to save > the binary size >=20 > Hi Guomin, >=20 > I think this patch should work. > I concern the case that there would be already DEBUG_FILE macro defined i= n > some existing platform. >=20 > Could you add the 2 patches' review link to the Bugzilla? >=20 > And I'd like to see the other associated patch review comments also. >=20 > Thanks, > Bob >=20 > -----Original Message----- > From: Jiang, Guomin > Sent: Friday, February 18, 2022 10:30 AM > To: devel@edk2.groups.io > Cc: Feng, Bob C ; Gao, Liming > ; Chen, Christine > Subject: [PATCH 1/2] BaseTools/Conf: Reduce the ASSERT patch to save the > binary size >=20 > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3840 >=20 > Use DEBUG_FILE to control ASSERT path >=20 > Motivation and Goal: > 1. The path will occupy many size in DEBUG build when file path is long 2= . We > hope can reduce the size but not impact the debug capability 3. If only u= se > filename, we can search the filename to locate file. It > can save many size meanwhile. >=20 > Cc: Bob Feng > Cc: Liming Gao > Cc: Yuwei Chen > Signed-off-by: Guomin Jiang > --- > BaseTools/Conf/build_rule.template | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) >=20 > diff --git a/BaseTools/Conf/build_rule.template > b/BaseTools/Conf/build_rule.template > index f40118234471..ad0bae42be62 100755 > --- a/BaseTools/Conf/build_rule.template > +++ b/BaseTools/Conf/build_rule.template > @@ -1,5 +1,5 @@ > # > -# Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved. > +# Copyright (c) 2007 - 2022, Intel Corporation. All rights > +reserved.
> # Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved. # > Copyright (c) 2020, ARM Ltd. All rights reserved.
# SPDX-License- > Identifier: BSD-2-Clause-Patent @@ -126,14 +126,14 @@ > $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.obj >=20 > > - "$(CC)" /Fo${dst} $(DEPS_FLAGS) $(CC_FLAGS) $(INC) ${src} > + "$(CC)" /Fo${dst} $(DEPS_FLAGS) /D DEBUG_FILE=3D"\"${s_base}.c\"= " > + $(CC_FLAGS) $(INC) ${src} >=20 > > # For RVCTCYGWIN CC_FLAGS must be first to work around pathing > issues > - "$(CC)" $(DEPS_FLAGS) $(CC_FLAGS) -c -o ${dst} $(INC) ${src} > + "$(CC)" $(DEPS_FLAGS) -D DEBUG_FILE=3D"\"${s_base}.c\"" > + $(CC_FLAGS) -c -o ${dst} $(INC) ${src} >=20 > > - "$(CC)" $(DEPS_FLAGS) $(CC_FLAGS) -o ${dst} $(INC) ${src} > + "$(CC)" $(DEPS_FLAGS) -D DEBUG_FILE=3D"\"${s_base}.c\"" > + $(CC_FLAGS) -o ${dst} $(INC) ${src} >=20 > [C-Code-File.BASE.AARCH64,C-Code-File.SEC.AARCH64,C-Code- > File.PEI_CORE.AARCH64,C-Code-File.PEIM.AARCH64,C-Code- > File.BASE.ARM,C-Code-File.SEC.ARM,C-Code-File.PEI_CORE.ARM,C-Code- > File.PEIM.ARM] > > @@ -146,7 +146,7 @@ > $(OUTPUT_DIR)(+)${s_dir}(+)${s_base}.obj >=20 > > - "$(CC)" $(CC_FLAGS) $(CC_XIPFLAGS) -c -o ${dst} $(INC) ${src} > + "$(CC)" -D DEBUG_FILE=3D"\"${s_base}.c\"" $(CC_FLAGS) > + $(CC_XIPFLAGS) -c -o ${dst} $(INC) ${src} >=20 > [C-Header-File] > > -- > 2.35.1.windows.2