LLVM  4.0.0
Public Types | Public Member Functions | List of all members
llvm::FunctionImporter Class Reference

The function importer is automatically importing function from other modules based on the provided summary informations. More...

#include <FunctionImport.h>

Public Types

typedef std::map
< GlobalValue::GUID, unsigned
FunctionsToImportTy
 Set of functions to import from a source module. More...
 
typedef StringMap
< FunctionsToImportTy
ImportMapTy
 The map contains an entry for every module to import from, the key being the module identifier to pass to the ModuleLoader. More...
 
typedef std::unordered_set
< GlobalValue::GUID
ExportSetTy
 The set contains an entry for every global value the module exports. More...
 
typedef std::function
< Expected< std::unique_ptr
< Module > >StringRef
Identifier)> 
ModuleLoaderTy
 A function of this type is used to load modules referenced by the index. More...
 

Public Member Functions

 FunctionImporter (const ModuleSummaryIndex &Index, ModuleLoaderTy ModuleLoader)
 Create a Function Importer. More...
 
Expected< boolimportFunctions (Module &M, const ImportMapTy &ImportList, bool ForceImportReferencedDiscardableSymbols=false)
 Import functions in Module M based on the supplied import list. More...
 

Detailed Description

The function importer is automatically importing function from other modules based on the provided summary informations.

Definition at line 31 of file FunctionImport.h.

Member Typedef Documentation

The set contains an entry for every global value the module exports.

Definition at line 45 of file FunctionImport.h.

Set of functions to import from a source module.

Each entry is a map containing all the functions to import for a source module. The keys is the GUID identifying a function to import, and the value is the threshold applied when deciding to import it.

Definition at line 37 of file FunctionImport.h.

The map contains an entry for every module to import from, the key being the module identifier to pass to the ModuleLoader.

The value is the set of functions to import.

Definition at line 42 of file FunctionImport.h.

A function of this type is used to load modules referenced by the index.

Definition at line 49 of file FunctionImport.h.

Constructor & Destructor Documentation

llvm::FunctionImporter::FunctionImporter ( const ModuleSummaryIndex Index,
ModuleLoaderTy  ModuleLoader 
)
inline

Create a Function Importer.

Definition at line 52 of file FunctionImport.h.

Member Function Documentation

Expected< bool > FunctionImporter::importFunctions ( Module M,
const ImportMapTy ImportList,
bool  ForceImportReferencedDiscardableSymbols = false 
)

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