File tree Expand file tree Collapse file tree 2 files changed +13
-6
lines changed Expand file tree Collapse file tree 2 files changed +13
-6
lines changed Original file line number Diff line number Diff line change 1
1
// RUN: %target-sil-opt -diagnostics -enable-sil-opaque-values %s | \
2
- // RUN: %target-sil-opt -Onone-performance -enable-sil-opaque-values -emit-sorted-sil -sil-disable-pass=mandatory-copy-propagation | \
2
+ // RUN: %target-sil-opt -Onone-performance -enable-sil-verify-all \
3
+ // RUN: -enable-sil-opaque-values -emit-sorted-sil \
4
+ // RUN: -enable-ossa-modules -enable-copy-propagation | \
3
5
// RUN: %FileCheck %s
4
6
5
- // Using -sil-disable-pass=mandatory-copy-propagation to pattern match
6
- // against older SIL output. At least until -enable-copy-propagation
7
- // has been around long enough in the same form to be worth rewriting
8
- // CHECK lines.
9
-
10
7
import Builtin
11
8
12
9
sil_stage raw
Original file line number Diff line number Diff line change @@ -122,6 +122,14 @@ static llvm::cl::opt<bool> EnableOSSAModules(
122
122
" this is disabled we do not serialize in OSSA "
123
123
" form when optimizing." ));
124
124
125
+ static llvm::cl::opt<bool > EnableCopyPropagation (
126
+ " enable-copy-propagation" ,
127
+ llvm::cl::desc (" Enable the copy propagation pass." ));
128
+
129
+ static llvm::cl::opt<bool > DisableCopyPropagation (
130
+ " disable-copy-propagation" ,
131
+ llvm::cl::desc (" Disable the copy propagation pass." ));
132
+
125
133
namespace {
126
134
enum class EnforceExclusivityMode {
127
135
Unchecked, // static only
@@ -470,6 +478,8 @@ int main(int argc, char **argv) {
470
478
SILOpts.EnableSpeculativeDevirtualization = EnableSpeculativeDevirtualization;
471
479
SILOpts.IgnoreAlwaysInline = IgnoreAlwaysInline;
472
480
SILOpts.EnableOSSAModules = EnableOSSAModules;
481
+ SILOpts.EnableCopyPropagation = EnableCopyPropagation;
482
+ SILOpts.DisableCopyPropagation = DisableCopyPropagation;
473
483
474
484
serialization::ExtendedValidationInfo extendedInfo;
475
485
llvm::ErrorOr<std::unique_ptr<llvm::MemoryBuffer>> FileBufOrErr =
You can’t perform that action at this time.
0 commit comments