From: Andrea Corallo Date: Mon, 16 Sep 2019 18:11:05 +0000 (+0200) Subject: fix comp-compute-edges handling all kind of branches X-Git-Tag: emacs-28.0.90~2727^2~1159 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=05b733e86c108bdacd3ff45d05d560d7b8778a9b;p=emacs.git fix comp-compute-edges handling all kind of branches --- diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el index 04096d65a94..c7d9ab37958 100644 --- a/lisp/emacs-lisp/comp.el +++ b/lisp/emacs-lisp/comp.el @@ -1008,16 +1008,19 @@ Top level forms for the current context are rendered too." (cl-loop with blocks = (comp-func-blocks comp-func) for bb being each hash-value of blocks for last-insn = (car (last (comp-block-insns bb))) - for (op first _ third forth) = last-insn + for (op first second third forth) = last-insn do (cl-ecase op (jump - (edge-add :src bb :dst (gethash first - blocks))) + (edge-add :src bb :dst (gethash first blocks))) (cond-jump - (edge-add :src bb :dst (gethash third - blocks)) - (edge-add :src bb :dst (gethash forth - blocks))) + (edge-add :src bb :dst (gethash third blocks)) + (edge-add :src bb :dst (gethash forth blocks))) + (cond-jump-narg-leq + (edge-add :src bb :dst (gethash second blocks)) + (edge-add :src bb :dst (gethash third blocks))) + (push-handler + (edge-add :src bb :dst (gethash third blocks)) + (edge-add :src bb :dst (gethash forth blocks))) (return)) finally (progn (setf (comp-func-edges comp-func)