We use the same similarity scheme we used for branch instructions for phi nodes, and allow them to be outlined. There is not a lot of special handling needed for these phi nodes when outlining, as they simply act as outputs. The code extractor does not currently allow for non entry blocks within the extracted region to have predecessors, so there are not conflicts to handle with respect to predecessors no longer contained in the function.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
Updating to handle changes from previous commits, more thorough testing, and bug fixes for outlining PHINodes.
llvm/lib/Transforms/IPO/IROutliner.cpp | ||
---|---|---|
183–221 | this needs Doxygen comments |
llvm/lib/Analysis/IRSimilarityIdentifier.cpp | ||
---|---|---|
63 | comment? | |
110 | comment on the loop? | |
llvm/lib/Transforms/IPO/IROutliner.cpp | ||
187 | add in-code comments to the loop? | |
195 | since Term is only used for computing BI, it might as well be folded in here. | |
197 | needs comments? | |
273 | "original beginning go the branch instruction" doesn't make a lot of sense? | |
281 | Is there a more succinct way to compute this? | |
345–346 | Remove this? |
comment?