summaryrefslogtreecommitdiffstats
path: root/stdlib/optimize.tl
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2023-04-17 16:55:21 -0700
committerKaz Kylheku <kaz@kylheku.com>2023-04-17 16:55:21 -0700
commita50921651490df9b6278c20290b4e428cfc7d057 (patch)
tree978cbac0acadde0778d0413b3233c5054211087b /stdlib/optimize.tl
parenta4e89a91bff4de065b138a6fa4183cb4234d42c2 (diff)
downloadtxr-a50921651490df9b6278c20290b4e428cfc7d057.tar.gz
txr-a50921651490df9b6278c20290b4e428cfc7d057.tar.bz2
txr-a50921651490df9b6278c20290b4e428cfc7d057.zip
compiler: propagate t-reg rename into end insn.
* stdlib/optimize.tl (basic-blocks rename): When we stop the renaming due to an end instruction and the src being a v-reg, we can still do the rename in that end instruction itself. If the v-reg becomes invalid, that doesn't happen until after the instruction.
Diffstat (limited to 'stdlib/optimize.tl')
-rw-r--r--stdlib/optimize.tl2
1 files changed, 1 insertions, 1 deletions
diff --git a/stdlib/optimize.tl b/stdlib/optimize.tl
index f3e2a6c6..095350d3 100644
--- a/stdlib/optimize.tl
+++ b/stdlib/optimize.tl
@@ -385,7 +385,7 @@
(cond
(close (add insn))
((and vreg end)
- (add insn)
+ (add (subst-preserve dst src bb li insn))
(pend insns)
(set insns nil))
((or (mequal dst li.def0 li.def1)