Skip to content

Commit

Permalink
Merged master:51ff04567b2f into amd-gfx:340537749c25
Browse files Browse the repository at this point in the history
Local branch amd-gfx 3405377 Merged master:3cfd9384bff4 into amd-gfx:4f03f357fef1
Remote branch master 51ff045 Recommit "[DSE] Switch to MemorySSA-backed DSE by default."
  • Loading branch information
Sw authored and Sw committed Oct 16, 2020
2 parents 3405377 + 51ff045 commit 11d9db1
Show file tree
Hide file tree
Showing 84 changed files with 141 additions and 200 deletions.
2 changes: 0 additions & 2 deletions clang/lib/AST/ExprConstant.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7440,7 +7440,6 @@ class ExprEvaluatorBase
bool HasQualifier = false;

CallRef Call;
bool EvaluatedArgs = false;

// Extract function decl and 'this' pointer from the callee.
if (CalleeType->isSpecificBuiltinType(BuiltinType::BoundMember)) {
Expand Down Expand Up @@ -7499,7 +7498,6 @@ class ExprEvaluatorBase
if (!EvaluateArgs(isa<CXXMethodDecl>(FD) ? Args.slice(1) : Args, Call,
Info, FD, /*RightToLeft=*/true))
return false;
EvaluatedArgs = true;
}

