[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: address@hidden: Speed of all-completions]
From: |
David Kastrup |
Subject: |
Re: address@hidden: Speed of all-completions] |
Date: |
15 Jun 2004 15:27:53 +0200 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 |
Andreas Schwab <address@hidden> writes:
> David Kastrup <address@hidden> writes:
>
> > Andreas Schwab <address@hidden> writes:
> >
> >> David Kastrup <address@hidden> writes:
> >>
> >> > Andreas Schwab <address@hidden> writes:
> >> >
> >> >> This is due to this change:
> >> >>
> >> >> (Ftry_completion, Fall_completions, Ftest_completion): Bind
> >> >> case-fold-search to the value of completion-ignore-case when
> >> >> checking completion-regexp-list.
> >> >>
> >> >> I've checked in a fix that avoids the overhead of specbind when
> >> >> completion-regexp-list is empty.
> >> >
> >> > At the cost of being more expensive when it isn't.
> >>
> >> Why is it more expensive? The check for CONSP (completion-regexp-list)
> >> has to be done anyway, and can be CSE'd by the compiler.
> >
> > Because you are redoing the binding for every element in the loop,
> > while it is needed only once.
>
> I did not change anything in this regard.
Serves me right from just looking at the result instead of what you
started with.
To illustrate what I mean, here is a patch against the most recent
version. Note that I have to undo the binding before calling a
user-defined predicate function (which might rely on the original
binding). The last of your three changes, not running in a loop, was
not improvable, however.
txtQydVHZiUZr.txt
Description: Text Data
Does this look sane enough?
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
- address@hidden: Speed of all-completions], Richard Stallman, 2004/06/13
- Re: address@hidden: Speed of all-completions], Andreas Schwab, 2004/06/13
- Re: address@hidden: Speed of all-completions], David Kastrup, 2004/06/14
- Re: address@hidden: Speed of all-completions], Andreas Schwab, 2004/06/15
- Re: address@hidden: Speed of all-completions], David Kastrup, 2004/06/15
- Re: address@hidden: Speed of all-completions], Andreas Schwab, 2004/06/15
- Re: address@hidden: Speed of all-completions],
David Kastrup <=
- Re: address@hidden: Speed of all-completions], Andreas Schwab, 2004/06/15
- Re: address@hidden: Speed of all-completions], David Kastrup, 2004/06/15
- Re: address@hidden: Speed of all-completions], Andreas Schwab, 2004/06/15
- Re: address@hidden: Speed of all-completions], David Kastrup, 2004/06/15
- Re: address@hidden: Speed of all-completions], Andreas Schwab, 2004/06/15
- Re: address@hidden: Speed of all-completions], Luc Teirlinck, 2004/06/15
- Re: address@hidden: Speed of all-completions], David Kastrup, 2004/06/15
- Re: address@hidden: Speed of all-completions], Luc Teirlinck, 2004/06/18
- Re: address@hidden: Speed of all-completions], Richard Stallman, 2004/06/18
- Re: address@hidden: Speed of all-completions], David Kastrup, 2004/06/20