rocm.bindings.llvm.c.executionengine

Contents

rocm.bindings.llvm.c.executionengine#

2026-09-24

21 min read time

Applies to Linux and Windows

Advanced Micro Devices, Inc.

Attributes#

Classes#

LLVMOpaqueGenericValue

(No short description)

LLVMOpaqueExecutionEngine

(No short description)

LLVMOpaqueMCJITMemoryManager

(No short description)

LLVMMCJITCompilerOptions

(No short description)

LLVMMemoryManagerAllocateCodeSectionCallback

(No short description)

LLVMMemoryManagerAllocateDataSectionCallback

(No short description)

LLVMMemoryManagerFinalizeMemoryCallback

(No short description)

LLVMMemoryManagerDestroyCallback

(No short description)

Functions#

has_symbol(→ bool)

LLVMLinkInMCJIT()

Empty function used to force the linker to link MCJIT.

LLVMLinkInInterpreter()

Empty function used to force the linker to link the LLVM interpreter.

LLVMCreateGenericValueOfInt(Ty, N, IsSigned)

===-- Operations on generic values --------------------------------------===

LLVMCreateGenericValueOfPointer(P)

===-- Operations on generic values --------------------------------------===

LLVMCreateGenericValueOfFloat(Ty, N)

===-- Operations on generic values --------------------------------------===

LLVMGenericValueIntWidth(GenValRef)

===-- Operations on generic values --------------------------------------===

LLVMGenericValueToInt(GenVal, IsSigned)

===-- Operations on generic values --------------------------------------===

LLVMGenericValueToPointer(GenVal)

===-- Operations on generic values --------------------------------------===

LLVMGenericValueToFloat(TyRef, GenVal)

===-- Operations on generic values --------------------------------------===

LLVMDisposeGenericValue(GenVal)

===-- Operations on generic values --------------------------------------===

LLVMCreateExecutionEngineForModule(M)

===-- Operations on execution engines -----------------------------------===

LLVMCreateInterpreterForModule(M)

===-- Operations on execution engines -----------------------------------===

LLVMCreateJITCompilerForModule(M, OptLevel)

===-- Operations on execution engines -----------------------------------===

LLVMInitializeMCJITCompilerOptions(Options, SizeOfOptions)

===-- Operations on execution engines -----------------------------------===

LLVMCreateMCJITCompilerForModule(M, Options, SizeOfOptions)

Create an MCJIT execution engine for a module, with the given options.

LLVMDisposeExecutionEngine(EE)

Create an MCJIT execution engine for a module, with the given options.

LLVMRunStaticConstructors(EE)

Create an MCJIT execution engine for a module, with the given options.

LLVMRunStaticDestructors(EE)

Create an MCJIT execution engine for a module, with the given options.

LLVMRunFunctionAsMain(EE, F, ArgC, ArgV, EnvP)

Create an MCJIT execution engine for a module, with the given options.

LLVMRunFunction(EE, F, NumArgs, Args)

Create an MCJIT execution engine for a module, with the given options.

LLVMFreeMachineCodeForFunction(EE, F)

Create an MCJIT execution engine for a module, with the given options.

LLVMAddModule(EE, M)

Create an MCJIT execution engine for a module, with the given options.

LLVMRemoveModule(EE, M)

Create an MCJIT execution engine for a module, with the given options.

LLVMFindFunction(EE, Name)

Create an MCJIT execution engine for a module, with the given options.

LLVMRecompileAndRelinkFunction(EE, Fn)

Create an MCJIT execution engine for a module, with the given options.

LLVMGetExecutionEngineTargetData(EE)

Create an MCJIT execution engine for a module, with the given options.

LLVMGetExecutionEngineTargetMachine(EE)

Create an MCJIT execution engine for a module, with the given options.

LLVMAddGlobalMapping(EE, Global, Addr)

Create an MCJIT execution engine for a module, with the given options.

LLVMGetPointerToGlobal(EE, Global)

Create an MCJIT execution engine for a module, with the given options.

LLVMGetGlobalValueAddress(EE, Name)

Create an MCJIT execution engine for a module, with the given options.

LLVMGetFunctionAddress(EE, Name)

Create an MCJIT execution engine for a module, with the given options.

LLVMExecutionEngineGetErrMsg(EE)

Returns true on error, false on success.

LLVMCreateSimpleMCJITMemoryManager(Opaque, ...)

