diff options
author | Alina Sbirlea <asbirlea@google.com> | 2018-12-04 14:23:37 +0000 |
---|---|---|
committer | Alina Sbirlea <asbirlea@google.com> | 2018-12-04 14:23:37 +0000 |
commit | a2eebb828e02be7ca8e0c1c53e1ad6548aa1049f (patch) | |
tree | bacd9a5df5f282f58718e0142b44f3a6a1463962 /llvm/test/Transforms | |
parent | 2d12d810f487bf251289546a587cc525e23ca62c (diff) | |
download | bcm5719-llvm-a2eebb828e02be7ca8e0c1c53e1ad6548aa1049f.tar.gz bcm5719-llvm-a2eebb828e02be7ca8e0c1c53e1ad6548aa1049f.zip |
Update MemorySSA in SimpleLoopUnswitch.
Summary:
Teach SimpleLoopUnswitch to preserve MemorySSA.
Subscribers: sanjoy, jlebar, Prazek, george.burgess.iv, llvm-commits
Differential Revision: https://reviews.llvm.org/D47022
llvm-svn: 348263
Diffstat (limited to 'llvm/test/Transforms')
31 files changed, 31 insertions, 0 deletions
diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-13-SingleEntryPHI.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-13-SingleEntryPHI.ll index 3b22687ca91..0a769ec5da6 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-13-SingleEntryPHI.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-13-SingleEntryPHI.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output %struct.BLEND_MAP = type { i16, i16, i16, i32, %struct.BLEND_MAP_ENTRY* } %struct.BLEND_MAP_ENTRY = type { float, i8, { [5 x float], [4 x i8] } } diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-27-DeadSwitchCase.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-27-DeadSwitchCase.ll index 61825b6c1d8..85066168e1e 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-27-DeadSwitchCase.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2006-06-27-DeadSwitchCase.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output define void @init_caller_save() { entry: diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-Unreachable.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-Unreachable.ll index 4bbcc80ff3b..02c7a96deb5 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-Unreachable.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-Unreachable.ll @@ -1,5 +1,6 @@ ; PR1333 ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64" target triple = "i686-pc-linux-gnu" diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-tl.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-tl.ll index 835715264e1..a0408c8ea6a 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-tl.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2007-05-09-tl.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output ; PR1333 define void @pp_cxx_expression() { diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-12-ExitDomInfo.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-12-ExitDomInfo.ll index 2a73a429c6a..571e3eb6696 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-12-ExitDomInfo.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-12-ExitDomInfo.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -instcombine -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -instcombine -disable-output @str3 = external constant [3 x i8] ; <[3 x i8]*> [#uses=1] diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-13-DomInfo.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-13-DomInfo.ll index 7299b2b1908..626ac848cfb 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-13-DomInfo.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-13-DomInfo.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output define i32 @main(i32 %argc, i8** %argv) { entry: diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-18-DomInfo.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-18-DomInfo.ll index e1ef5064a8f..52d96893060 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-18-DomInfo.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2007-07-18-DomInfo.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output ; PR1559 target triple = "i686-pc-linux-gnu" diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2007-08-01-LCSSA.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2007-08-01-LCSSA.ll index cb65d2fb644..7c65459a65c 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2007-08-01-LCSSA.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2007-08-01-LCSSA.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -instcombine -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -instcombine -disable-output %struct.ClassDef = type { %struct.QByteArray, %struct.QByteArray, %"struct.QList<ArgumentDef>", %"struct.QList<ArgumentDef>", i8, i8, %"struct.QList<ArgumentDef>", %"struct.QList<ArgumentDef>", %"struct.QList<ArgumentDef>", %"struct.QList<ArgumentDef>", %"struct.QList<ArgumentDef>", %"struct.QList<ArgumentDef>", %"struct.QMap<QByteArray,QByteArray>", %"struct.QList<ArgumentDef>", %"struct.QMap<QByteArray,QByteArray>", i32, i32 } %struct.FILE = type { i32, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, %struct._IO_marker*, %struct.FILE*, i32, i32, i32, i16, i8, [1 x i8], i8*, i64, i8*, i8*, i8*, i8*, i32, i32, [40 x i8] } %struct.Generator = type { %struct.FILE*, %struct.ClassDef*, %"struct.QList<ArgumentDef>", %struct.QByteArray, %"struct.QList<ArgumentDef>" } diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2008-06-02-DomInfo.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2008-06-02-DomInfo.ll index 5b3ca9c187d..5db1ced473f 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2008-06-02-DomInfo.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2008-06-02-DomInfo.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -instcombine -gvn -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -instcombine -gvn -disable-output ; PR2372 target triple = "i386-pc-linux-gnu" diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2010-11-18-LCSSA.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2010-11-18-LCSSA.ll index 9f71417df8e..f3a382d813b 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2010-11-18-LCSSA.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2010-11-18-LCSSA.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa ; PR8622 @g_38 = external global i32, align 4 diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2011-06-02-CritSwitch.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2011-06-02-CritSwitch.ll index 8c13e1854c9..b861d3029d5 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2011-06-02-CritSwitch.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2011-06-02-CritSwitch.ll @@ -1,4 +1,5 @@ ; RUN: opt -simple-loop-unswitch -disable-output < %s +; RUN: opt -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output < %s ; PR10031 define i32 @test(i32 %command) { diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2011-09-26-EHCrash.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2011-09-26-EHCrash.ll index 6b7d9faf70f..16886bfec03 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2011-09-26-EHCrash.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2011-09-26-EHCrash.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -sroa -simple-loop-unswitch -disable-output +; RUN: opt < %s -sroa -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output ; PR11016 target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" target triple = "x86_64-apple-macosx10.7.2" diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2012-04-02-IndirectBr.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2012-04-02-IndirectBr.ll index 133f41744a9..72af9840818 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2012-04-02-IndirectBr.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2012-04-02-IndirectBr.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -S -simple-loop-unswitch -verify-loop-info -verify-dom-info | FileCheck %s +; RUN: opt < %s -S -simple-loop-unswitch -verify-loop-info -verify-dom-info -enable-mssa-loop-dependency=true -verify-memoryssa | FileCheck %s ; PR12343: -simple-loop-unswitch crash on indirect branch ; CHECK: %0 = icmp eq i64 undef, 0 diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2012-05-20-Phi.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2012-05-20-Phi.ll index e5549fe92f9..e9f35709ba7 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2012-05-20-Phi.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2012-05-20-Phi.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output ; PR12887 target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128" target triple = "x86_64-unknown-linux-gnu" diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/2015-09-18-Addrspace.ll b/llvm/test/Transforms/SimpleLoopUnswitch/2015-09-18-Addrspace.ll index ddb888af8ba..c8de642a5d0 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/2015-09-18-Addrspace.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/2015-09-18-Addrspace.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -S | FileCheck %s +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -S | FileCheck %s ; In cases where two address spaces do not have the same size pointer, the ; input for the addrspacecast should not be used as a substitute for itself diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/LIV-loop-condtion.ll b/llvm/test/Transforms/SimpleLoopUnswitch/LIV-loop-condtion.ll index 03c23da6c96..59c14e937b6 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/LIV-loop-condtion.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/LIV-loop-condtion.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -S 2>&1 | FileCheck %s +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -S 2>&1 | FileCheck %s ; This is to test trivial loop unswitch only happens when trivial condition ; itself is an LIV loop condition (not partial LIV which could occur in and/or). diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/basictest.ll b/llvm/test/Transforms/SimpleLoopUnswitch/basictest.ll index afca20fe251..240f433a8db 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/basictest.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/basictest.ll @@ -1,4 +1,5 @@ ; RUN: opt -passes='loop(unswitch),verify<loops>' -S < %s | FileCheck %s +; RUN: opt -enable-mssa-loop-dependency=true -verify-memoryssa -passes='loop(unswitch),verify<loops>' -S < %s | FileCheck %s define i32 @test(i32* %A, i1 %C) { entry: diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/cleanuppad.ll b/llvm/test/Transforms/SimpleLoopUnswitch/cleanuppad.ll index 8ab23cb1f61..1cade22b659 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/cleanuppad.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/cleanuppad.ll @@ -1,4 +1,5 @@ ; RUN: opt -S -simple-loop-unswitch < %s | FileCheck %s +; RUN: opt -S -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa < %s | FileCheck %s target triple = "x86_64-pc-win32" define void @f(i32 %doit, i1 %x, i1 %y) personality i32 (...)* @__CxxFrameHandler3 { diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/copy-metadata.ll b/llvm/test/Transforms/SimpleLoopUnswitch/copy-metadata.ll index 7085ed8e10f..09d7d792c7c 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/copy-metadata.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/copy-metadata.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -S | FileCheck %s +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -S | FileCheck %s ; This test checks if unswitched condition preserve make.implicit metadata. define i32 @test(i1 %cond) { diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/crash.ll b/llvm/test/Transforms/SimpleLoopUnswitch/crash.ll index a6c64113c08..cf6a19d2540 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/crash.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/crash.ll @@ -1,4 +1,5 @@ ; RUN: opt < %s -simple-loop-unswitch -disable-output +; RUN: opt < %s -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output define void @test1(i32* %S2) { entry: diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/exponential-behavior.ll b/llvm/test/Transforms/SimpleLoopUnswitch/exponential-behavior.ll index 52e9aa1acc2..1c46ddbf51a 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/exponential-behavior.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/exponential-behavior.ll @@ -1,4 +1,5 @@ ; RUN: opt -simple-loop-unswitch -S < %s | FileCheck %s +; RUN: opt -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -S < %s | FileCheck %s define void @f(i32 %n, i32* %ptr) { ; CHECK-LABEL: @f( diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/guards.ll b/llvm/test/Transforms/SimpleLoopUnswitch/guards.ll index 95661c425e1..f1b92524332 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/guards.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/guards.ll @@ -1,5 +1,6 @@ ; RUN: opt -passes='loop(unswitch),verify<loops>' -enable-nontrivial-unswitch -simple-loop-unswitch-guards -S < %s | FileCheck %s ; RUN: opt -simple-loop-unswitch -enable-nontrivial-unswitch -simple-loop-unswitch-guards -S < %s | FileCheck %s +; RUN: opt -passes='loop(unswitch),verify<loops>' -enable-nontrivial-unswitch -simple-loop-unswitch-guards -enable-mssa-loop-dependency=true -verify-memoryssa -S < %s | FileCheck %s declare void @llvm.experimental.guard(i1, ...) diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/infinite-loop.ll b/llvm/test/Transforms/SimpleLoopUnswitch/infinite-loop.ll index 9164fd24783..91e1f486b82 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/infinite-loop.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/infinite-loop.ll @@ -1,6 +1,7 @@ ; REQUIRES: asserts ; RUN: opt -simple-loop-unswitch -disable-output -stats -info-output-file - < %s | FileCheck --check-prefix=STATS %s ; RUN: opt -simple-loop-unswitch -S < %s | FileCheck %s +; RUN: opt -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -S < %s | FileCheck %s ; PR5373 ; Loop unswitching shouldn't trivially unswitch the true case of condition %a diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/msan.ll b/llvm/test/Transforms/SimpleLoopUnswitch/msan.ll index ec1110ac9d6..8a296bcd279 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/msan.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/msan.ll @@ -1,4 +1,5 @@ ; RUN: opt -passes='loop(unswitch),verify<loops>' -S < %s | FileCheck %s +; RUN: opt -enable-mssa-loop-dependency=true -verify-memoryssa -passes='loop(unswitch),verify<loops>' -S < %s | FileCheck %s declare void @unknown() declare void @unknown2() diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch-cost.ll b/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch-cost.ll index 2d98f148d46..333378a0984 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch-cost.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch-cost.ll @@ -2,6 +2,7 @@ ; ; RUN: opt -passes='loop(unswitch),verify<loops>' -enable-nontrivial-unswitch -unswitch-threshold=5 -S < %s | FileCheck %s ; RUN: opt -simple-loop-unswitch -enable-nontrivial-unswitch -unswitch-threshold=5 -S < %s | FileCheck %s +; RUN: opt -simple-loop-unswitch -enable-nontrivial-unswitch -unswitch-threshold=5 -enable-mssa-loop-dependency=true -verify-memoryssa -S < %s | FileCheck %s declare void @a() declare void @b() diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch.ll b/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch.ll index 367d6fe28e9..f07c812819f 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/nontrivial-unswitch.ll @@ -1,5 +1,6 @@ ; RUN: opt -passes='loop(unswitch),verify<loops>' -enable-nontrivial-unswitch -S < %s | FileCheck %s ; RUN: opt -simple-loop-unswitch -enable-nontrivial-unswitch -S < %s | FileCheck %s +; RUN: opt -simple-loop-unswitch -enable-nontrivial-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -S < %s | FileCheck %s declare i32 @a() declare i32 @b() diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/pr37888.ll b/llvm/test/Transforms/SimpleLoopUnswitch/pr37888.ll index 307706fc34a..e8e34a2e882 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/pr37888.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/pr37888.ll @@ -1,4 +1,5 @@ ; RUN: opt -simple-loop-unswitch -loop-deletion -S < %s | FileCheck %s +; RUN: opt -simple-loop-unswitch -enable-mssa-loop-dependency=true -verify-memoryssa -loop-deletion -S < %s | FileCheck %s ; ; Check that when we do unswitching where we re-enqueue the loop to be processed ; again, but manage to delete the loop before ever getting to iterate on it, it diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/preserve-analyses.ll b/llvm/test/Transforms/SimpleLoopUnswitch/preserve-analyses.ll index 76b41e73ede..114825348da 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/preserve-analyses.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/preserve-analyses.ll @@ -1,4 +1,5 @@ ; RUN: opt -simple-loop-unswitch -verify-loop-info -verify-dom-info -disable-output < %s +; RUN: opt -simple-loop-unswitch -verify-loop-info -verify-dom-info -enable-mssa-loop-dependency=true -verify-memoryssa -disable-output < %s ; Loop unswitch should be able to unswitch these loops and ; preserve LCSSA and LoopSimplify forms. diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch-iteration.ll b/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch-iteration.ll index 6c409e40b28..18b39ca8082 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch-iteration.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch-iteration.ll @@ -1,4 +1,5 @@ ; RUN: opt -passes='loop(loop-instsimplify,simplify-cfg,unswitch),verify<loops>' -S < %s | FileCheck %s +; RUN: opt -enable-mssa-loop-dependency=true -verify-memoryssa -passes='loop(loop-instsimplify,simplify-cfg,unswitch),verify<loops>' -S < %s | FileCheck %s declare void @some_func() noreturn diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch.ll b/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch.ll index 6a025a4136b..56a9bac8980 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch.ll @@ -1,4 +1,5 @@ ; RUN: opt -passes='loop(unswitch),verify<loops>' -S < %s | FileCheck %s +; RUN: opt -enable-mssa-loop-dependency=true -verify-memoryssa -passes='loop(unswitch),verify<loops>' -S < %s | FileCheck %s declare void @some_func() noreturn declare void @sink(i32) diff --git a/llvm/test/Transforms/SimpleLoopUnswitch/update-scev.ll b/llvm/test/Transforms/SimpleLoopUnswitch/update-scev.ll index 96bdc6a91b8..1f4c1421b4e 100644 --- a/llvm/test/Transforms/SimpleLoopUnswitch/update-scev.ll +++ b/llvm/test/Transforms/SimpleLoopUnswitch/update-scev.ll @@ -1,4 +1,5 @@ ; RUN: opt -passes='print<scalar-evolution>,loop(unswitch,loop-instsimplify),print<scalar-evolution>' -enable-nontrivial-unswitch -S < %s 2>%t.scev | FileCheck %s +; RUN: opt -enable-mssa-loop-dependency=true -verify-memoryssa -passes='print<scalar-evolution>,loop(unswitch,loop-instsimplify),print<scalar-evolution>' -enable-nontrivial-unswitch -S < %s 2>%t.scev | FileCheck %s ; RUN: FileCheck %s --check-prefix=SCEV < %t.scev target triple = "x86_64-unknown-linux-gnu" |