From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Fri, 11 Nov 2022 18:55:39 +0100 Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1otYFf-004XBw-04 for lore@lore.pengutronix.de; Fri, 11 Nov 2022 18:55:39 +0100 Received: from localhost ([127.0.0.1] helo=metis.ext.pengutronix.de) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1otYFe-000530-Bq; Fri, 11 Nov 2022 18:55:38 +0100 Received: from mail-db8eur05on2065.outbound.protection.outlook.com ([40.107.20.65] helo=EUR05-DB8-obe.outbound.protection.outlook.com) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1otYEs-00052n-F3; Fri, 11 Nov 2022 18:54:51 +0100 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lBPjzh1I6HRorZV9nd8KTJvzJ6L92MhsaX0MrkgdmZb7Lrayc62LcfuQu4xgLRNDmIdgyTbKcE4bW0LuSjzwWWFLx4Z/qfTJJ9SEW6LIS4/mq9kE2CckErkBG9K6xRzNQSwyZ38ryhUnJJes4v428iR6IEMgavc+1/x/xmVhMDSjzrOVx9eYH5cH4XKui9LEmHQ1xDXXN9TdUQPAKskAx4iq0jePCruTKe+UFS0z8W5oTzc2Dc/sWqiwZzjOLGPJXGWbF3d5rvLB39ZiGXA9JhM4wSgrxeC3c7F6k2x9WTx77n3stUmuIP5/hUxZnH06U57zGHmud0Ee8kdyr3JCnQ== 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=lYuY9ZKeDww6HEWC6XSzMeIwW0QhPJqV/bcHlC7CZX8=; b=Kfx6QFgXB6+V7D3T2pTxYVcjo9EvtbRMyTq64uGJaQUEpa36rCZjECPPjlSXjQoVZksn/d4eBOVPIAsFz+WeaWRGauOcG0A28yoWN9odcvw1DLw9RTjaJzEJjuDk0IwBKIeb+84kXZ4vXv+EvPfa+eyEKTuZjXzj9wbJafA3d9j7scuXgIElUTlPg217co7Fv4zJg8dYcrokEuQnMI7GUb8229SlxaJ+fIJwG4bAVzZgyFNQifIyf2JXsg96JZEeYdyMe30W2PB2Xr4PQ1HU0A1SUGRbk520z54jOzJKujt1/L6Ips4vxGEdOP7I2rptJ/HzvvvXrNMYKsWMhpJ0aQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=t2data.com; dmarc=pass action=none header.from=t2data.com; dkim=pass header.d=t2data.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=t2datacom.onmicrosoft.com; s=selector1-t2datacom-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lYuY9ZKeDww6HEWC6XSzMeIwW0QhPJqV/bcHlC7CZX8=; b=Q5x1pa4ZudhrvY3yxFmCljsmpDZi4MMxtyy69/SOqWHDIq+bQVZhMlztJBS9mbWDx+F2obv701FUDd2MQWeAPRvcp+GNNVeCsdzOK8lGnG+z4TLix4NQ7GrHDWQWhoJuIUkg8PEPYARPVLbDg1vyBp5CWOhp+6uBHXt0cnfZ8Ag= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=t2data.com; Received: from DB9P251MB0618.EURP251.PROD.OUTLOOK.COM (2603:10a6:10:334::22) by PAXP251MB0672.EURP251.PROD.OUTLOOK.COM (2603:10a6:102:275::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5813.13; Fri, 11 Nov 2022 17:54:47 +0000 Received: from DB9P251MB0618.EURP251.PROD.OUTLOOK.COM ([fe80::db66:4269:9534:aab]) by DB9P251MB0618.EURP251.PROD.OUTLOOK.COM ([fe80::db66:4269:9534:aab%4]) with mapi id 15.20.5813.013; Fri, 11 Nov 2022 17:54:46 +0000 Message-ID: <30e96415-0a1e-2d3f-23a9-506b4a563119@t2data.com> Date: Fri, 11 Nov 2022 18:52:38 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.1 To: Michael Olbrich References: <75f0b7f568884d33af8f5c6bc23bd5dd@eks-engel.de> <2aa3b38a-9025-d88e-8364-fea4ada10f3a@t2data.com> <20221111160821.GG27612@pengutronix.de> Content-Language: en-US From: Christian Melki In-Reply-To: <20221111160821.GG27612@pengutronix.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-ClientProxiedBy: GV3P280CA0004.SWEP280.PROD.OUTLOOK.COM (2603:10a6:150:b::18) To DB9P251MB0618.EURP251.PROD.OUTLOOK.COM (2603:10a6:10:334::22) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DB9P251MB0618:EE_|PAXP251MB0672:EE_ X-MS-Office365-Filtering-Correlation-Id: 5ba7d1fd-89a3-472d-c1d3-08dac40dd232 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: mVRm4VduiusDEFLwD3eXO4r2OcHrBOcDm419NkcYkmqVEW7ESd8mXgLLTOSFMdVtzzK0cjAgkgkRb/r7D6myJsN5EHWkJRprx5U9tDiMYPqfZJGwUFRCONbFqsKbFzGf7b6p48dQOA2LrHK/IoGcDAkQyZY6UgljDlhI1c7e7co6W9WVyHjM718yDBGuMHVT96Dlwo3QlDaa4YxDfEa+tNXUV0Ms8dJZFba05OwXP+PR/5SFlPmVZqKfKmOaebbZyo6A6FLy6Gj6tWtnteMdViW6MU3Lr+f++9Z3/+nCB5Pbtpj5Z4mBZqAYKYc/yDHBYey3g5pVb7N4t7ZakcIklgeAuZjNAMrOZjTJqWumiRW5lJUq0unrz8HLbQlb5v+YTRWOcfGlMTHvWJLUYVZGFbBHhi3LJE7yffBkAiURoLV+ASv+eCX8CJZDaqfKzJ8gpD4REBtDdjFYgj0AxTvRvfhlHQz9c7IMwpBBgPmxaM5OGUYdQa/O2MF/gzr8ntOWRMuhqj4scEoaFeoBqRVBwW8onb99gFJb7dUDgEzAH4gW/AaAlc8Hu9i/ITWI9oKFAHK1NeS6/vC9TQw/WhJ7ba8LQ7OMYxvQPWQCKfh74MwGza9bmFI4+4l3O51TfngKGevJo/nnjd83oaZQx9nvdKl9SmfGoAHyrSO5ZTH//G3T9sF5uvnQD6t0npudd98/P2rFM/lPdi4XSQ/R5hlXK9+Ax2t8c65bXWz4Exk0QL31ddEN+uEY+HgA/r9nquI/2KZoCxD8WD3iJk6WEjpCpvr3LTVHNAz35n+L70RMvDnB8PVBos05xvl1RKxBK0yF X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB9P251MB0618.EURP251.PROD.OUTLOOK.COM; PTR:; CAT:NONE; SFS:(13230022)(39830400003)(366004)(346002)(396003)(376002)(136003)(451199015)(478600001)(31686004)(6666004)(966005)(31696002)(6486002)(2906002)(41300700001)(4001150100001)(6916009)(316002)(38100700002)(44832011)(86362001)(6512007)(8676002)(186003)(36756003)(66946007)(6506007)(53546011)(66556008)(26005)(83380400001)(66476007)(4326008)(8936002)(66574015)(5660300002)(3450700001)(2616005)(43740500002)(45980500001); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?Z3BBU3RnaW9JalF3VVg0a1hxbVk5YW04V1FMSVV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E0yL0UyUk9qM2FGV0cyWjJzS1AwR2ZBZENodG42?= =?utf-8?B?bktRNkRrVVA2c2RZaHJKdkxlN1QvT2YzUmNhYkYyRXJHanpaNmdwM2p5RWZz?= =?utf-8?B?T3lxMDUvdlhJeXdUbUw4TUJ5Sy9MSmsxaUNLWkNybUM5Z2NYRHVRWFJRd1d1?= =?utf-8?B?YVRob0g5Nm96SVY5QlNzVHJ4d0NhVC9hT0syT2g0VnYwQ21DeDdyRllaMXNi?= =?utf-8?B?dS9BMnlZVWo0VlZKNU44aXMyOVRyZHRMNHlmUUY0RklyZ1U1QWxxT3Y2djlj?= =?utf-8?B?bytTM1UzbDF6cTNkckNWR0ZvWjhIbWRHbkRNQjlOcFpzck5hM2o0dXFSZkdG?= =?utf-8?B?dlE9PQ==?= X-OriginatorOrg: t2data.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5ba7d1fd-89a3-472d-c1d3-08dac40dd232 X-MS-Exchange-CrossTenant-AuthSource: DB9P251MB0618.EURP251.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Nov 2022 17:54:46.8538 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 27928da5-aacd-4ba1-9566-c748a6863e6c X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: wWiboRF5VBAf9Pj5YaZMbstzybxdO8230FmWLRTVrWyJCR3apgSUwN1ZHIHZahNgQ3rN86KrRKZRt9AXWWfKqyVv0Ij4C0PvV05Utr2iQeg= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAXP251MB0672 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on metis.ext.pengutronix.de X-Spam-Level: X-Spam-Status: No, score=-2.0 required=4.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Subject: Re: [ptxdist] Speed up targetinstall of certain packages X-BeenThere: ptxdist@pengutronix.de X-Mailman-Version: 2.1.29 Precedence: list List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de, christian.melki@t2data.com Cc: post@lespocky.de, ptxdist@pengutronix.de, CG@eks-engel.de Sender: "ptxdist" X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: ptxdist-bounces@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false On 11/11/22 17:08, Michael Olbrich wrote: > Hi, > > On Tue, Nov 08, 2022 at 01:10:32PM +0100, Christian Melki wrote: >> So I did an experiment with bash loadables (builtins). >> Turns out bash has a bunch of builtin examples. >> >> I had ptxdist build me a bash-5.2 for x86_64. >> With the "loadables" make target. >> >> $ diff -urN ../lib/ptxdist-2022.11.0/rules/bash.make rules/bash.make >> --- ../lib/ptxdist-2022.11.0/rules/bash.make 2022-10-21 16:54:50.000000000 +0200 >> +++ rules/bash.make 2022-11-08 12:51:38.609794625 +0100 >> @@ -77,6 +77,16 @@ >> --$(call ptx/wwo, PTXCONF_BASH_CURSES)-curses >> # ---------------------------------------------------------------------------- >> +# Compile >> +# ---------------------------------------------------------------------------- >> + >> +$(STATEDIR)/bash.compile: >> + @$(call targetinfo) >> + @$(call world/compile, BASH) >> + @$(call compile, BASH, loadables) >> + @$(call touch) >> + >> +# ---------------------------------------------------------------------------- >> >> Since mkdir is slightly less than half of the external binary calls I had it replaced. >> I copied the scripts/lib/ptxd_make_xpkg_pkg.sh to my build path >> and created a shell-loadables directory there. >> >> $ cp platform-secplatform-x86_64/build-target/bash-5.2/examples/loadables/mkdir scripts/lib/shell-loadables/ >> >> $ ls -1 scripts/lib/shell-loadables/ >> mkdir >> >> $ diff -urN ../lib/ptxdist-2022.11.0/scripts/lib/ptxd_make_xpkg_pkg.sh scripts/lib/ptxd_make_xpkg_pkg.sh >> --- ../lib/ptxdist-2022.11.0/scripts/lib/ptxd_make_xpkg_pkg.sh 2022-10-21 16:54:50.000000000 +0200 >> +++ scripts/lib/ptxd_make_xpkg_pkg.sh 2022-11-08 13:08:18.074550829 +0100 >> @@ -682,6 +682,8 @@ >> ptxd_install_file() { >> local cmd="file" >> + #export PS4='+[${EPOCHREALTIME}][${BASH_SOURCE}:${LINENO}]: ${FUNCNAME[0]:+${FUNCNAME[0]}(): }'; set -x; >> + enable -f scripts/lib/shell-loadables/mkdir mkdir >> ptxd_install_file_impl "$@" || >> ptxd_install_error "install_file failed!" >> } >> >> without mkdir builtin: >> finished target timezone.targetinstall.post >> >> real 0m17,043s >> user 0m13,522s >> sys 0m4,138s >> >> with mkdir builtin: >> finished target timezone.targetinstall.post >> >> real 0m12,345s >> user 0m9,899s >> sys 0m2,916s > > So loadable builtins in bash is interesting, but not something we can rely > on at this time. But this whole thing got me thinking. Most mkdirs are > don't actually do anything. They are just in case the directory does not > exist yet. So we can do that: > > if [ ! -d "${dir}" ]; then > mkdir -p "${dir}" > fi > > That avoid most of the mkdirs and the speedup is considerably. Similar to > the builtin I think. And I found some more things to improve: > > The 'flock' is only needed when building packages in parallel, so we can > skip it for things like "ptxdist drop foo.compile; ptxdist targetinstall > foo", and that's where the slow targetinstall hurts the moset. > > Do the chmod/chown with the 'install' when possible. > > And some stuff to improve the ptxdist startup time. > > For "time ptxdist targetinstall timezone" I get: > > Before: > real 0m29.167s > user 0m19.389s > sys 0m9.903s > > After: > real 0m8.887s > user 0m5.954s > sys 0m2.470s > > This stuff should hit master pretty soon. > > Thanks for the inspiration :-). > > Michael > Super! The end goal was reached either way. A faster ptxdist! Wee! :D And thanks for the kind words, Christian >> On 11/8/22 11:13 AM, Christian Melki wrote: >>> >>> >>> On 11/4/22 8:12 PM, Alexander Dahl wrote: >>>> Hello Christian, >>>> >>>> Am Fri, Nov 04, 2022 at 03:37:02PM +0000 schrieb Gieseler, Christian: >>>>> Hello, >>>>> >>>>> I have question regarding the speedup of daily work. >>>>> >>>>> We have frontend and backend of our webgui deployed with separate packages. Only task of these package is to deploy the files with >>>>> >>>>> @$(call install_tree, web-frontend, -, -, $(WEB_FRONTEND_DIR)/var-www/, /var/www/,no) >>>>> >>>>> Compile and install stages are empty. The just call targetinfo and touch to skip the stages. >>>>> >>>>> The frontend depends on the backend and the backend obviously depends on our application which is called by the backend. >>>>> So our web-frontend.in file looks like this: >>>>> ## SECTION=project_specific >>>>> >>>>> config WEB_FRONTEND >>>>>     bool >>>>>     select APP_LAYER >>>>>     select WEB_BACKEND >>>>>     prompt "e-mode Web Frontend" >>>>>     help >>>>> >>>>> As expected if i clean and compile APP_LAYER the targetinstallstage of Backend and Frontend are executed again. However this is only a Run-Time only dependency. It is a third-party archive and install_tree takes quite some time even on fast build hosts. Even it if is just a minute it is annoying to spend the time waiting during image creation. Trying to solve that i found "if RUNTIME"  für Run-Time only Dependencys in the documentation here: >>>>> >>>>> https://www.ptxdist.org/doc/daily_work_section.html#controlling-package-dependencies-in-more-detail >>>>> >>>>> So my expectation would be that if i change the webfrontend.in file like this: >>>>> >>>>> config WEB_FRONTEND >>>>>     bool >>>>>     select APP_LAYER    if RUNTIME >>>>>     select WEB_BACKEND   if RUNTIME >>>>>     prompt "e-mode Web Frontend" >>>>>     help >>>> >>>> That sounds reasonable and I would have done it the same. >>>> >>>>> The "if RUNTIME" would make sure that the targetinstall stage is not executed again if i just execute a "ptxdist clean app-layer" followed by a "ptxdist images". Same with ptxdist clean root; ptxdist images. It is clear that all targetinstall stages are executed again, but i would expect that the web-frontend is deployed earlier if no build dependency is given. >>>>> >>>>> Am i missing something, oder is the "if RUNTIME" Switch not working properly in my ptxdist-2018.12 version? Or does it have no effect on targetinstall stages? >>>> >>>> Not sure how that should behave.  However if you want to speed up the >>>> build: make sure you call ptxdist with -q or --quiet parameter.  The >>>> output on screen takes suprisingly much time, even with modern >>>> terminals, and especially when doing targetinstall of many many files >>>> (as usually the case with web frontends. been there, done that.) >>>> >>>> Greets >>>> Alex >>>> >>> >>> I have a slight disagreement here. I don't think the console is slow. >>> So I did some investigation, mostly since the slowness bugs me too. >>> I did a: >>> export PS4='+[${EPOCHREALTIME}][${BASH_SOURCE}:${LINENO}]: ${FUNCNAME[0]:+${FUNCNAME[0]}(): }'; set -x; >>> as time measurement and trace in the shellscript in question (mostly scripts/lib/ptxd_make_xpkg_pkg.sh). >>> This pretty linear progressive cpu consumption, albeit the big chunks were due to calling of external binaries. >>> >>> Then I did a timezone package clean and targetinstall. >>> When targetinstalling a zone there was calls to several binaries. >>> >>> For one zone I had external calls to (in order): >>> echo, mkdir, printf(?), flock, ls, rm, mkdir, flock, mkdir, flock, mkdir, flock, mkdir, flock, mkdir, flock, mkdir, mkdir, mkdir, mkdir, mkdir, install, install, chmod, chmod, chown, echo. >>> >>> Some of these could be internal builtins, but the consumed time suggested otherwise. >>> Either way. Each install took about 26 ms and I could account the majority of that time in forking external programs and waiting for them to return. >>> >>> So my conclusion is: The whole thing is a bit slow and bash doesn't help. >>> >>> Regards, >>> Christian >>> >>>>> >>>>> Thanks for any feedback. >>>>> BR, >>>>> Christian >>>> >>> >> >> >