Skip to content

Commit

Permalink
[opt] Don't translate legacy -analysis flag to require<analysis>
Browse files Browse the repository at this point in the history
Tests relying on this should explicitly use -passes='require<analysis>,foo'.
  • Loading branch information
aeubanks committed Oct 7, 2022
1 parent 978f11c commit f3a928e
Show file tree
Hide file tree
Showing 498 changed files with 872 additions and 926 deletions.
6 changes: 0 additions & 6 deletions llvm/include/llvm/Passes/PassBuilder.h
Original file line number Diff line number Diff line change
Expand Up @@ -374,12 +374,6 @@ class PassBuilder {
/// returns false.
Error parseAAPipeline(AAManager &AA, StringRef PipelineText);

/// Returns true if the pass name is the name of an alias analysis pass.
bool isAAPassName(StringRef PassName);

/// Returns true if the pass name is the name of a (non-alias) analysis pass.
bool isAnalysisPassName(StringRef PassName);

/// Print pass names.
void printPassNames(raw_ostream &OS);

Expand Down
34 changes: 0 additions & 34 deletions llvm/lib/Passes/PassBuilder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1761,40 +1761,6 @@ Error PassBuilder::parseAAPipeline(AAManager &AA, StringRef PipelineText) {
return Error::success();
}

bool PassBuilder::isAAPassName(StringRef PassName) {
#define MODULE_ALIAS_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#define FUNCTION_ALIAS_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#include "PassRegistry.def"
return false;
}

bool PassBuilder::isAnalysisPassName(StringRef PassName) {
#define MODULE_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#define FUNCTION_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#define LOOP_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#define CGSCC_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#define MODULE_ALIAS_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#define FUNCTION_ALIAS_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#include "PassRegistry.def"
return false;
}

static void printPassName(StringRef PassName, raw_ostream &OS) {
OS << " " << PassName << "\n";
}
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/AliasSet/argmemonly.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s
; RUN: opt -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s

@s = global i8 1, align 1
@d = global i8 2, align 1
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/AliasSet/guards.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s
; RUN: opt -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s
; RUN: opt -aa-pipeline=basic-aa -passes=print-alias-sets -S -o - < %s 2>&1 | FileCheck %s
declare void @llvm.experimental.guard(i1, ...)

Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/AliasSet/intrinsics.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s
; RUN: opt -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s

; CHECK: Alias sets for function 'test1':
; CHECK: Alias Set Tracker: 2 alias sets for 2 pointer values.
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/AliasSet/memset.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s
; RUN: opt -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s

@s = global i8 1, align 1
@d = global i8 2, align 1
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/AliasSet/memtransfer.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s
; RUN: opt -print-alias-sets -S -o - < %s 2>&1 | FileCheck %s

@s = global i8 1, align 1
@d = global i8 2, align 1
Expand Down
4 changes: 2 additions & 2 deletions llvm/test/Analysis/AliasSet/saturation.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; RUN: opt -basic-aa -print-alias-sets -alias-set-saturation-threshold=2 -S -o - < %s 2>&1 | FileCheck %s --check-prefix=CHECK --check-prefix=NOSAT
; RUN: opt -basic-aa -print-alias-sets -alias-set-saturation-threshold=1 -S -o - < %s 2>&1 | FileCheck %s --check-prefix=CHECK --check-prefix=SAT
; RUN: opt -print-alias-sets -alias-set-saturation-threshold=2 -S -o - < %s 2>&1 | FileCheck %s --check-prefix=CHECK --check-prefix=NOSAT
; RUN: opt -print-alias-sets -alias-set-saturation-threshold=1 -S -o - < %s 2>&1 | FileCheck %s --check-prefix=CHECK --check-prefix=SAT

; CHECK-LABEL: 'allmust'
; CHECK: AliasSet[{{.*}}, 1] must alias, Mod Pointers: (i32* %a, LocationSize::precise(4))
Expand Down
1 change: 0 additions & 1 deletion llvm/test/Analysis/Dominators/2007-01-14-BreakCritEdges.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
; RUN: opt < %s -domtree -break-crit-edges -disable-output
; RUN: opt < %s -passes='require<domtree>,break-crit-edges' -disable-output
; PR1110

Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/IVUsers/deep_recursion_in_scev.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -iv-users
; RUN: opt < %s -passes='print<iv-users>'
; This is a regression test against very slow execution...
; In bad case it should fail by timeout.
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128-ni:1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; RUN: opt -S -memdep -gvn -basic-aa < %s | FileCheck %s
; RUN: opt -S -memdep -memdep-block-scan-limit=1 -gvn -basic-aa < %s | FileCheck %s --check-prefix=WITH-LIMIT
; RUN: opt -S -gvn < %s | FileCheck %s
; RUN: opt -S -memdep-block-scan-limit=1 -gvn < %s | FileCheck %s --check-prefix=WITH-LIMIT
; CHECK-LABEL: @test(
; CHECK: load
; CHECK-NOT: load
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -memdep -gvn < %s
; RUN: opt -gvn < %s

define void @__memdep_requires_dominator_tree(i32* nocapture %bufUInt, i32* nocapture %pattern) nounwind {
entry:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -S -gvn -basic-aa < %s | FileCheck %s
; RUN: opt -S -gvn < %s | FileCheck %s

@u = global i32 5, align 4
@w = global i32 10, align 4
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -S -gvn --basic-aa < %s | FileCheck %s
; RUN: opt -S -gvn < %s | FileCheck %s

@u = global i32 5, align 4
@w = global i32 10, align 4
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/MemorySSA/pr46275.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -S -memoryssa -loop-deletion -loop-simplifycfg -verify-memoryssa < %s | FileCheck %s
; RUN: opt -S -passes='loop-mssa(loop-deletion,loop-simplifycfg)' -verify-memoryssa < %s | FileCheck %s
; REQUIRES: asserts

; CHECK-LABEL: @foo()
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Analysis/MemorySSA/reduce_clobber_limit.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -S -memoryssa %s | FileCheck %s
; RUN: opt -S -passes='require<memoryssa>' %s | FileCheck %s
; REQUIRES: asserts
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
; RUN: opt < %s -disable-output -iv-users
; RUN: opt < %s -passes='print<iv-users>'
; PR9633: Tests that SCEV handles the mul.i2 recurrence being folded to
; constant zero.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -globalopt -instcombine -loop-rotate -licm -instcombine -indvars -loop-deletion -constmerge -S | FileCheck %s
; RUN: opt < %s -globalopt -instcombine -loop-rotate -licm -instcombine -indvars -loop-deletion -constmerge -S | FileCheck %s
; PR11882: ComputeLoadConstantCompareExitLimit crash.
;
; for.body is deleted leaving a loop-invariant load.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
; RUN: opt < %s -iv-users -S -disable-output
; RUN: opt < %s -passes='require<iv-users>' -S -disable-output
;
; PR12868: Infinite recursion:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
; RUN: opt < %s -iv-users
; RUN: opt < %s -passes='require<iv-users>'
; PR4538

Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
; Ensure we can pass -scalar-evolution-max-iterations multiple times
; RUN: opt -S -scalar-evolution -scalar-evolution-max-iterations=42 -scalar-evolution-max-iterations=42 < %s
; RUN: opt -S -passes='require<scalar-evolution>' -scalar-evolution-max-iterations=42 -scalar-evolution-max-iterations=42 < %s
2 changes: 1 addition & 1 deletion llvm/test/Analysis/ScalarEvolution/scev-aa.ll
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; RUN: opt -disable-output < %s -aa-pipeline=scev-aa -passes=aa-eval -print-all-alias-modref-info \
; RUN: 2>&1 | FileCheck %s

; At the time of this writing, -basic-aa misses the example of the form
; At the time of this writing, misses the example of the form
; A[i+(j+1)] != A[i+j], which can arise from multi-dimensional array references,
; and the example of the form A[0] != A[i+1], where i+1 is known to be positive.

Expand Down
2 changes: 1 addition & 1 deletion llvm/test/CodeGen/AMDGPU/amdgpu-unroll-threshold.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -S -mtriple=amdgcn-- -basic-aa -loop-unroll | FileCheck %s
; RUN: opt < %s -S -mtriple=amdgcn-- -loop-unroll | FileCheck %s

; Check that the loop in unroll_default is not fully unrolled using the default
; unroll threshold
Expand Down
6 changes: 3 additions & 3 deletions llvm/test/CodeGen/AMDGPU/loop-idiom.ll
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
; RUN: opt -basic-aa -loop-idiom -S < %s -march=r600 -mcpu=redwood | FileCheck --check-prefix=R600 --check-prefix=FUNC %s
; RUN: opt -basic-aa -loop-idiom -S < %s -march=amdgcn -mcpu=tahiti -verify-machineinstrs| FileCheck --check-prefix=SI --check-prefix=FUNC %s
; RUN: opt -basic-aa -loop-idiom -S < %s -march=amdgcn -mcpu=tonga -verify-machineinstrs| FileCheck --check-prefix=SI --check-prefix=FUNC %s
; RUN: opt -loop-idiom -S < %s -march=r600 -mcpu=redwood | FileCheck --check-prefix=R600 --check-prefix=FUNC %s
; RUN: opt -loop-idiom -S < %s -march=amdgcn -mcpu=tahiti -verify-machineinstrs| FileCheck --check-prefix=SI --check-prefix=FUNC %s
; RUN: opt -loop-idiom -S < %s -march=amdgcn -mcpu=tonga -verify-machineinstrs| FileCheck --check-prefix=SI --check-prefix=FUNC %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"

Expand Down
2 changes: 1 addition & 1 deletion llvm/test/CodeGen/Hexagon/loop-idiom/hexagon-memmove1.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; Check for recognizing the "memmove" idiom.
; RUN: opt -basic-aa -hexagon-loop-idiom -S -mtriple hexagon-unknown-elf < %s \
; RUN: opt -hexagon-loop-idiom -S -mtriple hexagon-unknown-elf < %s \
; RUN: | FileCheck %s
; CHECK: call void @llvm.memmove

Expand Down
2 changes: 1 addition & 1 deletion llvm/test/CodeGen/Hexagon/loop-idiom/hexagon-memmove2.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -hexagon-loop-idiom -S -mtriple hexagon-unknown-elf < %s \
; RUN: opt -hexagon-loop-idiom -S -mtriple hexagon-unknown-elf < %s \
; RUN: | FileCheck %s

define void @PR14241(i32* %s, i64 %size) #0 {
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/CodeGen/Hexagon/loop-idiom/nullptr-crash.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -hexagon-loop-idiom -mtriple hexagon-unknown-elf < %s
; RUN: opt -hexagon-loop-idiom -mtriple hexagon-unknown-elf < %s
; REQUIRES: asserts

target triple = "hexagon"
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/DebugInfo/Generic/licm-hoist-debug-loc.ll
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
; Generated with
; clang -O0 -S -emit-llvm test.cpp -g -gline-tables-only -o t.ll
; opt -S -sroa -adce -simplifycfg -reassociate -domtree -loops \
; -loop-simplify -lcssa -basic-aa -aa -scalar-evolution -loop-rotate t.ll > test.ll
; -loop-simplify -lcssa -aa -scalar-evolution -loop-rotate t.ll > test.ll
;
; void bar(int *);
; void foo(int k, int p)
Expand Down
4 changes: 2 additions & 2 deletions llvm/test/DebugInfo/check-debugify-preserves-analyses.ll
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; RUN: opt < %s -globals-aa -function-attrs | \
; RUN: opt < %s -passes='require<globals-aa>,function-attrs' | \
; RUN: opt -S -strip -strip-dead-prototypes -strip-named-metadata > %t.no_dbg

; RUN: opt < %s -debugify-each -globals-aa -function-attrs | \
; RUN: opt < %s -debugify-each -passes='require<globals-aa>,function-attrs' | \
; RUN: opt -S -strip -strip-dead-prototypes -strip-named-metadata > %t.with_dbg

; RUN: diff %t.no_dbg %t.with_dbg
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Feature/OperandBundles/pr26510.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -S -globals-aa -function-attrs < %s | FileCheck %s
; RUN: opt -S -passes='require<globals-aa>,function-attrs' < %s | FileCheck %s
; RUN: opt -S -O3 < %s | FileCheck %s

; Apart from checking for the direct cause of the bug, we also check
Expand Down
5 changes: 0 additions & 5 deletions llvm/test/Other/2006-02-05-PassManager.ll

This file was deleted.

2 changes: 1 addition & 1 deletion llvm/test/Other/lint.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -lint -disable-output < %s 2>&1 | FileCheck %s
; RUN: opt -lint -disable-output < %s 2>&1 | FileCheck %s
; RUN: opt -aa-pipeline=basic-aa -passes=lint -disable-output < %s 2>&1 | FileCheck %s
target datalayout = "e-p:64:64:64"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -dse -S | FileCheck %s
; PR9561
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-n8:16:32"
target triple = "i386-apple-darwin9.8"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -dse -S -enable-dse-partial-overwrite-tracking | FileCheck %s
; RUN: opt < %s -dse -S -enable-dse-partial-overwrite-tracking | FileCheck %s
; PR28588

target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -dse -S | FileCheck %s

define void @write4to7(ptr nocapture %p) {
; CHECK-LABEL: @write4to7(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -dse -S | FileCheck %s
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"

%struct.vec2 = type { <4 x i32>, <4 x i32> }
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/PartialStore.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -basic-aa -dse -enable-dse-partial-store-merging=false -S | FileCheck %s
; RUN: opt < %s -dse -enable-dse-partial-store-merging=false -S | FileCheck %s
target datalayout = "E-p:64:64:64-a0:0:8-f32:32:32-f64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-v64:64:64-v128:128:128"

; Ensure that the dead store is deleted in this case. It is wholely
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/atomic-todo.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; XFAIL: *
; RUN: opt -basic-aa -dse -S < %s | FileCheck %s
; RUN: opt -dse -S < %s | FileCheck %s

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.0"
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/atomic.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -basic-aa -dse -S < %s | FileCheck %s
; RUN: opt -dse -S < %s | FileCheck %s

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.0"
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/calloc-store.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -dse -S | FileCheck %s

declare noalias ptr @calloc(i64, i64) inaccessiblememonly allockind("alloc,zeroed")

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -dse -S < %s | FileCheck %s
; RUN: opt -dse -S < %s | FileCheck %s
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"

%t = type { i32 }
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/crash.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -dse -S
; RUN: opt < %s -dse -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"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -basic-aa -dse -S < %s | FileCheck %s
; RUN: opt -dse -S < %s | FileCheck %s
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

Expand Down
8 changes: 4 additions & 4 deletions llvm/test/Transforms/DeadStoreElimination/debug-counter.ll
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
; REQUIRES: asserts

; Eliminates store to %R in the entry block.
; RUN: opt < %s -basic-aa -dse -debug-counter=dse-memoryssa-skip=0,dse-memoryssa-count=1 -S | FileCheck --check-prefix=SKIP0-COUNT1 %s
; RUN: opt < %s -dse -debug-counter=dse-memoryssa-skip=0,dse-memoryssa-count=1 -S | FileCheck --check-prefix=SKIP0-COUNT1 %s

; Eliminates store to %P in the entry block.
; RUN: opt < %s -basic-aa -dse -debug-counter=dse-memoryssa-skip=1,dse-memoryssa-count=1 -S | FileCheck --check-prefix=SKIP1-COUNT1 %s
; RUN: opt < %s -dse -debug-counter=dse-memoryssa-skip=1,dse-memoryssa-count=1 -S | FileCheck --check-prefix=SKIP1-COUNT1 %s

; Eliminates both stores in the entry block.
; RUN: opt < %s -basic-aa -dse -debug-counter=dse-memoryssa-skip=0,dse-memoryssa-count=2 -S | FileCheck --check-prefix=SKIP0-COUNT2 %s
; RUN: opt < %s -dse -debug-counter=dse-memoryssa-skip=0,dse-memoryssa-count=2 -S | FileCheck --check-prefix=SKIP0-COUNT2 %s

; Eliminates no stores.
; RUN: opt < %s -basic-aa -dse -debug-counter=dse-memoryssa-skip=2,dse-memoryssa-count=1 -S | FileCheck --check-prefix=SKIP2-COUNT1 %s
; RUN: opt < %s -dse -debug-counter=dse-memoryssa-skip=2,dse-memoryssa-count=1 -S | FileCheck --check-prefix=SKIP2-COUNT1 %s


target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/debuginfo.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -debugify -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -debugify -dse -S | FileCheck %s

target datalayout = "E-p:64:64:64-a0:0:8-f32:32:32-f64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-v64:64:64-v128:128:128"

Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/fence-todo.ll
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
; XFAIL: *

; RUN: opt -S -basic-aa -dse < %s | FileCheck %s
; RUN: opt -S -dse < %s | FileCheck %s

; We DSE stack alloc'ed and byval locations, in the presence of fences.
; Fence does not make an otherwise thread local store visible.
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/fence.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -S -basic-aa -dse < %s | FileCheck %s
; RUN: opt -S -dse < %s | FileCheck %s

; We conservative choose to prevent dead store elimination
; across release or stronger fences. It's not required
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/free.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -dse -S | FileCheck %s

target datalayout = "e-p:64:64:64"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; Test to make sure llvm.invariant.start calls are not treated as clobbers.
; RUN: opt < %s -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -dse -S | FileCheck %s

declare ptr @llvm.invariant.start.p0(i64, ptr nocapture) nounwind readonly

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -dse -S | FileCheck %s
; RUN: opt < %s -dse -S | FileCheck %s

; CHECK-LABEL: void @skipBarrier(ptr %ptr)
define void @skipBarrier(ptr %ptr) {
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/libcalls.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -S -inferattrs -basic-aa -dse | FileCheck %s
; RUN: opt < %s -S -inferattrs -dse | FileCheck %s
; RUN: opt < %s -S -aa-pipeline=basic-aa -passes=inferattrs,dse | FileCheck %s

target triple = "x86_64-unknown-linux-gnu"
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadStoreElimination/lifetime.ll
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt -S -basic-aa -dse < %s | FileCheck %s
; RUN: opt -S -dse < %s | FileCheck %s

target datalayout = "E-p:64:64:64-a0:0:8-f32:32:32-f64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-v64:64:64-v128:128:128"

Expand Down
Loading

0 comments on commit f3a928e

Please sign in to comment.