mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
f36d8dfcf7
By using PhiValuesAnalysis we can get all the values reachable from a phi, so we can be more precise instead of giving up when a phi has phi operands. We can't make BaseicAA directly use PhiValuesAnalysis though, as the user of BasicAA may modify the function in ways that PhiValuesAnalysis can't cope with. For this optional usage to work correctly BasicAAWrapperPass now needs to be not marked as CFG-only (i.e. it is now invalidated even when CFG is preserved) due to how the legacy pass manager handles dependent passes being invalidated, namely the depending pass still has a pointer to the now-dead dependent pass. Differential Revision: https://reviews.llvm.org/D44564 llvm-svn: 338242
35 lines
1.4 KiB
LLVM
35 lines
1.4 KiB
LLVM
; RUN: opt < %s -debug-pass=Structure -globals-aa -loop-vectorize -sccp -loop-vectorize -globals-aa 2>&1 -S | FileCheck %s
|
|
; RUN: opt < %s -debug-pass-manager -passes='loop-vectorize,sccp,loop-vectorize' 2>&1 -S | FileCheck --check-prefix=NEW-PM %s
|
|
|
|
; Check CFG-only analysis are preserved by SCCP by running it between 2
|
|
; loop-vectorize runs.
|
|
|
|
; CHECK: Globals Alias Analysis
|
|
; CHECK: Dominator Tree Construction
|
|
; CHECK: Natural Loop Information
|
|
; CHECK: Sparse Conditional Constant Propagation
|
|
; CHECK-NOT: Dominator Tree Construction
|
|
; CHECK-NOT: Natural Loop Information
|
|
; CHECK-NOT: Globals Alias Analysis
|
|
; CHECK: Loop Vectorization
|
|
|
|
; NEW-PM-DAG: Running analysis: LoopAnalysis on test
|
|
; NEW-PM-DAG: Running analysis: DominatorTreeAnalysis on test
|
|
; NEW-PM-DAG: Running analysis: AssumptionAnalysis on test
|
|
; NEW-PM-DAG: Running analysis: TargetLibraryAnalysis on test
|
|
; NEW-PM-DAG: Running analysis: TargetIRAnalysis on test
|
|
; NEW-PM: Running pass: SCCPPass on test
|
|
; NEW-PM-NOT: Running analysis: LoopAnalysis on test
|
|
; NEW-PM-NOT: Running analysis: DominatorTreeAnalysis on test
|
|
; NEW-PM-NOT: Running analysis: AssumptionAnalysis on test
|
|
; NEW-PM-NOT: Running analysis: TargetLibraryAnalysis on test
|
|
; NEW-PM-NOT: Running analysis: TargetIRAnalysis on test
|
|
; NEW-PM: Finished llvm::Function pass manager run.
|
|
|
|
|
|
define i32 @test() {
|
|
entry:
|
|
%res = add i32 1, 10
|
|
ret i32 %res
|
|
}
|