BasicBlock

A basic block represents a single entry single exit section of code.

Basic blocks contain a list of instructions which form the body of the block.

Basic blocks belong to functions. They have the type of label.

Basic blocks are themselves values. However, the C API models them as LLVMBasicBlockRef.

See: llvm::BasicBlock

Alias This

lx

Members

Functions

asValue
Value asValue()

Convert a basic block instance to a value type.

firstInstr
InstructionValue firstInstr()

Obtain the first instruction in a basic block.

id
size_t id()

Uses the pointer as a unique identifier.

instructions
InstructionRange instructions()

A range over the instructions in the block

lastInstr
InstructionValue lastInstr()

Obtain the last instruction in a basic block.

parent
FunctionValue parent()

Obtain the function to which a basic block belongs.

terminator
Nullable!InstructionTerminatorValue terminator()

Obtain the terminator instruction for a basic block.

Properties

name
const(char)[] name [@property getter]

Obtain the string name of a basic block.

Meta