[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: |
Thu, 16 Nov 2023 17:02:09 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
João Távora <joaotavora@gmail.com> writes:
> But this one stands out. I hope you can read this macro more or less.
>
> (joaot/with-benchmark-group "destructuring"
> ((list1 . (make-list 3 0)))
> 100000
> (joaot/bench (pcase-let ((`(,a ,b ,c) list1)) (+ a b c)))
> (joaot/bench (cl-destructuring-bind (a b c) list1 (+ a b c)))
> (joaot/bench (seq-let (a b c) list1 (+ a b c))))
>
> Running in Emacs -Q:
>
> ("destructuring"
> (cl-destructuring-bind "FASTEST" 0.010702393 0 0.0)
> (pcase-let "1.3x SLOWER" 0.014360937999999998 0 0.0)
> (seq-let "3.5x (rel 2.6x) SLOWER" 0.03706726 0 0.0))
>
> Where after loading m6sparse.el we go to this:
>
> (("destructuring" (cl-destructuring-bind "FASTEST" 0.010157632 0 0.0)
> (pcase-let "1.3x SLOWER" 0.013152518000000002 0 0.0)
> (seq-let "14.8x (rel 11.4x) SLOWER" 0.15057331499999999
> 6 0.04785139399999849))
Isn't seq-let directly translated into a pcase-let call (it's a
simplistic macro)? How is this possible?
Michael.
- Re: What's missing in ELisp that makes people want to use cl-lib?, (continued)
- Re: What's missing in ELisp that makes people want to use cl-lib?, João Távora, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, Dmitry Gutov, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, João Távora, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, João Távora, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, Dmitry Gutov, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, Gerd Möllmann, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, Dmitry Gutov, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, João Távora, 2023/11/15
- Re: What's missing in ELisp that makes people want to use cl-lib?, Gerd Möllmann, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, João Távora, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?,
Michael Heerdegen <=
- Re: What's missing in ELisp that makes people want to use cl-lib?, João Távora, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, Gerd Möllmann, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, João Távora, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, Gerd Möllmann, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, Gerd Möllmann, 2023/11/17
- Re: What's missing in ELisp that makes people want to use cl-lib?, Gerd Möllmann, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, Dmitry Gutov, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, Stefan Monnier, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, Dmitry Gutov, 2023/11/16
- Re: What's missing in ELisp that makes people want to use cl-lib?, Eli Zaretskii, 2023/11/17