emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What's missing in ELisp that makes people want to use cl-lib?


From: Michael Heerdegen
Subject: Re: What's missing in ELisp that makes people want to use cl-lib?
Date: Mon, 13 Nov 2023 09:35:01 +0100
User-agent: Gnus/5.13 (Gnus v5.13)

João Távora <joaotavora@gmail.com> writes:

> Maybe seq.el can be made faster too?  Who knows, but it seems
> difficult without breaking at least some of its defgeneric-based
> contract.

Of course can it, and it is not difficult in most cases.

For example, `cl-some' has two code paths, while `seq-some' has only one
that corresponds to the more general and slower one in `cl-some'.
Nothing forbids us to add the same optimization to the `seq-some'
algorithm.

These kinds of benchmarks are more or less irrelevant.  seq.el is new
while cl-lib has been tuned and optimized for decades.  Nobody has so
far ever decidedly tried to optimize seq.el with respect to efficiency.
Not because it would be hard (it isn't) - just because nobody did the
job yet.  seq.el is in a state where most functions work reliably and
most bugs of the initial code have been fixed, but improvements are
still low relatively hanging fruits.  Unless we decide that seq.el
should intentionally have a more simple design.  But then, this would
have to be discussed again, it is a minor question compared to this one
(about cl-lib usage), IMO.

So please let's avoid such benchmarking contests here unless you want to
work on seq.el (then a bug report is a better place for discussion).
Because it has little relevance here.

Michael.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]