Create a simple custom MCJIT memory manager.

LLVMDisposeMCJITMemoryManager(MM)

Create a simple custom MCJIT memory manager.

LLVMCreateGDBRegistrationListener()

===-- JIT Event Listener functions -------------------------------------===

LLVMCreateIntelJITEventListener()

===-- JIT Event Listener functions -------------------------------------===

LLVMCreateOProfileJITEventListener()

===-- JIT Event Listener functions -------------------------------------===

LLVMCreatePerfJITEventListener()

===-- JIT Event Listener functions -------------------------------------===

Module Contents#

rocm.bindings.llvm.c.executionengine.has_symbol(name: str | bytes | bytearray) → bool#
rocm.bindings.llvm.c.executionengine.LLVMLinkInMCJIT()#

Empty function used to force the linker to link MCJIT.

Has no effect when called on a pre-built library (dylib interface).

C signature

void LLVMLinkInMCJIT()
rocm.bindings.llvm.c.executionengine.LLVMLinkInInterpreter()#

Empty function used to force the linker to link the LLVM interpreter.

Has no effect when called on a pre-built library (dylib interface).

C signature

void LLVMLinkInInterpreter()
class rocm.bindings.llvm.c.executionengine.LLVMOpaqueGenericValue(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

rocm.bindings.llvm.c.executionengine.LLVMGenericValueRef#
class rocm.bindings.llvm.c.executionengine.LLVMOpaqueExecutionEngine(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

rocm.bindings.llvm.c.executionengine.LLVMExecutionEngineRef#
class rocm.bindings.llvm.c.executionengine.LLVMOpaqueMCJITMemoryManager(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

rocm.bindings.llvm.c.executionengine.LLVMMCJITMemoryManagerRef#
class rocm.bindings.llvm.c.executionengine.LLVMMCJITCompilerOptions(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

OptLevel: Any#
CodeModel: Any#
NoFramePointerElim: Any#
EnableFastISel: Any#
MCJMM: Any#
static PROPERTIES() → list[str]#
static fromObj(pyobj) → Any#
static allocate(count: int = 1) → Any#
c_sizeof() → int#
as_c_void_p() → Any#
rocm.bindings.llvm.c.executionengine.LLVMCreateGenericValueOfInt(Ty, N, IsSigned)#

===– Operations on generic values ————————————–===

Args:
Ty (Pointer/object):

(undocumented)

N (int):

(undocumented)

IsSigned (int):

(undocumented)

Returns:

None: (undocumented)

C signature

LLVMGenericValueRef LLVMCreateGenericValueOfInt(LLVMTypeRef Ty, unsigned long long N, LLVMBool IsSigned)
rocm.bindings.llvm.c.executionengine.LLVMCreateGenericValueOfPointer(P)#

===– Operations on generic values ————————————–===

Args:
P (Pointer/object):

(undocumented)

Returns:

None: (undocumented)

C signature

LLVMGenericValueRef LLVMCreateGenericValueOfPointer(void * P)
rocm.bindings.llvm.c.executionengine.LLVMCreateGenericValueOfFloat(Ty, N)#

===– Operations on generic values ————————————–===

Args:
Ty (Pointer/object):

(undocumented)

N (float/int):

(undocumented)

Returns:

None: (undocumented)

C signature

LLVMGenericValueRef LLVMCreateGenericValueOfFloat(LLVMTypeRef Ty, double N)
rocm.bindings.llvm.c.executionengine.LLVMGenericValueIntWidth(GenValRef)#

===– Operations on generic values ————————————–===

Args:
GenValRef (LLVMOpaqueGenericValue/object):

(undocumented)

Returns:

int: (undocumented)

C signature

unsigned int LLVMGenericValueIntWidth(LLVMGenericValueRef GenValRef)
rocm.bindings.llvm.c.executionengine.LLVMGenericValueToInt(GenVal, IsSigned)#

===– Operations on generic values ————————————–===

Args:
GenVal (LLVMOpaqueGenericValue/object):

(undocumented)

IsSigned (int):

(undocumented)

Returns:

int: (undocumented)

C signature

unsigned long long LLVMGenericValueToInt(LLVMGenericValueRef GenVal, LLVMBool IsSigned)
rocm.bindings.llvm.c.executionengine.LLVMGenericValueToPointer(GenVal)#

===– Operations on generic values ————————————–===

Args:
GenVal (LLVMOpaqueGenericValue/object):

(undocumented)

Returns:

None: (undocumented)

C signature

void * LLVMGenericValueToPointer(LLVMGenericValueRef GenVal)
rocm.bindings.llvm.c.executionengine.LLVMGenericValueToFloat(TyRef, GenVal)#

===– Operations on generic values ————————————–===

Args:
TyRef (Pointer/object):

(undocumented)

GenVal (LLVMOpaqueGenericValue/object):

(undocumented)

Returns:

float: (undocumented)

C signature

double LLVMGenericValueToFloat(LLVMTypeRef TyRef, LLVMGenericValueRef GenVal)
rocm.bindings.llvm.c.executionengine.LLVMDisposeGenericValue(GenVal)#

===– Operations on generic values ————————————–===

Args:
GenVal (LLVMOpaqueGenericValue/object):

(undocumented)

C signature

void LLVMDisposeGenericValue(LLVMGenericValueRef GenVal)
rocm.bindings.llvm.c.executionengine.LLVMCreateExecutionEngineForModule(M)#

===– Operations on execution engines ———————————–===

Args:
M (Pointer/object):

(undocumented)

Returns:

A tuple of size 3 that contains (in that order):

C signature

LLVMBool LLVMCreateExecutionEngineForModule(LLVMExecutionEngineRef * OutEE, LLVMModuleRef M, char ** OutError)
rocm.bindings.llvm.c.executionengine.LLVMCreateInterpreterForModule(M)#

===– Operations on execution engines ———————————–===

Args:
M (Pointer/object):

(undocumented)

Returns:

A tuple of size 3 that contains (in that order):

C signature

LLVMBool LLVMCreateInterpreterForModule(LLVMExecutionEngineRef * OutInterp, LLVMModuleRef M, char ** OutError)
rocm.bindings.llvm.c.executionengine.LLVMCreateJITCompilerForModule(M, OptLevel)#

===– Operations on execution engines ———————————–===

Args:
M (Pointer/object):

(undocumented)

OptLevel (int):

(undocumented)

Returns:

A tuple of size 3 that contains (in that order):

C signature

LLVMBool LLVMCreateJITCompilerForModule(LLVMExecutionEngineRef * OutJIT, LLVMModuleRef M, unsigned int OptLevel, char ** OutError)
rocm.bindings.llvm.c.executionengine.LLVMInitializeMCJITCompilerOptions(Options, SizeOfOptions)#

===– Operations on execution engines ———————————–===

Args:
Options (LLVMMCJITCompilerOptions/object):

(undocumented)

SizeOfOptions (int):

(undocumented)

C signature

void LLVMInitializeMCJITCompilerOptions(struct LLVMMCJITCompilerOptions * Options, size_t SizeOfOptions)
rocm.bindings.llvm.c.executionengine.LLVMCreateMCJITCompilerForModule(M, Options, SizeOfOptions)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
M (Pointer/object):

(undocumented)

Options (LLVMMCJITCompilerOptions/object):

(undocumented)

SizeOfOptions (int):

(undocumented)

Returns:

A tuple of size 3 that contains (in that order):

C signature

LLVMBool LLVMCreateMCJITCompilerForModule(LLVMExecutionEngineRef * OutJIT, LLVMModuleRef M, struct LLVMMCJITCompilerOptions * Options, size_t SizeOfOptions, char ** OutError)
rocm.bindings.llvm.c.executionengine.LLVMDisposeExecutionEngine(EE)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

C signature

void LLVMDisposeExecutionEngine(LLVMExecutionEngineRef EE)
rocm.bindings.llvm.c.executionengine.LLVMRunStaticConstructors(EE)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

C signature

void LLVMRunStaticConstructors(LLVMExecutionEngineRef EE)
rocm.bindings.llvm.c.executionengine.LLVMRunStaticDestructors(EE)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

C signature

void LLVMRunStaticDestructors(LLVMExecutionEngineRef EE)
rocm.bindings.llvm.c.executionengine.LLVMRunFunctionAsMain(EE, F, ArgC, ArgV, EnvP)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

F (Pointer/object):

(undocumented)

ArgC (int):

(undocumented)

ArgV (Pointer/object):

(undocumented)

EnvP (Pointer/object):

(undocumented)

Returns:

int: (undocumented)

C signature

int LLVMRunFunctionAsMain(LLVMExecutionEngineRef EE, LLVMValueRef F, unsigned int ArgC, const char *const * ArgV, const char *const * EnvP)
rocm.bindings.llvm.c.executionengine.LLVMRunFunction(EE, F, NumArgs, Args)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

F (Pointer/object):

(undocumented)

NumArgs (int):

(undocumented)

Args (ListOfPointer/object):

(undocumented)

Returns:

None: (undocumented)

C signature

LLVMGenericValueRef LLVMRunFunction(LLVMExecutionEngineRef EE, LLVMValueRef F, unsigned int NumArgs, LLVMGenericValueRef * Args)
rocm.bindings.llvm.c.executionengine.LLVMFreeMachineCodeForFunction(EE, F)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

F (Pointer/object):

(undocumented)

C signature

void LLVMFreeMachineCodeForFunction(LLVMExecutionEngineRef EE, LLVMValueRef F)
rocm.bindings.llvm.c.executionengine.LLVMAddModule(EE, M)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

M (Pointer/object):

(undocumented)

C signature

void LLVMAddModule(LLVMExecutionEngineRef EE, LLVMModuleRef M)
rocm.bindings.llvm.c.executionengine.LLVMRemoveModule(EE, M)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

M (Pointer/object):

(undocumented)

Returns:

A tuple of size 3 that contains (in that order):

C signature

LLVMBool LLVMRemoveModule(LLVMExecutionEngineRef EE, LLVMModuleRef M, LLVMModuleRef * OutMod, char ** OutError)
rocm.bindings.llvm.c.executionengine.LLVMFindFunction(EE, Name)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Name (CStr/object):

(undocumented)

Returns:

A tuple of size 2 that contains (in that order):

C signature

LLVMBool LLVMFindFunction(LLVMExecutionEngineRef EE, const char * Name, LLVMValueRef * OutFn)
rocm.bindings.llvm.c.executionengine.LLVMRecompileAndRelinkFunction(EE, Fn)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Fn (Pointer/object):

(undocumented)

Returns:

None: (undocumented)

C signature

void * LLVMRecompileAndRelinkFunction(LLVMExecutionEngineRef EE, LLVMValueRef Fn)
rocm.bindings.llvm.c.executionengine.LLVMGetExecutionEngineTargetData(EE)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Returns:

None: (undocumented)

C signature

LLVMTargetDataRef LLVMGetExecutionEngineTargetData(LLVMExecutionEngineRef EE)
rocm.bindings.llvm.c.executionengine.LLVMGetExecutionEngineTargetMachine(EE)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Returns:

None: (undocumented)

C signature

LLVMTargetMachineRef LLVMGetExecutionEngineTargetMachine(LLVMExecutionEngineRef EE)
rocm.bindings.llvm.c.executionengine.LLVMAddGlobalMapping(EE, Global, Addr)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Global (Pointer/object):

(undocumented)

Addr (Pointer/object):

(undocumented)

C signature

void LLVMAddGlobalMapping(LLVMExecutionEngineRef EE, LLVMValueRef Global, void * Addr)
rocm.bindings.llvm.c.executionengine.LLVMGetPointerToGlobal(EE, Global)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Global (Pointer/object):

(undocumented)

Returns:

None: (undocumented)

C signature

void * LLVMGetPointerToGlobal(LLVMExecutionEngineRef EE, LLVMValueRef Global)
rocm.bindings.llvm.c.executionengine.LLVMGetGlobalValueAddress(EE, Name)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Name (CStr/object):

(undocumented)

Returns:

int: (undocumented)

C signature

uint64_t LLVMGetGlobalValueAddress(LLVMExecutionEngineRef EE, const char * Name)
rocm.bindings.llvm.c.executionengine.LLVMGetFunctionAddress(EE, Name)#

Create an MCJIT execution engine for a module, with the given options.

It is the responsibility of the caller to ensure that all fields in Options up to the given SizeOfOptions are initialized. It is correct to pass a smaller value of SizeOfOptions that omits some fields. The canonical way of using this is:

LLVMMCJITCompilerOptions options; LLVMInitializeMCJITCompilerOptions(&options, sizeof(options)); … fill in those options you care about LLVMCreateMCJITCompilerForModule(&jit, mod, &options, sizeof(options),

&error);

Note that this is also correct, though possibly suboptimal:

LLVMCreateMCJITCompilerForModule(&jit, mod, 0, 0, &error);

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Name (CStr/object):

(undocumented)

Returns:

int: (undocumented)

C signature

uint64_t LLVMGetFunctionAddress(LLVMExecutionEngineRef EE, const char * Name)
rocm.bindings.llvm.c.executionengine.LLVMExecutionEngineGetErrMsg(EE)#

Returns true on error, false on success.

If true is returned then the error message is copied to OutStr and cleared in the ExecutionEngine instance.

Args:
EE (LLVMOpaqueExecutionEngine/object):

(undocumented)

Returns:

A tuple of size 2 that contains (in that order):

C signature

LLVMBool LLVMExecutionEngineGetErrMsg(LLVMExecutionEngineRef EE, char ** OutError)
class rocm.bindings.llvm.c.executionengine.LLVMMemoryManagerAllocateCodeSectionCallback(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

class rocm.bindings.llvm.c.executionengine.LLVMMemoryManagerAllocateDataSectionCallback(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

class rocm.bindings.llvm.c.executionengine.LLVMMemoryManagerFinalizeMemoryCallback(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

class rocm.bindings.llvm.c.executionengine.LLVMMemoryManagerDestroyCallback(*args, **kwargs)#

Bases: rocm.bindings.util.types.Pointer

(No short description)

rocm.bindings.llvm.c.executionengine.LLVMCreateSimpleMCJITMemoryManager(Opaque, AllocateCodeSection, AllocateDataSection, FinalizeMemory, Destroy)#

Create a simple custom MCJIT memory manager.

This memory manager can intercept allocations in a module-oblivious way. This will return NULL if any of the passed functions are NULL.

Args:
Opaque (Pointer/object):

An opaque client object to pass back to the callbacks.

AllocateCodeSection (LLVMMemoryManagerAllocateCodeSectionCallback/object):

Allocate a block of memory for executable code.

AllocateDataSection (LLVMMemoryManagerAllocateDataSectionCallback/object):

Allocate a block of memory for data.

FinalizeMemory (LLVMMemoryManagerFinalizeMemoryCallback/object):

Set page permissions and flush cache. Return 0 on success, 1 on error.

Destroy (LLVMMemoryManagerDestroyCallback/object):

(undocumented)

Returns:

None: (undocumented)

C signature

LLVMMCJITMemoryManagerRef LLVMCreateSimpleMCJITMemoryManager(void * Opaque, LLVMMemoryManagerAllocateCodeSectionCallback AllocateCodeSection, LLVMMemoryManagerAllocateDataSectionCallback AllocateDataSection, LLVMMemoryManagerFinalizeMemoryCallback FinalizeMemory, LLVMMemoryManagerDestroyCallback Destroy)
rocm.bindings.llvm.c.executionengine.LLVMDisposeMCJITMemoryManager(MM)#

Create a simple custom MCJIT memory manager.

This memory manager can intercept allocations in a module-oblivious way. This will return NULL if any of the passed functions are NULL.

Args:
MM (LLVMOpaqueMCJITMemoryManager/object):

(undocumented)

C signature

void LLVMDisposeMCJITMemoryManager(LLVMMCJITMemoryManagerRef MM)
rocm.bindings.llvm.c.executionengine.LLVMCreateGDBRegistrationListener()#

===– JIT Event Listener functions ————————————-===

Returns:

None: (undocumented)

C signature

LLVMJITEventListenerRef LLVMCreateGDBRegistrationListener()
rocm.bindings.llvm.c.executionengine.LLVMCreateIntelJITEventListener()#

===– JIT Event Listener functions ————————————-===

Returns:

None: (undocumented)

C signature

LLVMJITEventListenerRef LLVMCreateIntelJITEventListener()
rocm.bindings.llvm.c.executionengine.LLVMCreateOProfileJITEventListener()#

===– JIT Event Listener functions ————————————-===

Returns:

None: (undocumented)

C signature

LLVMJITEventListenerRef LLVMCreateOProfileJITEventListener()
rocm.bindings.llvm.c.executionengine.LLVMCreatePerfJITEventListener()#

===– JIT Event Listener functions ————————————-===

Returns:

None: (undocumented)

C signature

LLVMJITEventListenerRef LLVMCreatePerfJITEventListener()