LLVM  14.0.0git
Classes | Namespaces | Macros | Functions
CodeGenPassBuilder.h File Reference
#include "llvm/ADT/FunctionExtras.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Analysis/AliasAnalysis.h"
#include "llvm/Analysis/BasicAliasAnalysis.h"
#include "llvm/Analysis/CFLAndersAliasAnalysis.h"
#include "llvm/Analysis/CFLSteensAliasAnalysis.h"
#include "llvm/Analysis/ScopedNoAliasAA.h"
#include "llvm/Analysis/TargetTransformInfo.h"
#include "llvm/Analysis/TypeBasedAliasAnalysis.h"
#include "llvm/CodeGen/ExpandReductions.h"
#include "llvm/CodeGen/MachineModuleInfo.h"
#include "llvm/CodeGen/MachinePassManager.h"
#include "llvm/CodeGen/PreISelIntrinsicLowering.h"
#include "llvm/CodeGen/ReplaceWithVeclib.h"
#include "llvm/CodeGen/UnreachableBlockElim.h"
#include "llvm/IR/IRPrintingPasses.h"
#include "llvm/IR/PassManager.h"
#include "llvm/IR/Verifier.h"
#include "llvm/MC/MCAsmInfo.h"
#include "llvm/MC/MCStreamer.h"
#include "llvm/MC/MCTargetOptions.h"
#include "llvm/Support/CodeGen.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/Error.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Target/CGPassBuilderOption.h"
#include "llvm/Target/TargetMachine.h"
#include "llvm/Transforms/Scalar.h"
#include "llvm/Transforms/Scalar/ConstantHoisting.h"
#include "llvm/Transforms/Scalar/LoopPassManager.h"
#include "llvm/Transforms/Scalar/LoopStrengthReduce.h"
#include "llvm/Transforms/Scalar/LowerConstantIntrinsics.h"
#include "llvm/Transforms/Scalar/MergeICmps.h"
#include "llvm/Transforms/Scalar/PartiallyInlineLibCalls.h"
#include "llvm/Transforms/Scalar/ScalarizeMaskedMemIntrin.h"
#include "llvm/Transforms/Utils.h"
#include "llvm/Transforms/Utils/EntryExitInstrumenter.h"
#include "llvm/Transforms/Utils/LowerInvoke.h"
#include <cassert>
#include <type_traits>
#include <utility>
#include "MachinePassRegistry.def"
#include "llvm/CodeGen/MachinePassRegistry.def"
Include dependency graph for CodeGenPassBuilder.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  llvm::CodeGenPassBuilder< DerivedT >
 This class provides access to building LLVM's passes. More...
 
class  llvm::CodeGenPassBuilder< DerivedT >::AddIRPass
 
class  llvm::CodeGenPassBuilder< DerivedT >::AddMachinePass
 

Namespaces

 llvm
 This is an optimization pass for GlobalISel generic memory operations.
 

Macros

#define DUMMY_FUNCTION_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define DUMMY_MODULE_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define DUMMY_MACHINE_MODULE_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define DUMMY_MACHINE_FUNCTION_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define MODULE_ANALYSIS(NAME, PASS_NAME, CONSTRUCTOR)   MAM.registerPass([&] { return PASS_NAME CONSTRUCTOR; });
 
#define FUNCTION_ANALYSIS(NAME, PASS_NAME, CONSTRUCTOR)   FAM.registerPass([&] { return PASS_NAME CONSTRUCTOR; });
 
#define MACHINE_FUNCTION_ANALYSIS(NAME, PASS_NAME, CONSTRUCTOR)   MFAM.registerPass([&] { return PASS_NAME CONSTRUCTOR; });
 
#define FUNCTION_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define DUMMY_FUNCTION_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define MODULE_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define DUMMY_MODULE_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define MACHINE_MODULE_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define DUMMY_MACHINE_MODULE_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define MACHINE_FUNCTION_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 
#define DUMMY_MACHINE_FUNCTION_PASS(NAME, PASS_NAME, CONSTRUCTOR)
 

Functions

static AAManager llvm::registerAAAnalyses (CFLAAType UseCFLAA)
 

Detailed Description

Interfaces for registering analysis passes, producing common pass manager configurations, and parsing of pass pipelines.

Definition in file CodeGenPassBuilder.h.

Macro Definition Documentation

◆ DUMMY_FUNCTION_PASS [1/2]

