@@ -67,18 +67,6 @@ static cl::opt<unsigned> TailDupIndirectBranchSize(
6767 " end with indirect branches." ), cl::init(20 ),
6868 cl::Hidden);
6969
70- static cl::opt<unsigned >
71- TailDupPredSize (" tail-dup-pred-size" ,
72- cl::desc (" Maximum predecessors (maximum successors at the "
73- " same time) to consider tail duplicating blocks." ),
74- cl::init(16 ), cl::Hidden);
75-
76- static cl::opt<unsigned >
77- TailDupSuccSize (" tail-dup-succ-size" ,
78- cl::desc (" Maximum successors (maximum predecessors at the "
79- " same time) to consider tail duplicating blocks." ),
80- cl::init(16 ), cl::Hidden);
81-
8270static cl::opt<bool >
8371 TailDupVerify (" tail-dup-verify" ,
8472 cl::desc (" Verify sanity of PHI instructions during taildup" ),
@@ -573,14 +561,6 @@ bool TailDuplicator::shouldTailDuplicate(bool IsSimple,
573561 if (TailBB.isSuccessor (&TailBB))
574562 return false ;
575563
576- // Duplicating a BB which has both multiple predecessors and successors will
577- // result in a complex CFG and also may cause huge amount of PHI nodes. If we
578- // want to remove this limitation, we have to address
579- // https://github.com/llvm/llvm-project/issues/78578.
580- if (TailBB.pred_size () > TailDupPredSize &&
581- TailBB.succ_size () > TailDupSuccSize)
582- return false ;
583-
584564 // Set the limit on the cost to duplicate. When optimizing for size,
585565 // duplicate only one, because one branch instruction can be eliminated to
586566 // compensate for the duplication.
0 commit comments