LLVM API Documentation

Enumerations
llvm::bitc Namespace Reference

Enumerations

enum  StandardWidths { BlockIDWidth = 8, CodeLenWidth = 4, BlockSizeWidth = 32 }
enum  FixedAbbrevIDs {
  END_BLOCK = 0, ENTER_SUBBLOCK = 1, DEFINE_ABBREV = 2, UNABBREV_RECORD = 3,
  FIRST_APPLICATION_ABBREV = 4
}
enum  StandardBlockIDs { BLOCKINFO_BLOCK_ID = 0, FIRST_APPLICATION_BLOCKID = 8 }
enum  BlockInfoCodes { BLOCKINFO_CODE_SETBID = 1, BLOCKINFO_CODE_BLOCKNAME = 2, BLOCKINFO_CODE_SETRECORDNAME = 3 }
enum  BlockIDs {
  MODULE_BLOCK_ID = FIRST_APPLICATION_BLOCKID, PARAMATTR_BLOCK_ID, PARAMATTR_GROUP_BLOCK_ID, CONSTANTS_BLOCK_ID,
  FUNCTION_BLOCK_ID, UNUSED_ID1, VALUE_SYMTAB_BLOCK_ID, METADATA_BLOCK_ID,
  METADATA_ATTACHMENT_ID, TYPE_BLOCK_ID_NEW, USELIST_BLOCK_ID
}
enum  ModuleCodes {
  MODULE_CODE_VERSION = 1, MODULE_CODE_TRIPLE = 2, MODULE_CODE_DATALAYOUT = 3, MODULE_CODE_ASM = 4,
  MODULE_CODE_SECTIONNAME = 5, MODULE_CODE_DEPLIB = 6, MODULE_CODE_GLOBALVAR = 7, MODULE_CODE_FUNCTION = 8,
  MODULE_CODE_ALIAS = 9, MODULE_CODE_PURGEVALS = 10, MODULE_CODE_GCNAME = 11, MODULE_CODE_COMDAT = 12
}
 MODULE blocks have a number of optional fields and subblocks. More...
enum  AttributeCodes { PARAMATTR_CODE_ENTRY_OLD = 1, PARAMATTR_CODE_ENTRY = 2, PARAMATTR_GRP_CODE_ENTRY = 3 }
 PARAMATTR blocks have code for defining a parameter attribute set. More...
enum  TypeCodes {
  TYPE_CODE_NUMENTRY = 1, TYPE_CODE_VOID = 2, TYPE_CODE_FLOAT = 3, TYPE_CODE_DOUBLE = 4,
  TYPE_CODE_LABEL = 5, TYPE_CODE_OPAQUE = 6, TYPE_CODE_INTEGER = 7, TYPE_CODE_POINTER = 8,
  TYPE_CODE_FUNCTION_OLD = 9, TYPE_CODE_HALF = 10, TYPE_CODE_ARRAY = 11, TYPE_CODE_VECTOR = 12,
  TYPE_CODE_X86_FP80 = 13, TYPE_CODE_FP128 = 14, TYPE_CODE_PPC_FP128 = 15, TYPE_CODE_METADATA = 16,
  TYPE_CODE_X86_MMX = 17, TYPE_CODE_STRUCT_ANON = 18, TYPE_CODE_STRUCT_NAME = 19, TYPE_CODE_STRUCT_NAMED = 20,
  TYPE_CODE_FUNCTION = 21
}
 TYPE blocks have codes for each type primitive they use. More...
