And update corresponding tests.
-; RUN: opt -S -memoryssa -loop-simplify -early-cse-memssa -earlycse-debug-hash -verify-memoryssa %s | FileCheck %s
+; RUN: opt -S -passes='require<memoryssa>,loop-simplify,early-cse<memssa>' -earlycse-debug-hash -verify-memoryssa %s | FileCheck %s
; REQUIRES: asserts
target triple = "x86_64-unknown-linux-gnu"
-; RUN: opt -early-cse-memssa -earlycse-debug-hash -loop-rotate -licm -loop-rotate -S %s -o - | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>,loop-mssa(loop-rotate,licm,loop-rotate)' -earlycse-debug-hash -S %s -o - | FileCheck %s
; ModuleID = 'bugpoint-reduced-simplified.bc'
source_filename = "bugpoint-output-8903f29.bc"
target datalayout = "e-m:e-i64:64-n32:64"
-; RUN: opt < %s -loop-simplify -loop-extract-single -disable-output
+; RUN: opt < %s -passes='function(loop-simplify),loop-extract<single>' -disable-output
define void @ab() {
entry:
-; RUN: opt < %s -S -mtriple=aarch64-none-linux-gnu -mattr=+neon -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -mtriple=aarch64-none-linux-gnu -mattr=+neon -basic-aa -early-cse-memssa | FileCheck %s
-; RUN: opt < %s -S -mtriple=aarch64-none-linux-gnu -mattr=+neon -passes=early-cse | FileCheck %s
+; RUN: opt < %s -S -mtriple=aarch64-none-linux-gnu -mattr=+neon -passes=early-cse -earlycse-debug-hash | FileCheck %s
; RUN: opt < %s -S -mtriple=aarch64-none-linux-gnu -mattr=+neon -aa-pipeline=basic-aa -passes='early-cse<memssa>' | FileCheck %s
define <4 x i32> @test_cse(ptr %a, [2 x <4 x i32>] %s.coerce, i32 %n) {
-; RUN: opt -S -early-cse -earlycse-debug-hash < %s | FileCheck %s
-; RUN: opt -S -basic-aa -early-cse-memssa < %s | FileCheck %s
+; RUN: opt -S -passes='early-cse' -earlycse-debug-hash < %s | FileCheck %s
+; RUN: opt -S -passes='early-cse<memssa>' < %s | FileCheck %s
target datalayout = "e-m:e-i64:64-i128:128-n32:64-S128"
target triple = "aarch64--linux-gnu"
-; RUN: opt -S -mtriple=amdgcn-amd-amdhsa -early-cse-memssa -earlycse-debug-hash < %s | FileCheck %s
+; RUN: opt -S -mtriple=amdgcn-amd-amdhsa -passes='early-cse<memssa>' -earlycse-debug-hash < %s | FileCheck %s
target datalayout = "e-p:64:64-p1:64:64-p2:32:32-p3:32:32-p4:64:64-p5:32:32-p6:32:32-i64:64-v16:16-v24:32-v32:32-v48:64-v96:128-v192:256-v256:256-v512:512-v1024:1024-v2048:2048-n32:64-S32-A5"
; CHECK-LABEL: @memrealtime(
-; RUN: opt -S -early-cse -earlycse-debug-hash < %s | FileCheck %s
-; RUN: opt -S -basic-aa -early-cse-memssa < %s | FileCheck %s
+; RUN: opt -S -passes=early-cse -earlycse-debug-hash < %s | FileCheck %s
+; RUN: opt -S -passes='early-cse<memssa>' < %s | FileCheck %s
target datalayout = "E-m:e-i64:64-n32:64"
target triple = "powerpc64-unknown-linux-gnu"
-; RUN: opt < %s -early-cse-memssa -earlycse-debug-hash -verify-memoryssa -disable-output
+; RUN: opt < %s -passes='early-cse<memssa>' -earlycse-debug-hash -verify-memoryssa -disable-output
; REQUIRES: asserts
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -early-cse -earlycse-debug-hash -S < %s | FileCheck %s
-; RUN: opt -basic-aa -early-cse-memssa -S < %s | FileCheck %s
+; RUN: opt -passes=early-cse -earlycse-debug-hash -S < %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -S < %s | FileCheck %s
define i32 @test_01(i32 %a, i32 %b) {
; CHECK-LABEL: @test_01(
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
define i32 @test12(i1 %B, ptr %P1, ptr %P2) {
; CHECK-LABEL: @test12(
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; RUN: opt < %s -S -passes=early-cse | FileCheck %s
declare void @llvm.assume(i1) nounwind
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
define void @test1(float %A, float %B, ptr %PA, ptr %PB) {
; CHECK-LABEL: @test1(
; RUN: opt -early-cse -earlycse-debug-hash -S < %s | FileCheck %s
-; RUN: opt -basic-aa -early-cse-memssa -S < %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -S < %s | FileCheck %s
; Can we CSE a known condition to a constant?
define i1 @test(ptr %p) {
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; Test use of constrained floating point intrinsics in the default
; floating point environment.
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; Test use of constrained floating point intrinsics with consistent
; floating point environments. All tests are with strict exception
; RUN: opt -early-cse -earlycse-debug-hash -S < %s | FileCheck %s
-; RUN: opt -basic-aa -early-cse-memssa -S < %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -S < %s | FileCheck %s
; Same as GVN/edge.ll, but updated to reflect EarlyCSE's less powerful
; implementation. EarlyCSE currently doesn't exploit equality comparisons
; against constants.
; RUN: opt -S -early-cse -earlycse-debug-hash < %s | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; NOTE: This file is testing the current implementation. Some of
; the transforms used as negative tests below would be legal, but
; only if reached through a chain of logic which EarlyCSE is incapable
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -early-cse -earlycse-debug-hash -S < %s | FileCheck %s
-; RUN: opt -basic-aa -early-cse-memssa -S < %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -S < %s | FileCheck %s
declare void @use(i1)
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; Ensure we don't simplify away additions vectors of +0.0's (same as scalars).
define <4 x float> @fV( <4 x float> %a) {
-; RUN: opt -basic-aa -aa -memoryssa -early-cse-memssa -verify -S < %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -S < %s | FileCheck %s
; Check that this doesn't crash. The crash only happens with expensive checks,
; but there doesn't seem to be a REQUIRES for that.
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt < %s -S -globals-aa -early-cse-memssa -earlycse-debug-hash | FileCheck %s
+; RUN: opt < %s -S -passes='require<globals-aa>,early-cse<memssa>' -earlycse-debug-hash | FileCheck %s
define i16 @f1() readonly {
ret i16 0
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -S -early-cse -earlycse-debug-hash < %s | FileCheck %s --check-prefixes=CHECK,NO_ASSUME
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s --check-prefixes=CHECK,NO_ASSUME
-; RUN: opt < %s -S -basic-aa -early-cse-memssa --enable-knowledge-retention | FileCheck %s --check-prefixes=CHECK,USE_ASSUME
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s --check-prefixes=CHECK,NO_ASSUME
+; RUN: opt < %s -S -passes='early-cse<memssa>' --enable-knowledge-retention | FileCheck %s --check-prefixes=CHECK,USE_ASSUME
declare void @llvm.experimental.guard(i1,...)
; RUN: opt -early-cse -earlycse-debug-hash -S < %s | FileCheck %s
-; RUN: opt -basic-aa -early-cse-memssa -S < %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -S < %s | FileCheck %s
; PR12231
declare i32 @f()
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -S -early-cse -earlycse-debug-hash < %s | FileCheck %s --check-prefixes=CHECK,NO_ASSUME
-; RUN: opt -S -basic-aa -early-cse-memssa < %s | FileCheck %s --check-prefixes=CHECK,NO_ASSUME
-; RUN: opt -S -basic-aa -early-cse-memssa --enable-knowledge-retention < %s | FileCheck %s --check-prefixes=CHECK,USE_ASSUME
+; RUN: opt -S -passes='early-cse<memssa>' < %s | FileCheck %s --check-prefixes=CHECK,NO_ASSUME
+; RUN: opt -S -passes='early-cse<memssa>' --enable-knowledge-retention < %s | FileCheck %s --check-prefixes=CHECK,USE_ASSUME
declare void @clobber_and_use(i32)
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s --check-prefix=CHECK-NOMEMSSA
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; RUN: opt < %s -S -passes='early-cse' | FileCheck %s --check-prefix=CHECK-NOMEMSSA
; RUN: opt < %s -S -aa-pipeline=basic-aa -passes='early-cse<memssa>' | FileCheck %s
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; Test use of constrained floating point intrinsics mixing the default
; floating point environment with alternate modes. None of the tests
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; Test use of constrained floating point intrinsics with consistent
; floating point environments. The default floating point environment
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -early-cse -earlycse-debug-hash -S < %s | FileCheck %s
-; RUN: opt -basic-aa -early-cse-memssa -S < %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -S < %s | FileCheck %s
; Most basic case, fully identical PHI nodes
define void @test0(i32 %v0, i32 %v1, i1 %c, ptr %d0, ptr %d1) {
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -early-cse-memssa -earlycse-debug-hash -S %s | FileCheck %s
+; RUN: opt -passes='early-cse<memssa>' -earlycse-debug-hash -S %s | FileCheck %s
@b = external global i32
-; RUN: opt -memoryssa -gvn -early-cse-memssa %s -S | FileCheck %s
+; RUN: opt -passes='require<memoryssa>,gvn,early-cse<memssa>' %s -S | FileCheck %s
; CHECK: define void @foo(
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
; Test use of constrained floating point intrinsics with dynamic
; rounding mode. Dynamic rounding _must_ disable CSE since EarlyCSE
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -early-cse -earlycse-debug-hash | FileCheck %s
-; RUN: opt < %s -S -basic-aa -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
define i64 @branching_int(i32 %a) {
; CHECK-LABEL: @branching_int(
-; RUN: opt < %s -early-cse-memssa -earlycse-debug-hash -gvn-hoist -S | FileCheck %s
+; RUN: opt < %s -passes='early-cse<memssa>,gvn-hoist' -earlycse-debug-hash -S | FileCheck %s
; Make sure opt won't crash and that this pair of
; instructions (load, icmp) are not hoisted.
-; RUN: opt < %s -early-cse-memssa -earlycse-debug-hash -gvn-hoist -S | FileCheck %s
+; RUN: opt < %s -passes='early-cse<memssa>,gvn-hoist' -earlycse-debug-hash -S | FileCheck %s
; Make sure opt doesn't crash. On top of that, the instructions
; of the side blocks should be hoisted to the entry block.
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -lower-matrix-intrinsics-minimal -fuse-matrix-tile-size=2 -matrix-allow-contract -force-fuse-matrix -instcombine -verify-dom-info %s -S | FileCheck %s
; RUN: opt -passes='lower-matrix-intrinsics<minimal>,instcombine,verify<domtree>' -fuse-matrix-tile-size=2 -matrix-allow-contract -force-fuse-matrix %s -S | FileCheck %s
; Test for the minimal version of the matrix lowering pass, which does not
-; RUN: opt < %s -S -early-cse-memssa | FileCheck %s
+; RUN: opt < %s -S -passes='early-cse<memssa>' | FileCheck %s
define i16 @f1() readonly {
ret i16 0
std::string ModifiedPassName(PassName.begin(), PassName.end());
if (PB.isAnalysisPassName(PassName))
ModifiedPassName = "require<" + ModifiedPassName + ">";
- // FIXME: These translations are supposed to be removed when lit tests that
- // use these names have been updated to use the -passes syntax (and when the
- // support for using the old syntax to specify passes is considered as
- // deprecated for the new PM).
- if (ModifiedPassName == "early-cse-memssa")
- ModifiedPassName = "early-cse<memssa>";
- else if (ModifiedPassName == "post-inline-ee-instrument")
- ModifiedPassName = "ee-instrument<post-inline>";
- else if (ModifiedPassName == "loop-extract-single")
- ModifiedPassName = "loop-extract<single>";
- else if (ModifiedPassName == "lower-matrix-intrinsics-minimal")
- ModifiedPassName = "lower-matrix-intrinsics<minimal>";
if (auto Err = PB.parsePassPipeline(MPM, ModifiedPassName)) {
errs() << Arg0 << ": " << toString(std::move(Err)) << "\n";
return false;