@@ -425,15 +425,15 @@ namespace {
425425
426426class CopyPropagation : public SILFunctionTransform {
427427 // / If true, debug_value instructions should be pruned.
428- bool pruneDebug;
428+ PruneDebugInsts_t pruneDebug;
429429 // / If true, all values will be canonicalized.
430430 bool canonicalizeAll;
431431 // / If true, then borrow scopes will be canonicalized, allowing copies of
432432 // / guaranteed values to be optimized. Does *not* shrink the borrow scope.
433433 bool canonicalizeBorrows;
434434
435435public:
436- CopyPropagation (bool pruneDebug, bool canonicalizeAll,
436+ CopyPropagation (PruneDebugInsts_t pruneDebug, bool canonicalizeAll,
437437 bool canonicalizeBorrows)
438438 : pruneDebug(pruneDebug), canonicalizeAll(canonicalizeAll),
439439 canonicalizeBorrows (canonicalizeBorrows) {}
@@ -645,11 +645,11 @@ void CopyPropagation::run() {
645645// MandatoryCopyPropagation is not currently enabled in the -Onone pipeline
646646// because it may negatively affect the debugging experience.
647647SILTransform *swift::createMandatoryCopyPropagation () {
648- return new CopyPropagation (/* pruneDebug */ true , /* canonicalizeAll*/ true ,
648+ return new CopyPropagation (PruneDebugInsts , /* canonicalizeAll*/ true ,
649649 /* canonicalizeBorrows*/ false );
650650}
651651
652652SILTransform *swift::createCopyPropagation () {
653- return new CopyPropagation (/* pruneDebug */ true , /* canonicalizeAll*/ true ,
653+ return new CopyPropagation (PruneDebugInsts , /* canonicalizeAll*/ true ,
654654 /* canonicalizeBorrows*/ EnableRewriteBorrows);
655655}
0 commit comments