enum  TypeSymtabCodes { TST_CODE_ENTRY = 1 }
enum  ValueSymtabCodes { VST_CODE_ENTRY = 1, VST_CODE_BBENTRY = 2 }
enum  MetadataCodes {
  METADATA_STRING = 1, METADATA_NAME = 4, METADATA_KIND = 6, METADATA_NODE = 8,
  METADATA_FN_NODE = 9, METADATA_NAMED_NODE = 10, METADATA_ATTACHMENT = 11
}
enum  ConstantsCodes {
  CST_CODE_SETTYPE = 1, CST_CODE_NULL = 2, CST_CODE_UNDEF = 3, CST_CODE_INTEGER = 4,
  CST_CODE_WIDE_INTEGER = 5, CST_CODE_FLOAT = 6, CST_CODE_AGGREGATE = 7, CST_CODE_STRING = 8,
  CST_CODE_CSTRING = 9, CST_CODE_CE_BINOP = 10, CST_CODE_CE_CAST = 11, CST_CODE_CE_GEP = 12,
  CST_CODE_CE_SELECT = 13, CST_CODE_CE_EXTRACTELT = 14, CST_CODE_CE_INSERTELT = 15, CST_CODE_CE_SHUFFLEVEC = 16,
  CST_CODE_CE_CMP = 17, CST_CODE_INLINEASM_OLD = 18, CST_CODE_CE_SHUFVEC_EX = 19, CST_CODE_CE_INBOUNDS_GEP = 20,
  CST_CODE_BLOCKADDRESS = 21, CST_CODE_DATA = 22, CST_CODE_INLINEASM = 23
}
enum  CastOpcodes {
  CAST_TRUNC = 0, CAST_ZEXT = 1, CAST_SEXT = 2, CAST_FPTOUI = 3,
  CAST_FPTOSI = 4, CAST_UITOFP = 5, CAST_SITOFP = 6, CAST_FPTRUNC = 7,
  CAST_FPEXT = 8, CAST_PTRTOINT = 9, CAST_INTTOPTR = 10, CAST_BITCAST = 11,
  CAST_ADDRSPACECAST = 12
}
enum  BinaryOpcodes {
  BINOP_ADD = 0, BINOP_SUB = 1, BINOP_MUL = 2, BINOP_UDIV = 3,
  BINOP_SDIV = 4, BINOP_UREM = 5, BINOP_SREM = 6, BINOP_SHL = 7,
  BINOP_LSHR = 8, BINOP_ASHR = 9, BINOP_AND = 10, BINOP_OR = 11,
  BINOP_XOR = 12
}
enum  RMWOperations {
  RMW_XCHG = 0, RMW_ADD = 1, RMW_SUB = 2, RMW_AND = 3,
  RMW_NAND = 4, RMW_OR = 5, RMW_XOR = 6, RMW_MAX = 7,
  RMW_MIN = 8, RMW_UMAX = 9, RMW_UMIN = 10
}
enum  OverflowingBinaryOperatorOptionalFlags { OBO_NO_UNSIGNED_WRAP = 0, OBO_NO_SIGNED_WRAP = 1 }
enum  PossiblyExactOperatorOptionalFlags { PEO_EXACT = 0 }
enum  AtomicOrderingCodes {
  ORDERING_NOTATOMIC = 0, ORDERING_UNORDERED = 1, ORDERING_MONOTONIC = 2, ORDERING_ACQUIRE = 3,
  ORDERING_RELEASE = 4, ORDERING_ACQREL = 5, ORDERING_SEQCST = 6
}
 Encoded AtomicOrdering values. More...
enum  AtomicSynchScopeCodes { SYNCHSCOPE_SINGLETHREAD = 0, SYNCHSCOPE_CROSSTHREAD = 1 }
 Encoded SynchronizationScope values. More...
