diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-10-23 07:27:15 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-10-23 07:27:15 -0700 |
commit | 84da351d88231cb480a25c816eff08d0669ac095 (patch) | |
tree | bd49e5381c63613d3ca357343ba276da3e4b35ba /stdlib/doc-syms.tl | |
parent | 153cb9fc22c4a7742948b4e066204fed6ef91bf7 (diff) | |
download | txr-84da351d88231cb480a25c816eff08d0669ac095.tar.gz txr-84da351d88231cb480a25c816eff08d0669ac095.tar.bz2 txr-84da351d88231cb480a25c816eff08d0669ac095.zip |
compiler: improvement in wasteful jmp elimination.
* stdlib/compiler.tl (compiler optimize): After the dataflow-driven
peephole optimization, call elim-dead-code again.
* stdlib/optimize.tl (basic-blocks check-bypass-empty): New method.
(basic-bocks elim-dead-code): After eliminating unreachable blocks
from the list, we use check-bypass-empty to squeeze out any
empty blocks: blocks that have no instructions in their list,
other than the leading label. This helps elim-next-jmp
to find more opportunities to eliminate a wasteful jump, because
sometimes these jumps straddle over empty blocks.
Furthermore, elim-next-jmp can generate more empty blocks itself;
so we check for this situation, delete the blocks and iterate.
Diffstat (limited to 'stdlib/doc-syms.tl')
0 files changed, 0 insertions, 0 deletions