[llvm] 20cbb6c - [LoopPred] Selectively disable to preserve test cases

Philip Reames via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 6 15:42:03 PST 2019


Author: Philip Reames
Date: 2019-11-06T15:41:57-08:00
New Revision: 20cbb6cdf8b33dd3732b9ef8702e7946b6d8c739

URL: https://github.com/llvm/llvm-project/commit/20cbb6cdf8b33dd3732b9ef8702e7946b6d8c739
DIFF: https://github.com/llvm/llvm-project/commit/20cbb6cdf8b33dd3732b9ef8702e7946b6d8c739.diff

LOG: [LoopPred] Selectively disable to preserve test cases

I'm about to enable the new loop predication transform by default.  It has the effect of completely destroying many read only loops - which happen to be a super common idiom in our test cases.  So as to preserve test coverage of other transforms, disable the new transform where it would cause sharp test coverage regressions.

(This is semantically part of the enabling commit.  It's committed separate to ease revert if the actual flag flip gets reverted.)

Added: 
    

Modified: 
    llvm/test/Transforms/IndVarSimplify/eliminate-trunc.ll
    llvm/test/Transforms/IndVarSimplify/lftr-dead-ivs.ll
    llvm/test/Transforms/IndVarSimplify/lftr-pr20680.ll
    llvm/test/Transforms/IndVarSimplify/lftr-reuse.ll
    llvm/test/Transforms/IndVarSimplify/lftr.ll
    llvm/test/Transforms/IndVarSimplify/loop-invariant-conditions.ll
    llvm/test/Transforms/IndVarSimplify/no-iv-rewrite.ll
    llvm/test/Transforms/IndVarSimplify/pr24356.ll
    llvm/test/Transforms/IndVarSimplify/pr38674.ll
    llvm/test/Transforms/IndVarSimplify/pr39673.ll
    llvm/test/Transforms/IndVarSimplify/replace-loop-exit-folds.ll
    llvm/test/Transforms/IndVarSimplify/sink-from-preheader.ll

Removed: 
    


################################################################################
diff  --git a/llvm/test/Transforms/IndVarSimplify/eliminate-trunc.ll b/llvm/test/Transforms/IndVarSimplify/eliminate-trunc.ll
index 74e422b797bf..8258445d4f32 100644
--- a/llvm/test/Transforms/IndVarSimplify/eliminate-trunc.ll
+++ b/llvm/test/Transforms/IndVarSimplify/eliminate-trunc.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -indvars -S < %s | FileCheck %s
+; RUN: opt -indvars -S -indvars-predicate-loops=0 < %s | FileCheck %s
 
 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
 target triple = "x86_64-unknown-linux-gnu"

diff  --git a/llvm/test/Transforms/IndVarSimplify/lftr-dead-ivs.ll b/llvm/test/Transforms/IndVarSimplify/lftr-dead-ivs.ll
index 5ef6b4a6e786..0ec469fea54e 100644
--- a/llvm/test/Transforms/IndVarSimplify/lftr-dead-ivs.ll
+++ b/llvm/test/Transforms/IndVarSimplify/lftr-dead-ivs.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -indvars < %s | FileCheck %s
+; RUN: opt -S -indvars -indvars-predicate-loops=0 < %s | FileCheck %s
 
 ; Tests in this file are specifically about correctly handling possibly poison
 ; producing flags when converting from one IV to another.  In particular, there

diff  --git a/llvm/test/Transforms/IndVarSimplify/lftr-pr20680.ll b/llvm/test/Transforms/IndVarSimplify/lftr-pr20680.ll
index 6f67662f2989..1bb13832c574 100644
--- a/llvm/test/Transforms/IndVarSimplify/lftr-pr20680.ll
+++ b/llvm/test/Transforms/IndVarSimplify/lftr-pr20680.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt < %s -indvars -S | FileCheck %s
+; RUN: opt < %s -indvars -S -indvars-predicate-loops=0 | FileCheck %s
 
 ; Provide legal integer types.
 target datalayout = "n8:16:32:64"

diff  --git a/llvm/test/Transforms/IndVarSimplify/lftr-reuse.ll b/llvm/test/Transforms/IndVarSimplify/lftr-reuse.ll
index 14ae9738696c..2053d70fbc1d 100644
--- a/llvm/test/Transforms/IndVarSimplify/lftr-reuse.ll
+++ b/llvm/test/Transforms/IndVarSimplify/lftr-reuse.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt < %s -indvars -S | FileCheck %s
+; RUN: opt < %s -indvars -S -indvars-predicate-loops=0 | FileCheck %s
 
 ; Make sure that indvars can perform LFTR without a canonical IV.
 

diff  --git a/llvm/test/Transforms/IndVarSimplify/lftr.ll b/llvm/test/Transforms/IndVarSimplify/lftr.ll
index b72778b2e762..098f98d53813 100644
--- a/llvm/test/Transforms/IndVarSimplify/lftr.ll
+++ b/llvm/test/Transforms/IndVarSimplify/lftr.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt < %s -indvars -dce -S | FileCheck %s
+; RUN: opt < %s -indvars -dce -S -indvars-predicate-loops=0 | FileCheck %s
 
 ; Provide legal integer types.
 target datalayout = "n8:16:32:64"

diff  --git a/llvm/test/Transforms/IndVarSimplify/loop-invariant-conditions.ll b/llvm/test/Transforms/IndVarSimplify/loop-invariant-conditions.ll
index 320f0b30cb98..f5b80d3688db 100644
--- a/llvm/test/Transforms/IndVarSimplify/loop-invariant-conditions.ll
+++ b/llvm/test/Transforms/IndVarSimplify/loop-invariant-conditions.ll
@@ -1,4 +1,4 @@
-; RUN: opt -S -indvars %s | FileCheck %s
+; RUN: opt -S -indvars -indvars-predicate-loops=0 %s | FileCheck %s
 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
 target triple = "x86_64-unknown-linux-gnu"
 

diff  --git a/llvm/test/Transforms/IndVarSimplify/no-iv-rewrite.ll b/llvm/test/Transforms/IndVarSimplify/no-iv-rewrite.ll
index 7411b16bb85b..53c08ec5d57f 100644
--- a/llvm/test/Transforms/IndVarSimplify/no-iv-rewrite.ll
+++ b/llvm/test/Transforms/IndVarSimplify/no-iv-rewrite.ll
@@ -1,4 +1,4 @@
-; RUN: opt < %s -indvars -S | FileCheck %s
+; RUN: opt < %s -indvars -S -indvars-predicate-loops=0  | FileCheck %s
 ;
 ; Make sure that indvars isn't inserting canonical IVs.
 ; This is kinda hard to do until linear function test replacement is removed.

diff  --git a/llvm/test/Transforms/IndVarSimplify/pr24356.ll b/llvm/test/Transforms/IndVarSimplify/pr24356.ll
index eac4204c0e16..2718a6c247fb 100644
--- a/llvm/test/Transforms/IndVarSimplify/pr24356.ll
+++ b/llvm/test/Transforms/IndVarSimplify/pr24356.ll
@@ -1,4 +1,4 @@
-; RUN: opt -S -indvars < %s | FileCheck %s
+; RUN: opt -S -indvars -indvars-predicate-loops=0  < %s | FileCheck %s
 
 target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128"
 target triple = "x86_64-apple-macosx10.10.0"

diff  --git a/llvm/test/Transforms/IndVarSimplify/pr38674.ll b/llvm/test/Transforms/IndVarSimplify/pr38674.ll
index 390a68d7cbbe..bd4a23dc3b9a 100644
--- a/llvm/test/Transforms/IndVarSimplify/pr38674.ll
+++ b/llvm/test/Transforms/IndVarSimplify/pr38674.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -indvars < %s | FileCheck %s
+; RUN: opt -S -indvars -indvars-predicate-loops=0  < %s | FileCheck %s
 
 ; Check that we don't reuse %zext instead of %inc11 for LCSSA Phi node. Case
 ; with constants SCEV.

diff  --git a/llvm/test/Transforms/IndVarSimplify/pr39673.ll b/llvm/test/Transforms/IndVarSimplify/pr39673.ll
index 4c1bfea0b2b8..7fb90a90071a 100644
--- a/llvm/test/Transforms/IndVarSimplify/pr39673.ll
+++ b/llvm/test/Transforms/IndVarSimplify/pr39673.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -S -indvars < %s | FileCheck %s
+; RUN: opt -S -indvars -indvars-predicate-loops=0  < %s | FileCheck %s
 
 define i16 @constant() {
 ; CHECK-LABEL: @constant(

diff  --git a/llvm/test/Transforms/IndVarSimplify/replace-loop-exit-folds.ll b/llvm/test/Transforms/IndVarSimplify/replace-loop-exit-folds.ll
index 77bc2b6ee5d9..9cc911cc5a0d 100644
--- a/llvm/test/Transforms/IndVarSimplify/replace-loop-exit-folds.ll
+++ b/llvm/test/Transforms/IndVarSimplify/replace-loop-exit-folds.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt -indvars -S < %s | FileCheck %s
+; RUN: opt -indvars -S -indvars-predicate-loops=0 < %s | FileCheck %s
 
 target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
 

diff  --git a/llvm/test/Transforms/IndVarSimplify/sink-from-preheader.ll b/llvm/test/Transforms/IndVarSimplify/sink-from-preheader.ll
index 29e8b638281a..00067fc979e9 100644
--- a/llvm/test/Transforms/IndVarSimplify/sink-from-preheader.ll
+++ b/llvm/test/Transforms/IndVarSimplify/sink-from-preheader.ll
@@ -1,5 +1,5 @@
 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
-; RUN: opt < %s -indvars -S | FileCheck %s
+; RUN: opt < %s -indvars -indvars-predicate-loops=0 -S | FileCheck %s
 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-f80:128:128"
 target triple = "i386-apple-darwin10.0"
 


        


More information about the llvm-commits mailing list