LLVM 20.0.0git
Namespaces | Macros | Functions | Variables
LTO.cpp File Reference
#include "llvm/LTO/LTO.h"
#include "llvm/ADT/ScopeExit.h"
#include "llvm/ADT/SmallSet.h"
#include "llvm/ADT/StableHashing.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/Analysis/OptimizationRemarkEmitter.h"
#include "llvm/Analysis/StackSafetyAnalysis.h"
#include "llvm/Analysis/TargetLibraryInfo.h"
#include "llvm/Analysis/TargetTransformInfo.h"
#include "llvm/Bitcode/BitcodeReader.h"
#include "llvm/Bitcode/BitcodeWriter.h"
#include "llvm/CGData/CodeGenData.h"
#include "llvm/CodeGen/Analysis.h"
#include "llvm/Config/llvm-config.h"
#include "llvm/IR/AutoUpgrade.h"
#include "llvm/IR/DiagnosticPrinter.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/IR/LLVMRemarkStreamer.h"
#include "llvm/IR/LegacyPassManager.h"
#include "llvm/IR/Mangler.h"
#include "llvm/IR/Metadata.h"
#include "llvm/IR/RuntimeLibcalls.h"
#include "llvm/LTO/LTOBackend.h"
#include "llvm/Linker/IRMover.h"
#include "llvm/MC/TargetRegistry.h"
#include "llvm/Object/IRObjectFile.h"
#include "llvm/Support/Caching.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Error.h"
#include "llvm/Support/FileSystem.h"
#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/Path.h"
#include "llvm/Support/SHA1.h"
#include "llvm/Support/SourceMgr.h"
#include "llvm/Support/ThreadPool.h"
#include "llvm/Support/Threading.h"
#include "llvm/Support/TimeProfiler.h"
#include "llvm/Support/ToolOutputFile.h"
#include "llvm/Support/VCSRevision.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/Target/TargetOptions.h"
#include "llvm/Transforms/IPO.h"
#include "llvm/Transforms/IPO/MemProfContextDisambiguation.h"
#include "llvm/Transforms/IPO/WholeProgramDevirt.h"
#include "llvm/Transforms/Utils/FunctionImportUtils.h"
#include "llvm/Transforms/Utils/SplitModule.h"
#include <optional>
#include <set>

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   "lto"
 

Functions

cl::opt< boolllvm::EnableLTOInternalization ("enable-lto-internalization", cl::init(true), cl::Hidden, cl::desc("Enable global value internalization in LTO"))
 Enable global value internalization in LTO.
 
static void thinLTOResolvePrevailingGUID (const Config &C, ValueInfo VI, DenseSet< GlobalValueSummary * > &GlobalInvolvedWithAlias, function_ref< bool(GlobalValue::GUID, const GlobalValueSummary *)> isPrevailing, function_ref< void(StringRef, GlobalValue::GUID, GlobalValue::LinkageTypes)> recordNewLinkage, const DenseSet< GlobalValue::GUID > &GUIDPreservedSymbols)
 
static void thinLTOInternalizeAndPromoteGUID (ValueInfo VI, function_ref< bool(StringRef, ValueInfo)> isExported, function_ref< bool(GlobalValue::GUID, const GlobalValueSummary *)> isPrevailing)
 
static void writeToResolutionFile (raw_ostream &OS, InputFile *Input, ArrayRef< SymbolResolution > Res)
 
static void handleNonPrevailingComdat (GlobalValue &GV, std::set< const Comdat * > &NonPrevailingComdats)
 

Variables

cl::opt< boolUseNewDbgInfoFormat
 
static cl::opt< boolDumpThinCGSCCs ("dump-thin-cg-sccs", cl::init(false), cl::Hidden, cl::desc("Dump the SCCs in the ThinLTO index's callgraph"))
 
cl::opt< boolCodeGenDataThinLTOTwoRounds
 
static cl::opt< boolllvm::LTOKeepSymbolCopies ("lto-keep-symbol-copies", cl::init(false), cl::Hidden, cl::desc("Keep copies of symbols in LTO indexing"))
 
cl::opt< boolllvm::SupportsHotColdNew
 Indicate we are linking with an allocator that supports hot/cold operator new interfaces.
 
cl::opt< boolllvm::EnableMemProfContextDisambiguation
 Enable MemProf context disambiguation for thin link.
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "lto"

Definition at line 68 of file LTO.cpp.

Function Documentation

◆ handleNonPrevailingComdat()

static void handleNonPrevailingComdat ( GlobalValue GV,
std::set< const Comdat * > &  NonPrevailingComdats 
)
static

◆ thinLTOInternalizeAndPromoteGUID()

static void thinLTOInternalizeAndPromoteGUID ( ValueInfo  VI,
function_ref< bool(StringRef, ValueInfo)>  isExported,
function_ref< bool(GlobalValue::GUID, const GlobalValueSummary *)>  isPrevailing 
)
static

◆ thinLTOResolvePrevailingGUID()

static void thinLTOResolvePrevailingGUID ( const Config C,
ValueInfo  VI,
DenseSet< GlobalValueSummary * > &  GlobalInvolvedWithAlias,
function_ref< bool(GlobalValue::GUID, const GlobalValueSummary *)>  isPrevailing,
function_ref< void(StringRef, GlobalValue::GUID, GlobalValue::LinkageTypes)>  recordNewLinkage,
const DenseSet< GlobalValue::GUID > &  GUIDPreservedSymbols 
)
static

◆ writeToResolutionFile()

static void writeToResolutionFile ( raw_ostream OS,
InputFile Input,
ArrayRef< SymbolResolution Res 
)
static

Variable Documentation

◆ CodeGenDataThinLTOTwoRounds

cl::opt<bool> CodeGenDataThinLTOTwoRounds
extern

◆ DumpThinCGSCCs

cl::opt< bool > DumpThinCGSCCs("dump-thin-cg-sccs", cl::init(false), cl::Hidden, cl::desc("Dump the SCCs in the ThinLTO index's callgraph")) ( "dump-thin-cg-sccs"  ,
cl::init(false)  ,
cl::Hidden  ,
cl::desc("Dump the SCCs in the ThinLTO index's callgraph")   
)
static

◆ UseNewDbgInfoFormat

cl::opt<bool> UseNewDbgInfoFormat
extern