// Overloaded operator calls to member functions are represented as normal
Expand Down
2 changes: 1 addition & 1 deletion clang/test/CodeGen/thinlto-distributed-newpm.ll
Original file line number Diff line number Diff line change
Expand Up @@ -130,12 +130,12 @@
; CHECK-O: Running pass: JumpThreadingPass on main
; CHECK-O: Running pass: CorrelatedValuePropagationPass on main
; CHECK-O: Running pass: DSEPass on main
; CHECK-O: Running analysis: PostDominatorTreeAnalysis on main
; CHECK-O: Starting {{.*}}Function pass manager run.
; CHECK-O: Running pass: LoopSimplifyPass on main
; CHECK-O: Running pass: LCSSAPass on main
; CHECK-O: Finished {{.*}}Function pass manager run.
; CHECK-O: Running pass: ADCEPass on main
; CHECK-O: Running analysis: PostDominatorTreeAnalysis on main
; CHECK-O: Running pass: SimplifyCFGPass on main
; CHECK-O: Running pass: InstCombinePass on main
; CHECK-O: Finished {{.*}}Function pass manager run.
Expand Down
3 changes: 0 additions & 3 deletions clang/test/CodeGenObjC/exceptions.m
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,6 @@ int f2() {
// CHECK-NEXT: [[T1:%.*]] = load i32, i32* [[X]]
// CHECK-NEXT: [[T2:%.*]] = add nsw i32 [[T1]], -1

// This store is dead.
// CHECK-NEXT: store i32 [[T2]], i32* [[X]]

// CHECK: store i32 6, i32* [[X]]
x++;
// CHECK-NEXT: call void asm sideeffect "", "*m,*m"(i32* nonnull [[X]]
Expand Down
3 changes: 2 additions & 1 deletion clang/test/Index/hidden-redecls.m
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ - (void)top_method;
// p1_method in protocol P1 is hidden since module_redecls.sub hasn't been
// imported yet. Check it is still indexed.

// RUN: c-index-test -index-file-full %s -isystem %S/Inputs -fmodules -target x86_64-apple-macosx10.7 | FileCheck %s
// RUN: rm -rf %t
// RUN: c-index-test -index-file-full %s -isystem %S/Inputs -fmodules -fmodules-cache-path=%t -target x86_64-apple-macosx10.7 | FileCheck %s
// CHECK: [indexDeclaration]: kind: objc-instance-method | name: p1_method | {{.*}} | loc: {{.*}}hidden-redecls-sub.h:2:9 | {{.*}} | isRedecl: 0
// CHECK: [indexDeclaration]: kind: objc-instance-method | name: p1_method | {{.*}} | loc: {{.*}}hidden-redecls-sub.h:3:9 | {{.*}} | isRedecl: 1
7 changes: 0 additions & 7 deletions llvm/include/llvm/Analysis/ScalarEvolution.h
Original file line number Diff line number Diff line change
Expand Up @@ -1489,13 +1489,6 @@ class ScalarEvolution {
ConstantRange getRangeForAffineAR(const SCEV *Start, const SCEV *Stop,
const SCEV *MaxBECount, unsigned BitWidth);

/// Determines the range for the affine non-self-wrapping SCEVAddRecExpr {\p
/// Start,+,\p Stop}<nw>.
ConstantRange getRangeForAffineNoSelfWrappingAR(const SCEVAddRecExpr *AddRec,
const SCEV *MaxBECount,
unsigned BitWidth,
RangeSignHint SignHint);

/// Try to compute a range for the affine SCEVAddRecExpr {\p Start,+,\p
/// Stop} by "factoring out" a ternary expression from the add recurrence.
/// Helper called by \c getRange.
Expand Down
75 changes: 0 additions & 75 deletions llvm/lib/Analysis/ScalarEvolution.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5509,17 +5509,6 @@ ScalarEvolution::getRangeRef(const SCEV *S,
ConservativeResult =
ConservativeResult.intersectWith(RangeFromFactoring, RangeType);
}

// Now try symbolic BE count and more powerful methods.
MaxBECount = computeMaxBackedgeTakenCount(AddRec->getLoop());
if (!isa<SCEVCouldNotCompute>(MaxBECount) &&
getTypeSizeInBits(MaxBECount->getType()) <= BitWidth &&
AddRec->hasNoSelfWrap()) {
auto RangeFromAffineNew = getRangeForAffineNoSelfWrappingAR(
AddRec, MaxBECount, BitWidth, SignHint);
ConservativeResult =
ConservativeResult.intersectWith(RangeFromAffineNew, RangeType);
}
}

return setRange(AddRec, SignHint, std::move(ConservativeResult));
Expand Down Expand Up @@ -5689,70 +5678,6 @@ ConstantRange ScalarEvolution::getRangeForAffineAR(const SCEV *Start,
return SR.intersectWith(UR, ConstantRange::Smallest);
}

ConstantRange ScalarEvolution::getRangeForAffineNoSelfWrappingAR(
const SCEVAddRecExpr *AddRec, const SCEV *MaxBECount, unsigned BitWidth,
ScalarEvolution::RangeSignHint SignHint) {
assert(AddRec->isAffine() && "Non-affine AddRecs are not suppored!\n");
assert(AddRec->hasNoSelfWrap() &&
"This only works for non-self-wrapping AddRecs!");
const bool IsSigned = SignHint == HINT_RANGE_SIGNED;
const SCEV *Step = AddRec->getStepRecurrence(*this);
// Let's make sure that we can prove that we do not self-wrap during
// MaxBECount iterations. We need this because MaxBECount is a maximum
// iteration count estimate, and we might infer nw from some exit for which we
// do not know max exit count (or any other side reasoning).
// TODO: Turn into assert at some point.
MaxBECount = getNoopOrZeroExtend(MaxBECount, AddRec->getType());
const SCEV *RangeWidth = getNegativeSCEV(getOne(AddRec->getType()));
const SCEV *StepAbs = getUMinExpr(Step, getNegativeSCEV(Step));
const SCEV *MaxItersWithoutWrap = getUDivExpr(RangeWidth, StepAbs);
if (!isKnownPredicate(ICmpInst::ICMP_ULE, MaxBECount, MaxItersWithoutWrap))
return ConstantRange::getFull(BitWidth);

ICmpInst::Predicate LEPred =
IsSigned ? ICmpInst::ICMP_SLE : ICmpInst::ICMP_ULE;
ICmpInst::Predicate GEPred =
IsSigned ? ICmpInst::ICMP_SGE : ICmpInst::ICMP_UGE;
const SCEV *Start = AddRec->getStart();
const SCEV *End = AddRec->evaluateAtIteration(MaxBECount, *this);

// We know that there is no self-wrap. Let's take Start and End values and
// look at all intermediate values V1, V2, ..., Vn that IndVar takes during
// the iteration. They either lie inside the range [Min(Start, End),
// Max(Start, End)] or outside it:
//
// Case 1: RangeMin ... Start V1 ... VN End ... RangeMax;
// Case 2: RangeMin Vk ... V1 Start ... End Vn ... Vk + 1 RangeMax;
//
// No self wrap flag guarantees that the intermediate values cannot be BOTH
// outside and inside the range [Min(Start, End), Max(Start, End)]. Using that
// knowledge, let's try to prove that we are dealing with Case 1. It is so if
// Start <= End and step is positive, or Start >= End and step is negative.
ConstantRange StartRange =
IsSigned ? getSignedRange(Start) : getUnsignedRange(Start);
ConstantRange EndRange =
IsSigned ? getSignedRange(End) : getUnsignedRange(End);
ConstantRange RangeBetween = StartRange.unionWith(EndRange);
// If they already cover full iteration space, we will know nothing useful
// even if we prove what we want to prove.
if (RangeBetween.isFullSet())
return RangeBetween;

// TODO: Too big expressions here may lead to exponential explosions on
// recursion. So we limit the size of operands to avoid this. Maybe in the
// future we should find a better way to deal with it.
const unsigned Threshold = 3;
if (Start->getExpressionSize() > Threshold ||
Step->getExpressionSize() > Threshold)
return ConstantRange::getFull(BitWidth);
if (isKnownPositive(Step) && isKnownPredicate(LEPred, Start, End))
return RangeBetween;
else if (isKnownNegative(Step) && isKnownPredicate(GEPred, Start, End))
return RangeBetween;
else
return ConstantRange::getFull(BitWidth);
}

ConstantRange ScalarEvolution::getRangeViaFactoring(const SCEV *Start,
const SCEV *Step,
const SCEV *MaxBECount,
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ EnablePartialStoreMerging("enable-dse-partial-store-merging",
cl::desc("Enable partial store merging in DSE"));

static cl::opt<bool>
EnableMemorySSA("enable-dse-memoryssa", cl::init(false), cl::Hidden,
EnableMemorySSA("enable-dse-memoryssa", cl::init(true), cl::Hidden,
cl::desc("Use the new MemorySSA-backed DSE."));

static cl::opt<unsigned>
Expand Down
1 change: 1 addition & 0 deletions llvm/test/Analysis/BasicAA/modref.ll
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ define void @test3(i8* %P, i8 %X) {

define void @test3a(i8* %P, i8 %X) {
; CHECK-LABEL: @test3a(
; CHECK-NEXT: call void @llvm.lifetime.end.p0i8(i64 10, i8* [[P:%.*]])
; CHECK-NEXT: ret void
;
%Y = add i8 %X, 1 ;; Dead, because the only use (the store) is dead.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ define i32 @test_01(i32 %start, i32* %p, i32* %q) {
; CHECK-NEXT: %0 = zext i32 %start to i64
; CHECK-NEXT: --> (zext i32 %start to i64) U: [0,4294967296) S: [0,4294967296)
; CHECK-NEXT: %indvars.iv = phi i64 [ %indvars.iv.next, %backedge ], [ %0, %entry ]
; CHECK-NEXT: --> {(zext i32 %start to i64),+,-1}<nsw><%loop> U: [0,4294967296) S: [0,4294967296) Exits: <<Unknown>> LoopDispositions: { %loop: Computable }
; CHECK-NEXT: --> {(zext i32 %start to i64),+,-1}<nsw><%loop> U: [-4294967295,4294967296) S: [-4294967295,4294967296) Exits: <<Unknown>> LoopDispositions: { %loop: Computable }
; CHECK-NEXT: %iv = phi i32 [ %start, %entry ], [ %iv.next, %backedge ]
; CHECK-NEXT: --> {%start,+,-1}<%loop> U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %loop: Computable }
; CHECK-NEXT: %iv.next = add i32 %iv, -1
Expand Down
14 changes: 6 additions & 8 deletions llvm/test/CodeGen/AMDGPU/opt-pipeline.ll
Original file line number Diff line number Diff line change
Expand Up @@ -522,15 +522,14 @@
; GCN-O2-NEXT: Value Propagation
; GCN-O2-NEXT: Basic Alias Analysis (stateless AA impl)
; GCN-O2-NEXT: Function Alias Analysis Results
; GCN-O2-NEXT: Phi Values Analysis
; GCN-O2-NEXT: Memory Dependence Analysis
; GCN-O2-NEXT: Dead Store Elimination
; GCN-O2-NEXT: Function Alias Analysis Results
; GCN-O2-NEXT: Post-Dominator Tree Construction
; GCN-O2-NEXT: Memory SSA
; GCN-O2-NEXT: Dead Store Elimination
; GCN-O2-NEXT: Natural Loop Information
; GCN-O2-NEXT: Canonicalize natural loops
; GCN-O2-NEXT: LCSSA Verifier
; GCN-O2-NEXT: Loop-Closed SSA Form Pass
; GCN-O2-NEXT: Function Alias Analysis Results
; GCN-O2-NEXT: Scalar Evolution Analysis
; GCN-O2-NEXT: Lazy Branch Probability Analysis
; GCN-O2-NEXT: Lazy Block Frequency Analysis
Expand Down Expand Up @@ -893,15 +892,14 @@
; GCN-O3-NEXT: Value Propagation
; GCN-O3-NEXT: Basic Alias Analysis (stateless AA impl)
; GCN-O3-NEXT: Function Alias Analysis Results
; GCN-O3-NEXT: Phi Values Analysis
; GCN-O3-NEXT: Memory Dependence Analysis
; GCN-O3-NEXT: Dead Store Elimination
; GCN-O3-NEXT: Function Alias Analysis Results
; GCN-O3-NEXT: Post-Dominator Tree Construction
; GCN-O3-NEXT: Memory SSA
; GCN-O3-NEXT: Dead Store Elimination
; GCN-O3-NEXT: Natural Loop Information
; GCN-O3-NEXT: Canonicalize natural loops
; GCN-O3-NEXT: LCSSA Verifier
; GCN-O3-NEXT: Loop-Closed SSA Form Pass
; GCN-O3-NEXT: Function Alias Analysis Results
; GCN-O3-NEXT: Scalar Evolution Analysis
; GCN-O3-NEXT: Lazy Branch Probability Analysis
; GCN-O3-NEXT: Lazy Block Frequency Analysis
Expand Down
3 changes: 2 additions & 1 deletion llvm/test/Other/new-pm-defaults.ll
Original file line number Diff line number Diff line change
Expand Up @@ -215,14 +215,15 @@
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
; CHECK-O23SZ-NEXT: Running pass: DSEPass
; CHECK-O23SZ-NEXT: Running analysis: PostDominatorTreeAnalysis
; CHECK-O23SZ-NEXT: Starting llvm::Function pass manager run.
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
; CHECK-O23SZ-NEXT: Finished llvm::Function pass manager run.
; CHECK-O23SZ-NEXT: Running pass: LICMPass
; CHECK-EP-SCALAR-LATE-NEXT: Running pass: NoOpFunctionPass
; CHECK-O-NEXT: Running pass: ADCEPass
; CHECK-O-NEXT: Running analysis: PostDominatorTreeAnalysis
; CHECK-O1-NEXT: Running analysis: PostDominatorTreeAnalysis
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
; CHECK-O-NEXT: Running pass: InstCombinePass
; CHECK-EP-PEEPHOLE-NEXT: Running pass: NoOpFunctionPass
Expand Down
2 changes: 2 additions & 0 deletions llvm/test/Other/new-pm-lto-defaults.ll
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,8 @@
; CHECK-O2-NEXT: Running analysis: PhiValuesAnalysis
; CHECK-O2-NEXT: Running pass: MemCpyOptPass on foo
; CHECK-O2-NEXT: Running pass: DSEPass on foo
; CHECK-O2-NEXT: Running analysis: MemorySSAAnalysis on foo
; CHECK-O2-NEXT: Running analysis: PostDominatorTreeAnalysis on foo
; CHECK-O2-NEXT: Running pass: InstCombinePass on foo
; CHECK-O2-NEXT: Running pass: SimplifyCFGPass on foo
; CHECK-O2-NEXT: Running pass: SCCPPass on foo
Expand Down
3 changes: 2 additions & 1 deletion llvm/test/Other/new-pm-thinlto-defaults.ll
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,14 @@
; CHECK-O23SZ-NEXT: Running pass: CorrelatedValuePropagationPass
; CHECK-O23SZ-NEXT: Invalidating analysis: LazyValueAnalysis
; CHECK-O23SZ-NEXT: Running pass: DSEPass
; CHECK-O23SZ-NEXT: Running analysis: PostDominatorTreeAnalysis on foo
; CHECK-O23SZ-NEXT: Starting llvm::Function pass manager run
; CHECK-O23SZ-NEXT: Running pass: LoopSimplifyPass
; CHECK-O23SZ-NEXT: Running pass: LCSSAPass
; CHECK-O23SZ-NEXT: Finished llvm::Function pass manager run
; CHECK-O23SZ-NEXT: Running pass: LICMPass on Loop at depth 1 containing: %loop
; CHECK-O-NEXT: Running pass: ADCEPass
; CHECK-O-NEXT: Running analysis: PostDominatorTreeAnalysis
; CHECK-O1-NEXT: Running analysis: PostDominatorTreeAnalysis
; CHECK-O-NEXT: Running pass: SimplifyCFGPass
; CHECK-O-NEXT: Running pass: InstCombinePass
; CHECK-O-NEXT: Finished llvm::Function pass manager run.
Expand Down
7 changes: 3 additions & 4 deletions llvm/test/Other/opt-O2-pipeline.ll
Original file line number Diff line number Diff line change
Expand Up @@ -162,15 +162,14 @@
; CHECK-NEXT: Value Propagation
; CHECK-NEXT: Basic Alias Analysis (stateless AA impl)
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Phi Values Analysis
; CHECK-NEXT: Memory Dependence Analysis
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Post-Dominator Tree Construction
; CHECK-NEXT: Memory SSA
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Natural Loop Information
; CHECK-NEXT: Canonicalize natural loops
; CHECK-NEXT: LCSSA Verifier
; CHECK-NEXT: Loop-Closed SSA Form Pass
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Scalar Evolution Analysis
; CHECK-NEXT: Lazy Branch Probability Analysis
; CHECK-NEXT: Lazy Block Frequency Analysis
Expand Down
7 changes: 3 additions & 4 deletions llvm/test/Other/opt-O3-pipeline-enable-matrix.ll
Original file line number Diff line number Diff line change
Expand Up @@ -167,15 +167,14 @@
; CHECK-NEXT: Value Propagation
; CHECK-NEXT: Basic Alias Analysis (stateless AA impl)
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Phi Values Analysis
; CHECK-NEXT: Memory Dependence Analysis
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Post-Dominator Tree Construction
; CHECK-NEXT: Memory SSA
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Natural Loop Information
; CHECK-NEXT: Canonicalize natural loops
; CHECK-NEXT: LCSSA Verifier
; CHECK-NEXT: Loop-Closed SSA Form Pass
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Scalar Evolution Analysis
; CHECK-NEXT: Lazy Branch Probability Analysis
; CHECK-NEXT: Lazy Block Frequency Analysis
Expand Down
7 changes: 3 additions & 4 deletions llvm/test/Other/opt-O3-pipeline.ll
Original file line number Diff line number Diff line change
Expand Up @@ -167,15 +167,14 @@
; CHECK-NEXT: Value Propagation
; CHECK-NEXT: Basic Alias Analysis (stateless AA impl)
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Phi Values Analysis
; CHECK-NEXT: Memory Dependence Analysis
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Post-Dominator Tree Construction
; CHECK-NEXT: Memory SSA
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Natural Loop Information
; CHECK-NEXT: Canonicalize natural loops
; CHECK-NEXT: LCSSA Verifier
; CHECK-NEXT: Loop-Closed SSA Form Pass
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Scalar Evolution Analysis
; CHECK-NEXT: Lazy Branch Probability Analysis
; CHECK-NEXT: Lazy Block Frequency Analysis
Expand Down
7 changes: 3 additions & 4 deletions llvm/test/Other/opt-Os-pipeline.ll
Original file line number Diff line number Diff line change
Expand Up @@ -148,15 +148,14 @@
; CHECK-NEXT: Value Propagation
; CHECK-NEXT: Basic Alias Analysis (stateless AA impl)
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Phi Values Analysis
; CHECK-NEXT: Memory Dependence Analysis
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Post-Dominator Tree Construction
; CHECK-NEXT: Memory SSA
; CHECK-NEXT: Dead Store Elimination
; CHECK-NEXT: Natural Loop Information
; CHECK-NEXT: Canonicalize natural loops
; CHECK-NEXT: LCSSA Verifier
; CHECK-NEXT: Loop-Closed SSA Form Pass
; CHECK-NEXT: Function Alias Analysis Results
; CHECK-NEXT: Scalar Evolution Analysis
; CHECK-NEXT: Lazy Branch Probability Analysis
; CHECK-NEXT: Lazy Block Frequency Analysis
Expand Down
11 changes: 11 additions & 0 deletions llvm/test/Transforms/Coroutines/ArgAddr.ll
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,19 @@ entry:
call void @llvm.coro.destroy(i8* %hdl)
ret i32 0
; CHECK: call void @ctor
; CHECK-NEXT: %dec1.spill.addr.i = getelementptr inbounds i8, i8* %call.i, i64 20
; CHECK-NEXT: bitcast i8* %dec1.spill.addr.i to i32*
; CHECK-NEXT: store i32 4
; CHECK-NEXT: call void @print(i32 4)
; CHECK-NEXT: %index.addr12.i = getelementptr inbounds i8, i8* %call.i, i64 24
; CHECK-NEXT: bitcast i8* %index.addr12.i to i1*
; CHECK-NEXT: store i1 false
; CHECK-NEXT: store i32 3
; CHECK-NEXT: store i32 3
; CHECK-NEXT: call void @print(i32 3)
; CHECK-NEXT: store i1 false
; CHECK-NEXT: store i32 2
; CHECK-NEXT: store i32 2
; CHECK-NEXT: call void @print(i32 2)
; CHECK: ret i32 0
}
Expand Down
6 changes: 3 additions & 3 deletions llvm/test/Transforms/Coroutines/coro-retcon.ll
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
; First example from Doc/Coroutines.rst (two block loop) converted to retcon
; RUN: opt < %s -enable-coroutines -O2 -S | FileCheck %s
; RUN: opt < %s -enable-coroutines -aa-pipeline=basic-aa -passes='default<O2>' -S | FileCheck %s
; RUN: opt < %s -enable-coroutines -O2 -S | FileCheck --check-prefixes=CHECK %s
; RUN: opt < %s -enable-coroutines -aa-pipeline=basic-aa -passes='default<O2>' -S | FileCheck --check-prefixes=CHECK,NPM %s

define i8* @f(i8* %buffer, i32 %n) {
entry:
Expand Down Expand Up @@ -75,7 +75,7 @@ entry:
; CHECK-NEXT: call void @print(i32 [[INC]])
; CHECK-NEXT: [[LOAD:%.*]] = load i32, i32* [[SLOT]], align 4
; CHECK-NEXT: [[INC:%.*]] = add i32 [[LOAD]], 1
; CHECK-NEXT: store i32 [[INC]], i32* [[SLOT]], align 4
; NPM-NEXT: store i32 [[INC]], i32* [[SLOT]], align 4
; CHECK-NEXT: call void @print(i32 [[INC]])
; CHECK-NEXT: ret i32 0

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -dse -enable-dse-memoryssa -S | FileCheck %s
; RUN: opt < %s -basic-aa -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 -dse -enable-dse-memoryssa -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-darwin"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt -dse -enable-dse-memoryssa -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-f128:128:128-n8:16:32:64"
target triple = "x86_64-unknown-linux-gnu"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; RUN: opt < %s -basic-aa -dse -enable-dse-memoryssa -S -enable-dse-partial-overwrite-tracking | FileCheck %s
; RUN: opt < %s -basic-aa -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
Loading

0 comments on commit 11d9db1

Please sign in to comment.