[PM/AA] Wire up CFLAA to the new pass manager fully, and port one of its

tests over to exercise this code.

This uncovered a few missing bits here and there in the analysis, but
nothing interesting.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@261404 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chandler Carruth 2016-02-20 03:52:02 +00:00
parent 89a08aa76a
commit 10d9c2cec2
5 changed files with 5 additions and 0 deletions

View File

@ -34,6 +34,7 @@ class CFLAAResult : public AAResultBase<CFLAAResult> {
public:
explicit CFLAAResult(const TargetLibraryInfo &TLI);
CFLAAResult(CFLAAResult &&Arg);
~CFLAAResult();
/// Handle invalidation events from the new pass manager.
///

View File

@ -61,6 +61,7 @@ using namespace llvm;
CFLAAResult::CFLAAResult(const TargetLibraryInfo &TLI) : AAResultBase(TLI) {}
CFLAAResult::CFLAAResult(CFLAAResult &&Arg) : AAResultBase(std::move(Arg)) {}
CFLAAResult::~CFLAAResult() {}
// \brief Information we have about a function and would like to keep around
struct CFLAAResult::FunctionInfo {

View File

@ -20,6 +20,7 @@
#include "llvm/Analysis/AliasAnalysisEvaluator.h"
#include "llvm/Analysis/AssumptionCache.h"
#include "llvm/Analysis/BasicAliasAnalysis.h"
#include "llvm/Analysis/CFLAliasAnalysis.h"
#include "llvm/Analysis/CGSCCPassManager.h"
#include "llvm/Analysis/LazyCallGraph.h"
#include "llvm/Analysis/LoopInfo.h"

View File

@ -69,6 +69,7 @@ FUNCTION_ANALYSIS("targetir",
FUNCTION_ANALYSIS(NAME, CREATE_PASS)
#endif
FUNCTION_ALIAS_ANALYSIS("basic-aa", BasicAA())
FUNCTION_ALIAS_ANALYSIS("cfl-aa", CFLAA())
#undef FUNCTION_ALIAS_ANALYSIS
#undef FUNCTION_ANALYSIS

View File

@ -2,6 +2,7 @@
; that involve arguments.
; RUN: opt < %s -disable-basicaa -cfl-aa -aa-eval -print-may-aliases -disable-output 2>&1 | FileCheck %s
; RUN: opt < %s -aa-pipeline=cfl-aa -passes=aa-eval -print-may-aliases -disable-output 2>&1 | FileCheck %s
; CHECK: Function: test
; CHECK: 2 Total Alias Queries Performed