diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2023-05-04 20:44:01 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2023-05-04 20:44:01 -0700 |
commit | d7949c371a527ca4064bbe59b2768361dd7ab7e0 (patch) | |
tree | fa1c3d2e53cf7aa93cabbe5fe45ab213b1f97219 | |
parent | 8e13cbf1f9de8bb1996710512e15a41c0d008771 (diff) | |
download | txr-d7949c371a527ca4064bbe59b2768361dd7ab7e0.tar.gz txr-d7949c371a527ca4064bbe59b2768361dd7ab7e0.tar.bz2 txr-d7949c371a527ca4064bbe59b2768361dd7ab7e0.zip |
compiler: bugfix: wrong condition in late-peephole.
* stdlib/optimize.tl (basic-blocks late-peephole):
The test whether lab2 is used is bogus, and will
never be true. The correct test is simply whether
the block has two or more rlinks. This makes no
-rw-r--r-- | stdlib/optimize.tl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/stdlib/optimize.tl b/stdlib/optimize.tl index bf82e5c1..9950d934 100644 --- a/stdlib/optimize.tl +++ b/stdlib/optimize.tl @@ -642,7 +642,7 @@ @lab1 . @rest) (let* ((bl [bb.hash lab2])) - (if (some bl.rlinks (op eq bb) .next) + (if (cdr bl.rlinks) insns ^((ifq ,reg (t 0) ,lab3) ,lab1 |