]> git.eshelyaron.com Git - emacs.git/commit
Clean up and improve compilation of arithmetic (bug#42597)
authorMattias Engdegård <mattiase@acm.org>
Mon, 3 Aug 2020 14:29:06 +0000 (16:29 +0200)
committerMattias Engdegård <mattiase@acm.org>
Fri, 7 Aug 2020 08:00:45 +0000 (10:00 +0200)
commit0facaeec1a37481536b6cef13c88d9728c2ec29b
treecc1c6126c46d1bc921065de555d4513de736c643
parent204273c3b9f0a77459661790aa929f86067a9ab1
Clean up and improve compilation of arithmetic (bug#42597)

* lisp/emacs-lisp/byte-opt.el (byte-optimize-associative-math)
(byte-optimize-min-max): Transform 3-arg min/max call into two 2-arg
calls, which is faster.
* lisp/emacs-lisp/bytecomp.el (byte-compile-associative): Rename to...
(byte-compile-variadic-numeric): ...this function and simplify,
fixing incorrect comments.  The 3-arg strength reduction is now
always done in the optimisers and is no longer needed here.
(byte-compile-min-max): New function.
(byte-compile-minus): Simplify, remove incorrect comment, and use
byte-compile-variadic-numeric.
(byte-compile-quo): Simplify and fix comment.
lisp/emacs-lisp/byte-opt.el
lisp/emacs-lisp/bytecomp.el