zsh-workers
 help / color / mirror / code / Atom feed
From: Sebastian Gniazdowski <psprint@zdharma.org>
To: zsh-workers@zsh.org
Subject: Performance gains after the commited optimizations
Date: Sun, 24 Sep 2017 22:04:39 +0200	[thread overview]
Message-ID: <etPan.59c80fd8.70b0c06f.98a8@zdharma.org> (raw)

Hello
I've found out great gains coming from multiple optimizations. I'm writing the Doxygen-like tool in Zsh, which uses (z) flag and much processing in loops.

Processing a 1500-lines file, gains are:

- from 14 seconds to 8 seconds, thanks to patch:

2017-03-04 8522e99 40781: optimize array assignment, similar to 39995 for string assignment

– from 20 seconds to 14 seconds, thanks to patch:

2016-12-28 4fb4ce1 40231: Optimise setarrvalue().

– from 25 seconds to 20 seconds, thanks to patch:

2016-11-14 99acd1e 39906: More multibyte optimisations for US-ASCII.

– from 30 seconds to 25 seconds, thanks to patch:

2016-11-04 9c68ef0 39825: optimise mb_metastrlenend() for 7-bit character.
one other patch that contributed 1 sec, but no time and energy to run bisect


I was searching for real-word confirmation of each optimization and it was hard to find  them, only once zsh-syntax-highlighting gained from 99acd1e and 9c68ef0. Thanks for commiting those patches, they've had say "off-by-1" complexity, the possibility to break special cases, so it wasn't easy to read them. I can now parse large file in 8 seconds, while 5.0.8 does it in 38 seconds (in 5.1 probably Bart's heap optimizations matter).

--  
Sebastian Gniazdowski
psprint /at/ zdharma.org


                 reply	other threads:[~2017-09-24 20:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=etPan.59c80fd8.70b0c06f.98a8@zdharma.org \
    --to=psprint@zdharma.org \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).