enum  FunctionCodes {
  FUNC_CODE_DECLAREBLOCKS = 1, FUNC_CODE_INST_BINOP = 2, FUNC_CODE_INST_CAST = 3, FUNC_CODE_INST_GEP = 4,
  FUNC_CODE_INST_SELECT = 5, FUNC_CODE_INST_EXTRACTELT = 6, FUNC_CODE_INST_INSERTELT = 7, FUNC_CODE_INST_SHUFFLEVEC = 8,
  FUNC_CODE_INST_CMP = 9, FUNC_CODE_INST_RET = 10, FUNC_CODE_INST_BR = 11, FUNC_CODE_INST_SWITCH = 12,
  FUNC_CODE_INST_INVOKE = 13, FUNC_CODE_INST_UNREACHABLE = 15, FUNC_CODE_INST_PHI = 16, FUNC_CODE_INST_ALLOCA = 19,
  FUNC_CODE_INST_LOAD = 20, FUNC_CODE_INST_VAARG = 23, FUNC_CODE_INST_STORE = 24, FUNC_CODE_INST_EXTRACTVAL = 26,
  FUNC_CODE_INST_INSERTVAL = 27, FUNC_CODE_INST_CMP2 = 28, FUNC_CODE_INST_VSELECT = 29, FUNC_CODE_INST_INBOUNDS_GEP = 30,
  FUNC_CODE_INST_INDIRECTBR = 31, FUNC_CODE_DEBUG_LOC_AGAIN = 33, FUNC_CODE_INST_CALL = 34, FUNC_CODE_DEBUG_LOC = 35,
  FUNC_CODE_INST_FENCE = 36, FUNC_CODE_INST_CMPXCHG = 37, FUNC_CODE_INST_ATOMICRMW = 38, FUNC_CODE_INST_RESUME = 39,
  FUNC_CODE_INST_LANDINGPAD = 40, FUNC_CODE_INST_LOADATOMIC = 41, FUNC_CODE_INST_STOREATOMIC = 42
}
enum  UseListCodes { USELIST_CODE_DEFAULT = 1, USELIST_CODE_BB = 2 }
enum  AttributeKindCodes {
  ATTR_KIND_ALIGNMENT = 1, ATTR_KIND_ALWAYS_INLINE = 2, ATTR_KIND_BY_VAL = 3, ATTR_KIND_INLINE_HINT = 4,
  ATTR_KIND_IN_REG = 5, ATTR_KIND_MIN_SIZE = 6, ATTR_KIND_NAKED = 7, ATTR_KIND_NEST = 8,
  ATTR_KIND_NO_ALIAS = 9, ATTR_KIND_NO_BUILTIN = 10, ATTR_KIND_NO_CAPTURE = 11, ATTR_KIND_NO_DUPLICATE = 12,
  ATTR_KIND_NO_IMPLICIT_FLOAT = 13, ATTR_KIND_NO_INLINE = 14, ATTR_KIND_NON_LAZY_BIND = 15, ATTR_KIND_NO_RED_ZONE = 16,
  ATTR_KIND_NO_RETURN = 17, ATTR_KIND_NO_UNWIND = 18, ATTR_KIND_OPTIMIZE_FOR_SIZE = 19, ATTR_KIND_READ_NONE = 20,
  ATTR_KIND_READ_ONLY = 21, ATTR_KIND_RETURNED = 22, ATTR_KIND_RETURNS_TWICE = 23, ATTR_KIND_S_EXT = 24,
  ATTR_KIND_STACK_ALIGNMENT = 25, ATTR_KIND_STACK_PROTECT = 26, ATTR_KIND_STACK_PROTECT_REQ = 27, ATTR_KIND_STACK_PROTECT_STRONG = 28,
  ATTR_KIND_STRUCT_RET = 29, ATTR_KIND_SANITIZE_ADDRESS = 30, ATTR_KIND_SANITIZE_THREAD = 31, ATTR_KIND_SANITIZE_MEMORY = 32,
  ATTR_KIND_UW_TABLE = 33, ATTR_KIND_Z_EXT = 34, ATTR_KIND_BUILTIN = 35, ATTR_KIND_COLD = 36,
  ATTR_KIND_OPTIMIZE_NONE = 37, ATTR_KIND_IN_ALLOCA = 38, ATTR_KIND_NON_NULL = 39, ATTR_KIND_JUMP_TABLE = 40,
  ATTR_KIND_DEREFERENCEABLE = 41
}
enum  ComdatSelectionKindCodes {
  COMDAT_SELECTION_KIND_ANY = 1, COMDAT_SELECTION_KIND_EXACT_MATCH = 2, COMDAT_SELECTION_KIND_LARGEST = 3, COMDAT_SELECTION_KIND_NO_DUPLICATES = 4,
  COMDAT_SELECTION_KIND_SAME_SIZE = 5
}

Enumeration Type Documentation

Encoded AtomicOrdering values.

Enumerator:
ORDERING_NOTATOMIC 
ORDERING_UNORDERED 
ORDERING_MONOTONIC 
ORDERING_ACQUIRE 
ORDERING_RELEASE 
ORDERING_ACQREL 
ORDERING_SEQCST 

Definition at line 253 of file LLVMBitCodes.h.

