Skip to content

Commit b2a5fd6

Browse files
committed
COWArrayOpts: remove the -view-cfg-before-cow-for option for debugging
This option is very old. The same effect can now be achieved with pass-manager options, like -sil-print-before
1 parent 4f113f6 commit b2a5fd6

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

lib/SILOptimizer/LoopTransforms/COWArrayOpt.cpp

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,6 @@
3838
#include "llvm/Support/Debug.h"
3939
using namespace swift;
4040

41-
#ifndef NDEBUG
42-
llvm::cl::opt<std::string>
43-
COWViewCFGFunction("view-cfg-before-cow-for", llvm::cl::init(""),
44-
llvm::cl::desc("Only print out the sil for this function"));
45-
#endif
46-
4741
/// \return a sequence of integers representing the access path of this element
4842
/// within a Struct/Ref/Tuple.
4943
///
@@ -1585,13 +1579,6 @@ class COWArrayOptPass : public SILFunctionTransform {
15851579
return;
15861580
}
15871581

1588-
#ifndef NDEBUG
1589-
if (!COWViewCFGFunction.empty() && getFunction()->getName() == COWViewCFGFunction) {
1590-
getFunction()->dump();
1591-
getFunction()->viewCFG();
1592-
}
1593-
#endif
1594-
15951582
// Create a flat list of loops in loop-tree postorder (bottom-up).
15961583
llvm::SmallVector<SILLoop *, 16> Loops;
15971584
std::function<void (SILLoop*)> pushChildren = [&](SILLoop *L) {

0 commit comments

Comments
 (0)