From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26728 invoked by alias); 26 Jan 2016 22:50:11 -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: X-Seq: 37798 Received: (qmail 18336 invoked from network); 26 Jan 2016 22:50:10 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) 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.0 Date: Tue, 26 Jan 2016 22:50:08 +0000 From: Daniel Shahaf To: Zsh hackers list Subject: Re: Slow highlighting (Re: "drop-in replacement" and transpose-words-match) Message-ID: <20160126225008.GB4731@tarsus.local2> References: <160111233259.ZM6719@torch.brasslantern.com> <160118223126.ZM28565@torch.brasslantern.com> <160119195608.ZM31931@torch.brasslantern.com> <20160123235303.GE20278@tarsus.local2> <160123222057.ZM16192@torch.brasslantern.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <160123222057.ZM16192@torch.brasslantern.com> User-Agent: Mutt/1.5.23 (2014-03-12) Bart Schaefer wrote on Sat, Jan 23, 2016 at 22:20:57 -0800: > On Jan 23, 11:53pm, Daniel Shahaf wrote: > } [Re-analyzing on every keystroke] doesn't explain the slowness on > } fned buffers: the initial highlight of an fned buffer involves exactly > } one _zsh_highlight call, and yet is slow. > > Is it similarly slow on any use of "vared"? fned with z-sy-h is slow. fned without z-sy-h is fast. vared with z-sy-h is slow. I tested this with . autoload +X vcs_info autoload zed zed -f vcs_info . compared to . autoload +X vcs_info s=$(which vcs_info); vared s . . > What about with a history line containing a function definition? Also slow. Tested with: # Copy the function's definition to the clipboard, then paste it back autoload +X vcs_info which vcs_info | xsel I also tested it as a single line, and that was still slow: autoload +X vcs_info which vcs_info | perl -pe 's/\n/;/' | xsel Thanks for the help! Daniel