aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrea Corallo2020-12-24 08:52:56 +0100
committerAndrea Corallo2020-12-24 15:36:46 +0100
commit2a6c6bf3242847de5d6a25acbfa2a946617df291 (patch)
treef22c592dec286a45c2e510f53e1bc671810d0ee6
parent96d4c70412ee1f3f0f797d27cd7b8bc5532ba692 (diff)
downloademacs-2a6c6bf3242847de5d6a25acbfa2a946617df291.tar.gz
emacs-2a6c6bf3242847de5d6a25acbfa2a946617df291.zip
* Use `comp-assign-op-p' into dead code elimination pass
* lisp/emacs-lisp/comp.el (comp-dead-assignments-func): Use `comp-assign-op-p' in place of `comp-set-op-p'.
-rw-r--r--lisp/emacs-lisp/comp.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el
index f73bd4b11eb..bbeaef37e3f 100644
--- a/lisp/emacs-lisp/comp.el
+++ b/lisp/emacs-lisp/comp.el
@@ -2761,7 +2761,7 @@ Return the list of m-var ids nuked."
2761 do (cl-loop 2761 do (cl-loop
2762 for insn in (comp-block-insns b) 2762 for insn in (comp-block-insns b)
2763 for (op arg0 . rest) = insn 2763 for (op arg0 . rest) = insn
2764 if (comp-set-op-p op) 2764 if (comp-assign-op-p op)
2765 do (push (comp-mvar-id arg0) l-vals) 2765 do (push (comp-mvar-id arg0) l-vals)
2766 (setf r-vals (nconc (comp-collect-mvar-ids rest) r-vals)) 2766 (setf r-vals (nconc (comp-collect-mvar-ids rest) r-vals))
2767 else 2767 else
@@ -2779,7 +2779,7 @@ Return the list of m-var ids nuked."
2779 for b being each hash-value of (comp-func-blocks comp-func) 2779 for b being each hash-value of (comp-func-blocks comp-func)
2780 do (comp-loop-insn-in-block b 2780 do (comp-loop-insn-in-block b
2781 (cl-destructuring-bind (op &optional arg0 arg1 &rest rest) insn 2781 (cl-destructuring-bind (op &optional arg0 arg1 &rest rest) insn
2782 (when (and (comp-set-op-p op) 2782 (when (and (comp-assign-op-p op)
2783 (memq (comp-mvar-id arg0) nuke-list)) 2783 (memq (comp-mvar-id arg0) nuke-list))
2784 (setf insn 2784 (setf insn
2785 (if (comp-limple-insn-call-p arg1) 2785 (if (comp-limple-insn-call-p arg1)