Encoded SynchronizationScope values.

Enumerator:
SYNCHSCOPE_SINGLETHREAD 
SYNCHSCOPE_CROSSTHREAD 

Definition at line 264 of file LLVMBitCodes.h.

PARAMATTR blocks have code for defining a parameter attribute set.

Enumerator:
PARAMATTR_CODE_ENTRY_OLD 
PARAMATTR_CODE_ENTRY 
PARAMATTR_GRP_CODE_ENTRY 

Definition at line 79 of file LLVMBitCodes.h.

Enumerator:
ATTR_KIND_ALIGNMENT 
ATTR_KIND_ALWAYS_INLINE 
ATTR_KIND_BY_VAL 
ATTR_KIND_INLINE_HINT 
ATTR_KIND_IN_REG 
ATTR_KIND_MIN_SIZE 
ATTR_KIND_NAKED 
ATTR_KIND_NEST 
ATTR_KIND_NO_ALIAS 
ATTR_KIND_NO_BUILTIN 
ATTR_KIND_NO_CAPTURE 
ATTR_KIND_NO_DUPLICATE 
ATTR_KIND_NO_IMPLICIT_FLOAT 
ATTR_KIND_NO_INLINE 
ATTR_KIND_NON_LAZY_BIND 
ATTR_KIND_NO_RED_ZONE 
ATTR_KIND_NO_RETURN 
ATTR_KIND_NO_UNWIND 
ATTR_KIND_OPTIMIZE_FOR_SIZE 
ATTR_KIND_READ_NONE 
ATTR_KIND_READ_ONLY 
ATTR_KIND_RETURNED 
ATTR_KIND_RETURNS_TWICE 
ATTR_KIND_S_EXT 
ATTR_KIND_STACK_ALIGNMENT 
ATTR_KIND_STACK_PROTECT 
ATTR_KIND_STACK_PROTECT_REQ 
ATTR_KIND_STACK_PROTECT_STRONG 
ATTR_KIND_STRUCT_RET 
ATTR_KIND_SANITIZE_ADDRESS 
ATTR_KIND_SANITIZE_THREAD 
ATTR_KIND_SANITIZE_MEMORY 
ATTR_KIND_UW_TABLE 
ATTR_KIND_Z_EXT 
ATTR_KIND_BUILTIN 
ATTR_KIND_COLD 
ATTR_KIND_OPTIMIZE_NONE 
ATTR_KIND_IN_ALLOCA 
ATTR_KIND_NON_NULL 
ATTR_KIND_JUMP_TABLE 
ATTR_KIND_DEREFERENCEABLE 

Definition at line 337 of file LLVMBitCodes.h.

BinaryOpcodes - These are values used in the bitcode files to encode which binop a CST_CODE_CE_BINOP or a XXX refers to. The values of these enums have no fixed relation to the LLVM IR enum values. Changing these will break compatibility with old files.

Enumerator:
BINOP_ADD 
BINOP_SUB 
BINOP_MUL 
BINOP_UDIV 
BINOP_SDIV 
BINOP_UREM 
BINOP_SREM 
BINOP_SHL 
BINOP_LSHR 
BINOP_ASHR 
BINOP_AND 
BINOP_OR 
BINOP_XOR 

Definition at line 206 of file LLVMBitCodes.h.

Enumerator:
MODULE_BLOCK_ID 
PARAMATTR_BLOCK_ID 
PARAMATTR_GROUP_BLOCK_ID 
CONSTANTS_BLOCK_ID 
FUNCTION_BLOCK_ID 
UNUSED_ID1 
VALUE_SYMTAB_BLOCK_ID 
METADATA_BLOCK_ID 
METADATA_ATTACHMENT_ID 
TYPE_BLOCK_ID_NEW 
USELIST_BLOCK_ID 

Definition at line 26 of file LLVMBitCodes.h.

BlockInfoCodes - The blockinfo block contains metadata about user-defined blocks.

Enumerator:
BLOCKINFO_CODE_SETBID 
BLOCKINFO_CODE_BLOCKNAME 
BLOCKINFO_CODE_SETRECORDNAME 

Definition at line 70 of file BitCodes.h.

