#ifndef LLVM_ANALYSIS_CFGPRINTER_H
#define LLVM_ANALYSIS_CFGPRINTER_H
#include "llvm/Analysis/BlockFrequencyInfo.h"
#include "llvm/Analysis/BranchProbabilityInfo.h"
#include "llvm/Analysis/HeatUtils.h"
#include "llvm/IR/CFG.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/PassManager.h"
#include "llvm/IR/ProfDataUtils.h"
#include "llvm/Support/DOTGraphTraits.h"
#include "llvm/Support/FormatVariadic.h"
namespace llvm {
template <class GraphType> struct GraphTraits;
class CFGViewerPass : public PassInfoMixin<CFGViewerPass> { … };
class CFGOnlyViewerPass : public PassInfoMixin<CFGOnlyViewerPass> { … };
class CFGPrinterPass : public PassInfoMixin<CFGPrinterPass> { … };
class CFGOnlyPrinterPass : public PassInfoMixin<CFGOnlyPrinterPass> { … };
class DOTFuncInfo { … };
template <>
struct GraphTraits<DOTFuncInfo *> : public GraphTraits<const BasicBlock *> { … };
template <typename BasicBlockT>
std::string SimpleNodeLabelString(const BasicBlockT *Node) { … }
template <typename BasicBlockT>
std::string CompleteNodeLabelString(
const BasicBlockT *Node,
function_ref<void(raw_string_ostream &, const BasicBlockT &)>
HandleBasicBlock,
function_ref<void(std::string &, unsigned &, unsigned)>
HandleComment) { … }
template <>
struct DOTGraphTraits<DOTFuncInfo *> : public DefaultDOTGraphTraits { … };
}
#endif