LLVM  4.0.0
Modules | Functions
Function values

Functions in this group operate on LLVMValueRef instances that correspond to llvm::Function instances. More...

Collaboration diagram for Function values:

Modules

 Function Parameters
 Functions in this group relate to arguments/parameters on functions.
 

Functions

void LLVMDeleteFunction (LLVMValueRef Fn)
 Remove a function from its containing module and deletes it. More...
 
LLVMBool LLVMHasPersonalityFn (LLVMValueRef Fn)
 Check whether the given function has a personality function. More...
 
LLVMValueRef LLVMGetPersonalityFn (LLVMValueRef Fn)
 Obtain the personality function attached to the function. More...
 
void LLVMSetPersonalityFn (LLVMValueRef Fn, LLVMValueRef PersonalityFn)
 Set the personality function attached to the function. More...
 
unsigned LLVMGetIntrinsicID (LLVMValueRef Fn)
 Obtain the ID number from a function instance. More...
 
unsigned LLVMGetFunctionCallConv (LLVMValueRef Fn)
 Obtain the calling function of a function. More...
 
void LLVMSetFunctionCallConv (LLVMValueRef Fn, unsigned CC)
 Set the calling convention of a function. More...
 
const char * LLVMGetGC (LLVMValueRef Fn)
 Obtain the name of the garbage collector to use during code generation. More...
 
void LLVMSetGC (LLVMValueRef Fn, const char *Name)
 Define the garbage collector to use during code generation. More...
 
void LLVMAddAttributeAtIndex (LLVMValueRef F, LLVMAttributeIndex Idx, LLVMAttributeRef A)
 Add an attribute to a function. More...
 
unsigned LLVMGetAttributeCountAtIndex (LLVMValueRef F, LLVMAttributeIndex Idx)
 
void LLVMGetAttributesAtIndex (LLVMValueRef F, LLVMAttributeIndex Idx, LLVMAttributeRef *Attrs)
 
LLVMAttributeRef LLVMGetEnumAttributeAtIndex (LLVMValueRef F, LLVMAttributeIndex Idx, unsigned KindID)
 
LLVMAttributeRef LLVMGetStringAttributeAtIndex (LLVMValueRef F, LLVMAttributeIndex Idx, const char *K, unsigned KLen)
 
void LLVMRemoveEnumAttributeAtIndex (LLVMValueRef F, LLVMAttributeIndex Idx, unsigned KindID)
 
void LLVMRemoveStringAttributeAtIndex (LLVMValueRef F, LLVMAttributeIndex Idx, const char *K, unsigned KLen)
 
void LLVMAddTargetDependentFunctionAttr (LLVMValueRef Fn, const char *A, const char *V)
 Add a target-dependent attribute to a function. More...
 

Detailed Description

Functions in this group operate on LLVMValueRef instances that correspond to llvm::Function instances.

See Also
llvm::Function

Function Documentation

void LLVMAddAttributeAtIndex ( LLVMValueRef  F,
LLVMAttributeIndex  Idx,
LLVMAttributeRef  A 
)

Add an attribute to a function.

See Also
llvm::Function::addAttribute()

Definition at line 1841 of file Core.cpp.

References F, and llvm::unwrap().

void LLVMAddTargetDependentFunctionAttr ( LLVMValueRef  Fn,
const char *  A,
const char *  V 
)
void LLVMDeleteFunction ( LLVMValueRef  Fn)

Remove a function from its containing module and deletes it.

See Also
llvm::Function::eraseFromParent()

Definition at line 1797 of file Core.cpp.

unsigned LLVMGetAttributeCountAtIndex ( LLVMValueRef  F,
LLVMAttributeIndex  Idx 
)

Definition at line 1846 of file Core.cpp.

References llvm::AttributeSetNode::get(), and llvm::Intrinsic::getAttributes().

void LLVMGetAttributesAtIndex ( LLVMValueRef  F,
LLVMAttributeIndex  Idx,
LLVMAttributeRef Attrs 
)
LLVMAttributeRef LLVMGetEnumAttributeAtIndex ( LLVMValueRef  F,
LLVMAttributeIndex  Idx,
unsigned  KindID 
)

Definition at line 1862 of file Core.cpp.

References llvm::wrap().

unsigned LLVMGetFunctionCallConv ( LLVMValueRef  Fn)

Obtain the calling function of a function.

The returned value corresponds to the LLVMCallConv enumeration.

See Also
llvm::Function::getCallingConv()

Definition at line 1819 of file Core.cpp.

const char* LLVMGetGC ( LLVMValueRef  Fn)

Obtain the name of the garbage collector to use during code generation.

See Also
llvm::Function::getGC()

Definition at line 1828 of file Core.cpp.

References F, llvm::Function::getGC(), and llvm::Function::hasGC().

unsigned LLVMGetIntrinsicID ( LLVMValueRef  Fn)

Obtain the ID number from a function instance.

See Also
llvm::Function::getIntrinsicID()

Definition at line 1813 of file Core.cpp.

References F, and llvm::unwrap().

LLVMValueRef LLVMGetPersonalityFn ( LLVMValueRef  Fn)

Obtain the personality function attached to the function.

See Also
llvm::Function::getPersonalityFn()

Definition at line 1805 of file Core.cpp.

References llvm::wrap().

LLVMAttributeRef LLVMGetStringAttributeAtIndex ( LLVMValueRef  F,
LLVMAttributeIndex  Idx,
const char *  K,
unsigned  KLen 
)

Definition at line 1869 of file Core.cpp.

References llvm::wrap().

LLVMBool LLVMHasPersonalityFn ( LLVMValueRef  Fn)

Check whether the given function has a personality function.

See Also
llvm::Function::hasPersonalityFn()

Definition at line 1801 of file Core.cpp.

void LLVMRemoveEnumAttributeAtIndex ( LLVMValueRef  F,
LLVMAttributeIndex  Idx,
unsigned  KindID 
)

Definition at line 1875 of file Core.cpp.

References F.

void LLVMRemoveStringAttributeAtIndex ( LLVMValueRef  F,
LLVMAttributeIndex  Idx,
const char *  K,
unsigned  KLen 
)

Definition at line 1880 of file Core.cpp.

References F.

void LLVMSetFunctionCallConv ( LLVMValueRef  Fn,
unsigned  CC 
)

Set the calling convention of a function.

See Also
llvm::Function::setCallingConv()
Parameters
FnFunction to operate on
CCLLVMCallConv to set calling convention to

Definition at line 1823 of file Core.cpp.

void LLVMSetGC ( LLVMValueRef  Fn,
const char *  Name 
)

Define the garbage collector to use during code generation.

See Also
llvm::Function::setGC()

Definition at line 1833 of file Core.cpp.

References llvm::Function::clearGC(), F, and llvm::Function::setGC().

void LLVMSetPersonalityFn ( LLVMValueRef  Fn,
LLVMValueRef  PersonalityFn 
)

Set the personality function attached to the function.

See Also
llvm::Function::setPersonalityFn()

Definition at line 1809 of file Core.cpp.