You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Master branch uses a substitutions map in each pass to keep track of how AST nodes are substituted, but this not fine-grained enough.
As an example, let's say we have a pass which turns if(!cond) { a(); } else { b(); } into if(cond) { b(); } else { a(); }: by substituting the whole IfStmt without tracking the condition, we lose information about it. Adding substitution info about the condition is not always possible due to interaction between substituting a node and one of its children at the same time.
In the decomp-api branch this is addressed by making it so that each pass keeps track of provenance on its own, but it would be nice to find a way to make the substitution map work.
The text was updated successfully, but these errors were encountered:
At least in this particular case, !cond and cond relating to a br instruction is valid. It's just about different interpretations of the two successors. Are there any guarantees right now on the true target of a br actually being the if branch of the statement?
Right now, br instructions are never the source of provenance of anything. cond would originate from the predicate of a br instruction, not the instruction itself
Master branch uses a
substitutions
map in each pass to keep track of how AST nodes are substituted, but this not fine-grained enough.As an example, let's say we have a pass which turns
if(!cond) { a(); } else { b(); }
intoif(cond) { b(); } else { a(); }
: by substituting the wholeIfStmt
without tracking the condition, we lose information about it. Adding substitution info about the condition is not always possible due to interaction between substituting a node and one of its children at the same time.In the
decomp-api
branch this is addressed by making it so that each pass keeps track of provenance on its own, but it would be nice to find a way to make the substitution map work.The text was updated successfully, but these errors were encountered: