Table of Contents

Class Function

Namespace
Ubiquity.NET.Llvm.Values
Assembly
Ubiquity.NET.Llvm.dll

LLVM Function definition

public class Function : GlobalObject, IEquatable<Value>, IFunctionAttributeAccessor
Inheritance
Function
Implements
Inherited Members
Extension Methods

Properties

BasicBlocks

Gets the basic blocks for the function

CallingConvention

Gets or sets the Calling convention for the method

DISubProgram

Gets or sets the debug information for this function

EntryBlock

Gets the Entry block for this function

GcName

Gets or sets the Garbage collection engine name that this function is generated to work with

IntrinsicId

Gets the LLVM intrinsicID for the method

IsVarArg

Gets a value indicating whether the method signature accepts variable arguments

Parameters

Gets the parameters for the function including any method definition specific attributes (i.e. ByVal)

PersonalityFunction

Gets or sets the personality function for exception handling in this function

ReturnType

Gets the return type of the function

Signature

Gets the signature type of the function

Methods

AddAttributeAtIndex(FunctionAttributeIndex, AttributeValue)

Adds an AttributeValue at a specified index

AppendBasicBlock(LazyEncodedString)

Creates an appends a new basic block to a function

AppendBasicBlock(BasicBlock)

Appends a new basic block to a function

EraseFromParent()

Removes this function from the parent module

FindOrCreateNamedBlock(LazyEncodedString)

Retrieves or creates block by name

GetAttributeAtIndex(FunctionAttributeIndex, uint)

Gets a specific attribute at a given index

GetAttributeAtIndex(FunctionAttributeIndex, LazyEncodedString)

Gets a named attribute at a given index

GetAttributeCountAtIndex(FunctionAttributeIndex)

Gets the count of attributes on a given index

GetAttributesAtIndex(FunctionAttributeIndex)

Gets the attributes on a given index

InsertBasicBlock(LazyEncodedString, BasicBlock)

Inserts a basic block before another block in the function

PrependBasicBlock(LazyEncodedString)

Add a new basic block to the beginning of a function

RemoveAttributeAtIndex(FunctionAttributeIndex, uint)

Removes an AttributeInfo at a specified index

RemoveAttributeAtIndex(FunctionAttributeIndex, LazyEncodedString)

Removes a named attribute at a specified index

TryRunPasses(params LazyEncodedString[])

Tries running the specified passes on this function

TryRunPasses(PassBuilderOptions, params LazyEncodedString[])

Tries running the specified passes on this function

TryRunPasses(TargetMachine, PassBuilderOptions, params LazyEncodedString[])

Tries running the specified passes on this function

Verify()

Verifies the function is valid and all blocks properly terminated

Verify(out string)

Verifies the function without throwing an exception