LLVM: lib/CodeGen/MachinePostDominators.cpp Source File (original) (raw)

1

2

3

4

5

6

7

8

9

10

11

12

13

17

18using namespace llvm;

19

20namespace llvm {

22

23namespace DomTreeBuilder {

24

25template void Calculate(MBBPostDomTree &DT);

26template void InsertEdge(MBBPostDomTree &DT,

29template void DeleteEdge(MBBPostDomTree &DT,

32template void ApplyUpdates(MBBPostDomTree &DT,

33 MBBPostDomTreeGraphDiff &,

34 MBBPostDomTreeGraphDiff *);

35template bool Verify(const MBBPostDomTree &DT,

36 MBBPostDomTree::VerificationLevel VL);

37

38}

40}

41

42AnalysisKey MachinePostDominatorTreeAnalysis::Key;

43

48}

49

53 OS << "MachinePostDominatorTree for machine function: " << MF.getName()

54 << '\n';

57}

58

60

61

63 "MachinePostDominator Tree Construction", true, true)

64

69}

70

74 PDT->recalculate(F);

75 return false;

76}

77

82}

83

87

88

90 return !PAC.preserved() &&

93}

94

98

102

103

105 return nullptr;

106 }

107

108 return NCD;

109}

110

115}

116

118 const Module *M) const {

119 PDT->print(OS);

120}

BlockVerifier::State From

DenseMap< Block *, BlockRelaxAux > Blocks

Generic dominator tree construction - this file provides routines to construct immediate dominator in...

#define INITIALIZE_PASS(passName, arg, name, cfg, analysis)

assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())

This templated class represents "all analyses that operate over " (e....

API to communicate dependencies between analyses during invalidation.

A container for analyses that lazily runs them and caches their results.

PassT::Result & getResult(IRUnitT &IR, ExtraArgTs... ExtraArgs)

Get the result of an analysis pass for a given IR unit.

Represent the analysis usage information of a pass.

void setPreservesAll()

Set by analyses that do not transform their input at all.

ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...

Represents analyses that only rely on functions' control flow.

Core dominator tree base class.

NodeT * findNearestCommonDominator(NodeT *A, NodeT *B) const

Find nearest common dominator basic block for basic block A and B.

DomTreeNodeBase< NodeT > * getNode(const NodeT *BB) const

getNode - return the (Post)DominatorTree node for the specified basic block.

bool isVirtualRoot(const DomTreeNodeBase< NodeT > *A) const

MachineFunctionPass - This class adapts the FunctionPass interface to allow convenient creation of pa...

void getAnalysisUsage(AnalysisUsage &AU) const override

getAnalysisUsage - Subclasses that override getAnalysisUsage must call this.

StringRef getName() const

getName - Return the name of the corresponding LLVM function.

Result run(MachineFunction &MF, MachineFunctionAnalysisManager &MFAM)

PreservedAnalyses run(MachineFunction &MF, MachineFunctionAnalysisManager &MFAM)

void verifyAnalysis() const override

verifyAnalysis() - This member can be implemented by a analysis pass to check state of analysis infor...

bool runOnMachineFunction(MachineFunction &MF) override

runOnMachineFunction - This method must be overloaded to perform the desired machine code transformat...

void print(llvm::raw_ostream &OS, const Module *M=nullptr) const override

print - Print out the internal state of the pass.

void getAnalysisUsage(AnalysisUsage &AU) const override

getAnalysisUsage - Subclasses that override getAnalysisUsage must call this.

MachinePostDominatorTree - an analysis pass wrapper for DominatorTree used to compute the post-domina...

bool invalidate(MachineFunction &, const PreservedAnalyses &PA, MachineFunctionAnalysisManager::Invalidator &)

Handle invalidation explicitly.

MachineBasicBlock * findNearestCommonDominator(ArrayRef< MachineBasicBlock * > Blocks) const

Returns the nearest common dominator of the given blocks.

A Module instance is used to store all the information related to an LLVM module.

static PassRegistry * getPassRegistry()

getPassRegistry - Access the global registry object, which is automatically initialized at applicatio...

A set of analyses that are preserved following a run of a transformation pass.

static PreservedAnalyses all()

Construct a special preserved set that preserves all passes.

PreservedAnalysisChecker getChecker() const

Build a checker for this PreservedAnalyses and the specified analysis type.

This class implements an extremely fast bulk output stream that can only output to a stream.

This is an optimization pass for GlobalISel generic memory operations.

void initializeMachinePostDominatorTreeWrapperPassPass(PassRegistry &)

Printable print(const GCNRegPressure &RP, const GCNSubtarget *ST=nullptr)

void report_fatal_error(Error Err, bool gen_crash_diag=true)

Report a serious error, calling any installed error handler.

bool VerifyMachineDomInfo

A special type used by analysis passes to provide an address that identifies that particular analysis...