[llvm] StructurizeCFG: Optimize phi insertion during ssa reconstruction (PR #101301)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 2 09:52:19 PDT 2024


================
@@ -710,10 +717,104 @@ void StructurizeCFG::findUndefBlocks(
   }
 }
 
+// If two PHI nodes have compatible incoming values (for each
+// incoming block, either they have the same incoming value or only one PHI
+// node has a incoming value), let them share the merged incoming values.
+void StructurizeCFG::mergeIfCompatible(PHINode *A, PHINode *B) {
+
----------------
arsenm wrote:

Extra blank line 

https://github.com/llvm/llvm-project/pull/101301


More information about the llvm-commits mailing list