diff options
author | Alon Zakai <azakai@google.com> | 2024-03-14 10:23:37 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-14 10:23:37 -0700 |
commit | 7bd37d404e679407c283a90c4d13f770c6067229 (patch) | |
tree | 54ec4b8519020053e4073cac34f7e91e25ca48c7 /src/shell-interface.h | |
parent | 08e47de21223c3605edd71347e6b8b24b4187294 (diff) | |
download | binaryen-7bd37d404e679407c283a90c4d13f770c6067229.tar.gz binaryen-7bd37d404e679407c283a90c4d13f770c6067229.tar.bz2 binaryen-7bd37d404e679407c283a90c4d13f770c6067229.zip |
[NFC] Refactor ChildLocalizer to handle unreachable code better (#6394)
This is NFC in the current users, but is necessary functionality for a later
PR.
ChildLocalizer moves children into locals as needed. It used to stop when it
saw the first unreachable. After this change we move such unreachable
children out of the parent as well, making this more uniform: all interacting
effects are moved out, and all that is left nested in the parent can be
moved around and removed as desired.
Also add a getReplacement helper that makes using this easier.
This cannot be tested comprehensively with the current user as that user
will not call this code path on an unreachable parent at all, so this just
adds what can be tested. The later PR will have tests for all corner cases.
Diffstat (limited to 'src/shell-interface.h')
0 files changed, 0 insertions, 0 deletions