#define DUMMY_FUNCTION_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
struct PASS_NAME : public PassInfoMixin<PASS_NAME> { \
template <typename... Ts> PASS_NAME(Ts &&...) {} \
PreservedAnalyses run(Function &, FunctionAnalysisManager &) { \
} \
};

Definition at line 65 of file CodeGenPassBuilder.h.

◆ DUMMY_FUNCTION_PASS [2/2]

#define DUMMY_FUNCTION_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, false};

Definition at line 65 of file CodeGenPassBuilder.h.

◆ DUMMY_MACHINE_FUNCTION_PASS [1/2]

#define DUMMY_MACHINE_FUNCTION_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
struct PASS_NAME : public PassInfoMixin<PASS_NAME> { \
template <typename... Ts> PASS_NAME(Ts &&...) {} \
PreservedAnalyses run(MachineFunction &, \
MachineFunctionAnalysisManager &) { \
} \
static AnalysisKey Key; \
};

Definition at line 91 of file CodeGenPassBuilder.h.

◆ DUMMY_MACHINE_FUNCTION_PASS [2/2]

#define DUMMY_MACHINE_FUNCTION_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, true};

Definition at line 91 of file CodeGenPassBuilder.h.

◆ DUMMY_MACHINE_MODULE_PASS [1/2]

#define DUMMY_MACHINE_MODULE_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
struct PASS_NAME : public PassInfoMixin<PASS_NAME> { \
template <typename... Ts> PASS_NAME(Ts &&...) {} \
Error run(Module &, MachineFunctionAnalysisManager &) { \
return Error::success(); \
} \
PreservedAnalyses run(MachineFunction &, \
MachineFunctionAnalysisManager &) { \
llvm_unreachable("this api is to make new PM api happy"); \
} \
static AnalysisKey Key; \
};

Definition at line 79 of file CodeGenPassBuilder.h.

◆ DUMMY_MACHINE_MODULE_PASS [2/2]

#define DUMMY_MACHINE_MODULE_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, true};

Definition at line 79 of file CodeGenPassBuilder.h.

◆ DUMMY_MODULE_PASS [1/2]

#define DUMMY_MODULE_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
struct PASS_NAME : public PassInfoMixin<PASS_NAME> { \
template <typename... Ts> PASS_NAME(Ts &&...) {} \
PreservedAnalyses run(Module &, ModuleAnalysisManager &) { \
} \
};

Definition at line 72 of file CodeGenPassBuilder.h.

◆ DUMMY_MODULE_PASS [2/2]

#define DUMMY_MODULE_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, false};

Definition at line 72 of file CodeGenPassBuilder.h.

◆ FUNCTION_ANALYSIS

#define FUNCTION_ANALYSIS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)    FAM.registerPass([&] { return PASS_NAME CONSTRUCTOR; });

◆ FUNCTION_PASS

#define FUNCTION_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, false};

◆ MACHINE_FUNCTION_ANALYSIS

#define MACHINE_FUNCTION_ANALYSIS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)    MFAM.registerPass([&] { return PASS_NAME CONSTRUCTOR; });

◆ MACHINE_FUNCTION_PASS

#define MACHINE_FUNCTION_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, true};

◆ MACHINE_MODULE_PASS

#define MACHINE_MODULE_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, true};

◆ MODULE_ANALYSIS

#define MODULE_ANALYSIS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)    MAM.registerPass([&] { return PASS_NAME CONSTRUCTOR; });

◆ MODULE_PASS

#define MODULE_PASS (   NAME,
  PASS_NAME,
  CONSTRUCTOR 
)
Value:
if (Name == NAME) \
Ret = {#PASS_NAME, false};
PASS_NAME
#define PASS_NAME
Definition: TypePromotion.cpp:43
llvm::ModuleAnalysisManager
AnalysisManager< Module > ModuleAnalysisManager
Convenience typedef for the Module analysis manager.
Definition: PassManager.h:916
llvm::AMDGPU::PALMD::Key
Key
PAL metadata keys.
Definition: AMDGPUMetadata.h:481
llvm::LegalityPredicates::all
Predicate all(Predicate P0, Predicate P1)
True iff P0 and P1 are true.
Definition: LegalizerInfo.h:226
Module
Machine Check Debug Module
Definition: MachineCheckDebugify.cpp:122
llvm::GraphProgram::Name
Name
Definition: GraphWriter.h:52
llvm::FunctionAnalysisManager
AnalysisManager< Function > FunctionAnalysisManager
Convenience typedef for the Function analysis manager.
Definition: PassManager.h:921