|
LLVM 24.0.0git
|
#include "InstrumentationOptions.h"#include "llvm/ADT/ArrayRef.h"#include "llvm/ADT/DenseMap.h"#include "llvm/ADT/Statistic.h"#include "llvm/ADT/StringRef.h"#include "llvm/Analysis/IndirectCallPromotionAnalysis.h"#include "llvm/Analysis/IndirectCallVisitor.h"#include "llvm/Analysis/OptimizationRemarkEmitter.h"#include "llvm/Analysis/ProfileSummaryInfo.h"#include "llvm/Analysis/TypeMetadataUtils.h"#include "llvm/IR/DiagnosticInfo.h"#include "llvm/IR/Dominators.h"#include "llvm/IR/Function.h"#include "llvm/IR/InstrTypes.h"#include "llvm/IR/Instructions.h"#include "llvm/IR/LLVMContext.h"#include "llvm/IR/MDBuilder.h"#include "llvm/IR/PassManager.h"#include "llvm/IR/ProfDataUtils.h"#include "llvm/IR/Value.h"#include "llvm/ProfileData/InstrProf.h"#include "llvm/ProfileData/ProfileCommon.h"#include "llvm/Support/Casting.h"#include "llvm/Support/CommandLine.h"#include "llvm/Support/Debug.h"#include "llvm/Support/Error.h"#include "llvm/Support/raw_ostream.h"#include "llvm/Transforms/Instrumentation/PGOInstrumentation.h"#include "llvm/Transforms/Utils/CallPromotionUtils.h"#include "llvm/Transforms/Utils/Instrumentation.h"#include <cassert>#include <cstdint>#include <set>#include <string>#include <utility>#include <vector>Go to the source code of this file.
Namespaces | |
| namespace | llvm |
| This is an optimization pass for GlobalISel generic memory operations. | |
Macros | |
| #define | DEBUG_TYPE "pgo-icall-prom" |
Functions | |
| STATISTIC (NumOfPGOICallPromotion, "Number of indirect call promotions.") | |
| STATISTIC (NumOfPGOICallsites, "Number of indirect call candidate sites.") | |
| static MDNode * | createBranchWeights (LLVMContext &Context, uint64_t TrueWeight, uint64_t FalseWeight) |
| static void | computeVirtualCallSiteTypeInfoMap (Module &M, ModuleAnalysisManager &MAM, VirtualCallSiteTypeInfoMap &VirtualCSInfo) |
| static bool | promoteIndirectCalls (const InstrumentationOptions &Opts, Module &M, ProfileSummaryInfo *PSI, bool InLTO, bool SamplePGO, ModuleAnalysisManager &MAM) |
| #define DEBUG_TYPE "pgo-icall-prom" |
Definition at line 54 of file IndirectCallPromotion.cpp.
|
static |
Definition at line 910 of file IndirectCallPromotion.cpp.
References llvm::cast(), llvm::dyn_cast(), F, FAM, llvm::findDevirtualizableCallsForTypeTest(), llvm::Intrinsic::getDeclarationIfExists(), llvm::make_early_inc_range(), MAM, llvm::PGOIndirectCallVisitor::tryGetVTableInstruction(), llvm::Value::use_empty(), and llvm::Value::uses().
Referenced by promoteIndirectCalls().
|
static |
Definition at line 560 of file IndirectCallPromotion.cpp.
References llvm::calculateCountScale(), llvm::MDBuilder::createBranchWeights(), llvm::scaleBranchCount(), and uint64_t.
Referenced by llvm::pgo::promoteIndirectCall().
|
static |
Definition at line 963 of file IndirectCallPromotion.cpp.
References Changed, computeVirtualCallSiteTypeInfoMap(), llvm::InstrProfSymtab::create(), llvm::dbgs(), E(), llvm::EnableVTableProfileUse, F, FAM, llvm::detail::DenseSetImpl< ValueT, MapTy >::insert_range(), LLVM_DEBUG, MAM, and llvm::toString().
Referenced by llvm::PGOIndirectCallPromotion::run().
| STATISTIC | ( | NumOfPGOICallPromotion | , |
| "Number of indirect call promotions." | ) |
| STATISTIC | ( | NumOfPGOICallsites | , |
| "Number of indirect call candidate sites." | ) |
References llvm::MaxNumVTableAnnotations.