From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from primenet.com.au (ns1.primenet.com.au [203.24.36.2]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id e69b7a1b for ; Fri, 6 Sep 2019 12:58:25 +0000 (UTC) Received: (qmail 11405 invoked by alias); 6 Sep 2019 12:58:16 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: List-Unsubscribe: X-Seq: 24213 Received: (qmail 26095 invoked by uid 1010); 6 Sep 2019 12:58:16 -0000 X-Qmail-Scanner-Diagnostics: from mail-io1-f46.google.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.101.2/25559. spamassassin: 3.4.2. Clear:RC:0(209.85.166.46):SA:0(-2.0/5.0):. Processed in 1.84578 secs); 06 Sep 2019 12:58:16 -0000 X-Envelope-From: pengyu.ut@gmail.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _netblocks.google.com designates 209.85.166.46 as permitted sender) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=4mvd5vIJ/EMOC4SQSnUpJRW1puK3fXj6Sz7RGwWGkRo=; b=NH1BzDI4ici1M1AG608a/YpN9U4qtuYmP1SVyR49FwuKvC4yB10Jg/XxUNPs4uippX x1ga5DWaYWoMpVwmThEYNOqWCpM0GO44IVfWo0IMI+V4ZVlS2ZIX0pwj7mV7C8Djq4hs Cwcym9Dov3q6PGpeUHWt9CxfSnf2R9L/10RMq+7qR1ueJFAE+cyawwIyNGlRm3KWGruw SAfjL5j/CjuRetD5KQevuhiQIvY35OqIY6j9YU5n47SuevJ3CBu9ebWg3RjesJZqqARu tudNRUuS5h8/dZbpVLNLStsQcsnQq3PiiXMkfxr4PQxEL4PSA2+FxoykuBV2UUUb1QFN +H/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=4mvd5vIJ/EMOC4SQSnUpJRW1puK3fXj6Sz7RGwWGkRo=; b=ev9rnD269hVvif/FqmQO4+yweSe+DkDzb3HI21FvWngFaCo2jawi7gh6drb1SUg32Z WfITP2omhplGtlzUCtE1sVJRO1Gr/3jtC6kz8JleJFusiPpdM7EjEy1ylZSaVR4AOQC5 EeySVxgENjb0q/kn6O7ljPAuRNpZH2aPl+Avj9lEm0k4reOYNkRtuSGtOsCv4CAzDqLi Vo5JB1QLWOGWRsibaAoG23OBQLKmpXGDNQ78wKlxvgyumRAlJX9rrlHARRHpthPdNKq3 uQbpBzPTfkVgYzmaGnK2Qv4G/mxyvWS+H8yeIO7vRbAx/KqdaxSNEymyOKWaml6x9AXy orFA== X-Gm-Message-State: APjAAAVdMyL35T3IGOTyER/msUqOr0zBl+rs5rf/Ag1mOA3jYeGXEXNJ VqY85DHwMmcf2Wq1a2QIcOTrwOYB6TNuTNhKRb8= X-Google-Smtp-Source: APXvYqzQ0V/aBXzNzU8lRIFcZwEgVcZabFOX0bllSoi6UTcC0CERR5f4jzAIpaj/PM3dG1keBikLiUrmQXsGkeCB41o= X-Received: by 2002:a02:c7c8:: with SMTP id s8mr10148823jao.121.1567774660686; Fri, 06 Sep 2019 05:57:40 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Peng Yu Date: Fri, 6 Sep 2019 07:57:29 -0500 Message-ID: Subject: Re: slow startup of zsh (1x slower than bash) To: Roman Perepelitsa Cc: Sebastian Gniazdowski , julien.nicoulaud@gmail.com, zsh-users Content-Type: multipart/alternative; boundary="000000000000bcff280591e1fb5d" --000000000000bcff280591e1fb5d Content-Type: text/plain; charset="UTF-8" > > > Perhaps you can change your code to spawn fewer zsh processes? I am doing so. But because zsh is much slower than bash, I will not use zsh for my scripts at all. Only if it is faster than bash, I may consider using it. I think this is one aspect that zsh developers may consider to optimize. What does your code look like? I've seen plenty of code that spends > most of its CPU time on forking but I don't recall seeing anything > that calls `zsh -dfc` or the like in a tight loop. I just use shebang to call a specific shell for a whole script. > > -- Regards, Peng --000000000000bcff280591e1fb5d--