Repository navigation
Simplify CfgBuilder to place all targets of br_table as outgoing edges of the same block - #703
Merged
Merged
Conversation
…ges from the same block
Owner
|
You'll need to push an empty change to this to force CI to run again with the fixes to CI on master. |
matthew-mojira
force-pushed
the
fix_br_table_cfg
branch
from
September 24, 2026 19:31
29d1cc4 to
4d2b383
Compare
titzer
approved these changes
Sep 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Right now the CFG Builder iterates over each target label and treats it as a chain of
br_ifinstructions. This bloats the CFG as each label in abr_tableinstruction gets its own block (whose outgoing edges are the target if that branch is taken and a fallthrough to the test on the next index). (Blocks with no instructions are very annoying on the Ball-Larus path profiler since I need an instruction associated with each edge to place a probe on.) This change makes it so that a basic block ending in abr_tablehas all its outgoing edges from the same block.