[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Speed of all-completions
From: |
Stefan Monnier |
Subject: |
Re: Speed of all-completions |
Date: |
Thu, 29 Apr 2010 11:14:33 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) |
Barely 6 years ago, Jesper Harder <address@hidden> wrote:
> I use icomplete-mode and I've noticed that it feels more sluggish in
> cvs Emacs than in Emacs 21.3.
> Profiling shows that the bulk of the time is spent in
> `all-completions', so I tried to benchmark it with this example:
> (defmacro time (form)
> `(let ((t1 (float-time)))
> ,form
> (- (float-time) t1)))
> (let ((oba (make-vector 255 0)))
> (dotimes (i 10000)
> (intern (format "f%i" i) oba))
> (time
> (all-completions "f" oba)))
> The time used was:
> cvs Emacs: 0.16448211669921875
> Emacs 21.3: 0.01507115364074707
> i.e. `all-completions' is roughly an order of magnitude slower in cvs
> Emacs.
I cannot reproduce it now. I tried it with `emacs21', `emacs22', and
`emacs23' (under Debian testing, and adding a 0 to the number of
iterations of your test), and I do see that Emacs is getting slower, the
difference is not nearly as large, changing from 0.05s to
0.06s, basically.
Stefan "you can always count on a prompt answer"
- Re: Speed of all-completions,
Stefan Monnier <=