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

#include <IRMover.h>

Classes

class  IdentifiedStructTypeSet
 

Public Types

typedef std::function< void(GlobalValue &)> ValueAdder
 

Public Member Functions

 IRMover (Module &M)
 
Error move (std::unique_ptr< Module > Src, ArrayRef< GlobalValue * > ValuesToLink, std::function< void(GlobalValue &GV, ValueAdder Add)> AddLazyFor, bool LinkModuleInlineAsm, bool IsPerformingImport)
 Move in the provide values in ValuesToLink from Src. More...
 
ModulegetModule ()
 

Detailed Description

Definition at line 26 of file IRMover.h.

Member Typedef Documentation

Definition at line 65 of file IRMover.h.

Constructor & Destructor Documentation

IRMover::IRMover ( Module M)

Member Function Documentation

Module& llvm::IRMover::getModule ( )
inline

Definition at line 83 of file IRMover.h.

Error IRMover::move ( std::unique_ptr< Module Src,
ArrayRef< GlobalValue * >  ValuesToLink,
std::function< void(GlobalValue &GV, ValueAdder Add)>  AddLazyFor,
bool  LinkModuleInlineAsm,
bool  IsPerformingImport 
)

Move in the provide values in ValuesToLink from Src.

  • AddLazyFor is a call back that the IRMover will call when a global value is referenced by one of the ValuesToLink (transitively) but was not present in ValuesToLink. The GlobalValue and a ValueAdder callback are passed as an argument, and the callback is expected to be called if the GlobalValue needs to be added to the ValuesToLink and linked.
  • LinkModuleInlineAsm is true if the ModuleInlineAsm string in Src should be linked with (concatenated into) the ModuleInlineAsm string for the destination module. It should be true for full LTO, but not when importing for ThinLTO, otherwise we can have duplicate symbols.
  • IsPerformingImport is true when this IR link is to perform ThinLTO function importing from Src.

Definition at line 1436 of file IRMover.cpp.

References llvm::Module::dropTriviallyDeadConstantArrays(), and E.


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