From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20557 invoked by alias); 9 Mar 2018 13:39:15 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: List-Unsubscribe: X-Seq: 42437 Received: (qmail 10186 invoked by uid 1010); 9 Mar 2018 13:39:15 -0000 X-Qmail-Scanner-Diagnostics: from aok120.rev.netart.pl by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(85.128.245.120):SA:0(-1.9/5.0):. Processed in 1.325337 secs); 09 Mar 2018 13:39:15 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.1 X-Envelope-From: psprint@zdharma.org X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | X-Virus-Scanned: by amavisd-new using ClamAV (3) Date: Fri, 9 Mar 2018 14:39:10 +0100 From: Sebastian Gniazdowski To: Stephane Chazelas Cc: Zsh hackers list Message-ID: In-Reply-To: References: Subject: Re: Performance tests of quoting and dequoting, printf -v turned out slow X-Mailer: Airmail (467) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On 9 marca 2018 at 14:23:44, Stephane Chazelas (stephane.chazelas=40gmail= .com) wrote: > I can't reproduce with zsh 5.4.2 (x86=5F64-debian-linux-gnu) > compared with 4.4.18(1)-release (x86=5F64-pc-linux-gnu). > in a en=5FGB.UT=46-8 locale. > =20 > =46WIW, I find: > =20 > =24 time INPUT=3D'ice as=22program=22 pick=22=24ZP=46X/bin/prll=5F(qer=7C= bfr)=22 src=22prll.sh=22 make=22install =20 > PRE=46IX=3D=24ZP=46X=22' bash -c 'for ((i =3D 0; i < 50000; i++)); do p= rintf -v OUTPUT %q =22=24INPUT=22; =20 > done' > INPUT=3D bash -c 1.48s user 0.00s system 99% cpu 1.485 total > =24 time INPUT=3D'ice as=22program=22 pick=22=24ZP=46X/bin/prll=5F(qer=7C= bfr)=22 src=22prll.sh=22 make=22install =20 > PRE=46IX=3D=24ZP=46X=22' zsh -c 'for ((i =3D 0; i < 50000; i++)); do pr= intf -v OUTPUT %q =22=24INPUT=22; done' =20 > INPUT=3D zsh -c 0.83s user 0.14s system 99% cpu 0.979 total > =20 > What's your version and locale=3F 5.3.1, I looked also at 5.4.2 and the results were the same. =46or your s= nippets I get the same results as you. If I source short.zsh, I again get= =7E25 sec time. I will find some time to narrow this shortly. --=C2=A0 Sebastian Gniazdowski psprint /at/ zdharma.org