CastOpcodes - These are values used in the bitcode files to encode which cast a CST_CODE_CE_CAST or a XXX refers to. The values of these enums have no fixed relation to the LLVM IR enum values. Changing these will break compatibility with old files.

Enumerator:
CAST_TRUNC 
CAST_ZEXT 
CAST_SEXT 
CAST_FPTOUI 
CAST_FPTOSI 
CAST_UITOFP 
CAST_SITOFP 
CAST_FPTRUNC 
CAST_FPEXT 
CAST_PTRTOINT 
CAST_INTTOPTR 
CAST_BITCAST 
CAST_ADDRSPACECAST 

Definition at line 186 of file LLVMBitCodes.h.

Enumerator:
COMDAT_SELECTION_KIND_ANY 
COMDAT_SELECTION_KIND_EXACT_MATCH 
COMDAT_SELECTION_KIND_LARGEST 
COMDAT_SELECTION_KIND_NO_DUPLICATES 
COMDAT_SELECTION_KIND_SAME_SIZE 

Definition at line 382 of file LLVMBitCodes.h.

Enumerator:
CST_CODE_SETTYPE 
CST_CODE_NULL 
CST_CODE_UNDEF 
CST_CODE_INTEGER 
CST_CODE_WIDE_INTEGER 
CST_CODE_FLOAT 
CST_CODE_AGGREGATE 
CST_CODE_STRING 
CST_CODE_CSTRING 
CST_CODE_CE_BINOP 
CST_CODE_CE_CAST 
CST_CODE_CE_GEP 
CST_CODE_CE_SELECT 
CST_CODE_CE_EXTRACTELT 
CST_CODE_CE_INSERTELT 
CST_CODE_CE_SHUFFLEVEC 
CST_CODE_CE_CMP 
CST_CODE_INLINEASM_OLD 
CST_CODE_CE_SHUFVEC_EX 
CST_CODE_CE_INBOUNDS_GEP 
CST_CODE_BLOCKADDRESS 
CST_CODE_DATA 
CST_CODE_INLINEASM 

Definition at line 154 of file LLVMBitCodes.h.

Enumerator:
END_BLOCK 
ENTER_SUBBLOCK 
DEFINE_ABBREV 

DEFINE_ABBREV - Defines an abbrev for the current block. It consists of a vbr5 for # operand infos. Each operand info is emitted with a single bit to indicate if it is a literal encoding. If so, the value is emitted with a vbr8. If not, the encoding is emitted as 3 bits followed by the info value as a vbr5 if needed.

UNABBREV_RECORD 
FIRST_APPLICATION_ABBREV 

Definition at line 37 of file BitCodes.h.

Enumerator:
FUNC_CODE_DECLAREBLOCKS 
FUNC_CODE_INST_BINOP 
FUNC_CODE_INST_CAST 
FUNC_CODE_INST_GEP 
FUNC_CODE_INST_SELECT 
FUNC_CODE_INST_EXTRACTELT 
FUNC_CODE_INST_INSERTELT 
FUNC_CODE_INST_SHUFFLEVEC 
FUNC_CODE_INST_CMP 
FUNC_CODE_INST_RET 
FUNC_CODE_INST_BR 
FUNC_CODE_INST_SWITCH 
FUNC_CODE_INST_INVOKE 
FUNC_CODE_INST_UNREACHABLE 
FUNC_CODE_INST_PHI 
FUNC_CODE_INST_ALLOCA 
FUNC_CODE_INST_LOAD 
FUNC_CODE_INST_VAARG 
FUNC_CODE_INST_STORE 
FUNC_CODE_INST_EXTRACTVAL 
FUNC_CODE_INST_INSERTVAL 
FUNC_CODE_INST_CMP2 
FUNC_CODE_INST_VSELECT 
FUNC_CODE_INST_INBOUNDS_GEP 
FUNC_CODE_INST_INDIRECTBR 
FUNC_CODE_DEBUG_LOC_AGAIN 
FUNC_CODE_INST_CALL 
FUNC_CODE_DEBUG_LOC 
FUNC_CODE_INST_FENCE 
FUNC_CODE_INST_CMPXCHG 
FUNC_CODE_INST_ATOMICRMW 
FUNC_CODE_INST_RESUME 
FUNC_CODE_INST_LANDINGPAD 
FUNC_CODE_INST_LOADATOMIC 
FUNC_CODE_INST_STOREATOMIC 

