LLVM 20.0.0git
Public Types | Public Member Functions | List of all members
llvm::FunctionImporter::ImportMapTy Class Reference

The map maintains the list of imports. More...

#include "llvm/Transforms/IPO/FunctionImport.h"

Public Types

enum class  AddDefinitionStatus { NoChange , Inserted , ChangedToDefinition }
 
using ImportMapTyImpl = DenseMap< StringRef, FunctionsToImportTy >
 

Public Member Functions

AddDefinitionStatus addDefinition (StringRef FromModule, GlobalValue::GUID GUID)
 
void maybeAddDeclaration (StringRef FromModule, GlobalValue::GUID GUID)
 
void addGUID (StringRef FromModule, GlobalValue::GUID GUID, GlobalValueSummary::ImportKind ImportKind)
 
const ImportMapTyImplgetImportMap () const
 

Detailed Description

The map maintains the list of imports.

Conceptually, it is a collection of tuples of the form:

(The name of the source module, GUID, Definition/Declaration)

The name of the source module is the module identifier to pass to the ModuleLoader. The module identifier strings must be owned elsewhere, typically by the in-memory ModuleSummaryIndex the importing decisions are made from (the module path for each summary is owned by the index's module path string table).

Definition at line 109 of file FunctionImport.h.

Member Typedef Documentation

◆ ImportMapTyImpl

Definition at line 111 of file FunctionImport.h.

Member Enumeration Documentation

◆ AddDefinitionStatus

Enumerator
NoChange 
Inserted 
ChangedToDefinition 

Definition at line 113 of file FunctionImport.h.

Member Function Documentation

◆ addDefinition()

FunctionImporter::ImportMapTy::AddDefinitionStatus FunctionImporter::ImportMapTy::addDefinition ( StringRef  FromModule,
GlobalValue::GUID  GUID 
)

◆ addGUID()

void llvm::FunctionImporter::ImportMapTy::addGUID ( StringRef  FromModule,
GlobalValue::GUID  GUID,
GlobalValueSummary::ImportKind  ImportKind 
)
inline

◆ getImportMap()

const ImportMapTyImpl & llvm::FunctionImporter::ImportMapTy::getImportMap ( ) const
inline

◆ maybeAddDeclaration()

void FunctionImporter::ImportMapTy::maybeAddDeclaration ( StringRef  FromModule,
GlobalValue::GUID  GUID 
)

Definition at line 350 of file FunctionImport.cpp.

References llvm::GlobalValueSummary::Declaration.

Referenced by addGUID(), and computeImportForFunction().


The documentation for this class was generated from the following files: