[Top][All Lists]

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

[Guile-commits] GNU Guile branch, master, updated. v2.1.0-232-g649f604

From: Andy Wingo
Subject: [Guile-commits] GNU Guile branch, master, updated. v2.1.0-232-g649f604
Date: Sat, 12 Oct 2013 14:37:22 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Guile".

The branch, master has been updated
       via  649f6043dec99337b9635893451773d9d2420a94 (commit)
      from  b8da548fba6979c02d2fe59e08265c0faf32d3e7 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 649f6043dec99337b9635893451773d9d2420a94
Author: Andy Wingo <address@hidden>
Date:   Sat Oct 12 16:36:28 2013 +0200

    More precise dead-after-use? for loop variables
    * module/language/cps/dfg.scm (dead-after-use?):
      (dead-after-branch?): A symbol defined in the header block of a loop
      is still within the same loop.


Summary of changes:
 module/language/cps/dfg.scm |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/module/language/cps/dfg.scm b/module/language/cps/dfg.scm
index af79466..ce36b1f 100644
--- a/module/language/cps/dfg.scm
+++ b/module/language/cps/dfg.scm
@@ -721,8 +721,9 @@
         ;; other ways for it to be dead, but this is an approximation.
         ;; A better check would be if all successors post-dominate all
         ;; uses.
-        (and (eqv? (lookup-loop-header use-k blocks)
-                   (lookup-loop-header def blocks))
+        (and (let ((loop (lookup-loop-header use-k blocks)))
+               (or (eqv? def loop)
+                   (eqv? (lookup-loop-header def blocks) loop)))
              (and-map (cut dominates? <> use-k blocks) uses)))))))
 ;; A continuation is a "branch" if all of its predecessors are $kif
@@ -753,8 +754,9 @@
        (($ $use-map sym def uses)
         ;; As in dead-after-use?, we don't kill the variable if it was
         ;; defined outside the current loop.
-        (and (eqv? (lookup-loop-header branch blocks)
-                   (lookup-loop-header def blocks))
+        (and (let ((loop (lookup-loop-header branch blocks)))
+               (or (eqv? def loop)
+                   (eqv? (lookup-loop-header def blocks) loop)))
               (lambda (use-k)
                 ;; A symbol is dead after a branch if at least one of the

GNU Guile

reply via email to

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