Definition at line 271 of file LLVMBitCodes.h.

Enumerator:
METADATA_STRING 
METADATA_NAME 
METADATA_KIND 
METADATA_NODE 
METADATA_FN_NODE 
METADATA_NAMED_NODE 
METADATA_ATTACHMENT 

Definition at line 138 of file LLVMBitCodes.h.

MODULE blocks have a number of optional fields and subblocks.

Enumerator:
MODULE_CODE_VERSION 
MODULE_CODE_TRIPLE 
MODULE_CODE_DATALAYOUT 
MODULE_CODE_ASM 
MODULE_CODE_SECTIONNAME 
MODULE_CODE_DEPLIB 
MODULE_CODE_GLOBALVAR 
MODULE_CODE_FUNCTION 
MODULE_CODE_ALIAS 
MODULE_CODE_PURGEVALS 
MODULE_CODE_GCNAME 
MODULE_CODE_COMDAT 

Definition at line 50 of file LLVMBitCodes.h.

OverflowingBinaryOperatorOptionalFlags - Flags for serializing OverflowingBinaryOperator's SubclassOptionalData contents.

Enumerator:
OBO_NO_UNSIGNED_WRAP 
OBO_NO_SIGNED_WRAP 

Definition at line 241 of file LLVMBitCodes.h.

PossiblyExactOperatorOptionalFlags - Flags for serializing PossiblyExactOperator's SubclassOptionalData contents.

Enumerator:
PEO_EXACT 

Definition at line 248 of file LLVMBitCodes.h.

These are values used in the bitcode files to encode AtomicRMW operations. The values of these enums have no fixed relation to the LLVM IR enum values. Changing these will break compatibility with old files.

Enumerator:
RMW_XCHG 
RMW_ADD 
RMW_SUB 
RMW_AND 
RMW_NAND 
RMW_OR 
RMW_XOR 
RMW_MAX 
RMW_MIN 
RMW_UMAX 
RMW_UMIN 

Definition at line 225 of file LLVMBitCodes.h.

StandardBlockIDs - All bitcode files can optionally include a BLOCKINFO block, which contains metadata about other blocks in the file.

Enumerator:
BLOCKINFO_BLOCK_ID 

BLOCKINFO_BLOCK is used to define metadata about blocks, for example, standard abbrevs that should be available to all blocks of a specified ID.

FIRST_APPLICATION_BLOCKID 

Definition at line 58 of file BitCodes.h.

Enumerator:
BlockIDWidth 
CodeLenWidth 
BlockSizeWidth 

Definition at line 29 of file BitCodes.h.

TYPE blocks have codes for each type primitive they use.

Enumerator:
TYPE_CODE_NUMENTRY 
TYPE_CODE_VOID 
TYPE_CODE_FLOAT 
TYPE_CODE_DOUBLE 
TYPE_CODE_LABEL 
TYPE_CODE_OPAQUE 
TYPE_CODE_INTEGER 
TYPE_CODE_POINTER 
TYPE_CODE_FUNCTION_OLD 
TYPE_CODE_HALF 
TYPE_CODE_ARRAY 
TYPE_CODE_VECTOR 
TYPE_CODE_X86_FP80 
TYPE_CODE_FP128 
TYPE_CODE_PPC_FP128 
TYPE_CODE_METADATA 
TYPE_CODE_X86_MMX 
TYPE_CODE_STRUCT_ANON 
TYPE_CODE_STRUCT_NAME 
TYPE_CODE_STRUCT_NAMED 
TYPE_CODE_FUNCTION 

Definition at line 89 of file LLVMBitCodes.h.

Enumerator:
TST_CODE_ENTRY 

Definition at line 128 of file LLVMBitCodes.h.

Enumerator:
USELIST_CODE_DEFAULT 
USELIST_CODE_BB 

Definition at line 332 of file LLVMBitCodes.h.

Enumerator:
VST_CODE_ENTRY 
VST_CODE_BBENTRY 

Definition at line 133 of file LLVMBitCodes.h.