Class LLVMObject
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classContains the function pointers loaded fromLLVMCore.getLibrary(). -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryTypestatic final intLLVMBinaryType -
Method Summary
Modifier and TypeMethodDescriptionstatic longLLVMBinaryCopyMemoryBuffer(long BR) Retrieves a copy of the memory buffer associated with this object file.static intLLVMBinaryGetType(long BR) Retrieve the specific type of a binary.static longLLVMCreateBinary(long MemBuf, long Context, org.lwjgl.PointerBuffer ErrorMessage) Create a binary file from the given memory buffer.static longLLVMCreateObjectFile(long MemBuf) Deprecated: useCreateBinaryinstead.static voidLLVMDisposeBinary(long BR) Dispose of a binary file.static voidLLVMDisposeObjectFile(long ObjectFile) Deprecated: useDisposeBinaryinstead.static voidLLVMDisposeRelocationIterator(long RI) static voidLLVMDisposeSectionIterator(long SI) static voidLLVMDisposeSymbolIterator(long SI) static longLLVMGetRelocationOffset(long RI) static longLLVMGetRelocations(long Section) static longLLVMGetRelocationSymbol(long RI) static longLLVMGetRelocationType(long RI) static @Nullable StringLLVMGetRelocationTypeName(long RI) static @Nullable StringLLVMGetRelocationValueString(long RI) static longLLVMGetSectionAddress(long SI) static booleanLLVMGetSectionContainsSymbol(long SI, long Sym) static @Nullable StringLLVMGetSectionContents(long SI) static @Nullable StringLLVMGetSectionName(long SI) static longLLVMGetSections(long ObjectFile) Deprecated: UseObjectFileCopySectionIteratorinstead.static longLLVMGetSectionSize(long SI) static longLLVMGetSymbolAddress(long SI) static @Nullable StringLLVMGetSymbolName(long SI) static longLLVMGetSymbols(long ObjectFile) Deprecated: UseObjectFileCopySymbolIteratorinstead.static longLLVMGetSymbolSize(long SI) static booleanLLVMIsRelocationIteratorAtEnd(long Section, long RI) static booleanLLVMIsSectionIteratorAtEnd(long ObjectFile, long SI) Deprecated: UseObjectFileIsSectionIteratorAtEndinstead.static booleanLLVMIsSymbolIteratorAtEnd(long ObjectFile, long SI) Deprecated: UseObjectFileIsSymbolIteratorAtEndinstead.static longLLVMMachOUniversalBinaryCopyObjectForArch(long BR, CharSequence Arch, org.lwjgl.PointerBuffer ErrorMessage) For a Mach-O universal binary file, retrieves the object file corresponding to the given architecture if it is present as a slice.static longLLVMMachOUniversalBinaryCopyObjectForArch(long BR, ByteBuffer Arch, org.lwjgl.PointerBuffer ErrorMessage) For a Mach-O universal binary file, retrieves the object file corresponding to the given architecture if it is present as a slice.static voidLLVMMoveToContainingSection(long Sect, long Sym) static voidLLVMMoveToNextRelocation(long RI) static voidLLVMMoveToNextSection(long SI) static voidLLVMMoveToNextSymbol(long SI) static longLLVMObjectFileCopySectionIterator(long BR) Retrieve a copy of the section iterator for this object file.static longLLVMObjectFileCopySymbolIterator(long BR) Retrieve a copy of the symbol iterator for this object file.static booleanLLVMObjectFileIsSectionIteratorAtEnd(long BR, long SI) Returns whether the given section iterator is at the end.static booleanLLVMObjectFileIsSymbolIteratorAtEnd(long BR, long SI) Returns whether the given symbol iterator is at the end.static longnLLVMCreateBinary(long MemBuf, long Context, long ErrorMessage) Unsafe version of:CreateBinarystatic longnLLVMGetRelocationTypeName(long RI) static longnLLVMGetRelocationValueString(long RI) static longnLLVMGetSectionContents(long SI) static longnLLVMGetSectionName(long SI) static longnLLVMGetSymbolName(long SI) static longnLLVMMachOUniversalBinaryCopyObjectForArch(long BR, long Arch, long ArchLen, long ErrorMessage) Unsafe version of:MachOUniversalBinaryCopyObjectForArch
-
Field Details
-
LLVMBinaryTypeArchive
public static final int LLVMBinaryTypeArchiveLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeMachOUniversalBinary
public static final int LLVMBinaryTypeMachOUniversalBinaryLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeCOFFImportFile
public static final int LLVMBinaryTypeCOFFImportFileLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeIR
public static final int LLVMBinaryTypeIRLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeWinRes
public static final int LLVMBinaryTypeWinResLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeCOFF
public static final int LLVMBinaryTypeCOFFLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeELF32L
public static final int LLVMBinaryTypeELF32LLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeELF32B
public static final int LLVMBinaryTypeELF32BLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeELF64L
public static final int LLVMBinaryTypeELF64LLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeELF64B
public static final int LLVMBinaryTypeELF64BLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeMachO32L
public static final int LLVMBinaryTypeMachO32LLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeMachO32B
public static final int LLVMBinaryTypeMachO32BLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeMachO64L
public static final int LLVMBinaryTypeMachO64LLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeMachO64B
public static final int LLVMBinaryTypeMachO64BLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeWasm
public static final int LLVMBinaryTypeWasmLLVMBinaryTypeEnum values:
- See Also:
-
LLVMBinaryTypeOffload
public static final int LLVMBinaryTypeOffloadLLVMBinaryTypeEnum values:
- See Also:
-
-
Method Details
-
nLLVMCreateBinary
public static long nLLVMCreateBinary(long MemBuf, long Context, long ErrorMessage) Unsafe version of:CreateBinary -
LLVMCreateBinary
public static long LLVMCreateBinary(long MemBuf, long Context, org.lwjgl.PointerBuffer ErrorMessage) Create a binary file from the given memory buffer.The exact type of the binary file will be inferred automatically, and the appropriate implementation selected. The context may be
NULLexcept if the resulting file is an LLVM IR file.The memory buffer is not consumed by this function. It is the responsibilty of the caller to free it with
DisposeMemoryBuffer.If
NULLis returned, theErrorMessageparameter is populated with the error's description. It is then the caller's responsibility to free this message by callingDisposeMessage. -
LLVMDisposeBinary
public static void LLVMDisposeBinary(long BR) Dispose of a binary file.The binary file does not own its backing buffer. It is the responsibilty of the caller to free it with
DisposeMemoryBuffer. -
LLVMBinaryCopyMemoryBuffer
public static long LLVMBinaryCopyMemoryBuffer(long BR) Retrieves a copy of the memory buffer associated with this object file.The returned buffer is merely a shallow copy and does not own the actual backing buffer of the binary. Nevertheless, it is the responsibility of the caller to free it with
DisposeMemoryBuffer. -
LLVMBinaryGetType
public static int LLVMBinaryGetType(long BR) Retrieve the specific type of a binary. -
nLLVMMachOUniversalBinaryCopyObjectForArch
public static long nLLVMMachOUniversalBinaryCopyObjectForArch(long BR, long Arch, long ArchLen, long ErrorMessage) Unsafe version of:MachOUniversalBinaryCopyObjectForArch -
LLVMMachOUniversalBinaryCopyObjectForArch
public static long LLVMMachOUniversalBinaryCopyObjectForArch(long BR, ByteBuffer Arch, org.lwjgl.PointerBuffer ErrorMessage) For a Mach-O universal binary file, retrieves the object file corresponding to the given architecture if it is present as a slice.If
NULLis returned, theErrorMessageparameter is populated with the error's description. It is then the caller's responsibility to free this message by callingDisposeMessage.It is the responsiblity of the caller to free the returned object file by calling
DisposeBinary. -
LLVMMachOUniversalBinaryCopyObjectForArch
public static long LLVMMachOUniversalBinaryCopyObjectForArch(long BR, CharSequence Arch, org.lwjgl.PointerBuffer ErrorMessage) For a Mach-O universal binary file, retrieves the object file corresponding to the given architecture if it is present as a slice.If
NULLis returned, theErrorMessageparameter is populated with the error's description. It is then the caller's responsibility to free this message by callingDisposeMessage.It is the responsiblity of the caller to free the returned object file by calling
DisposeBinary. -
LLVMObjectFileCopySectionIterator
public static long LLVMObjectFileCopySectionIterator(long BR) Retrieve a copy of the section iterator for this object file.If there are no sections, the result is
NULL.The returned iterator is merely a shallow copy. Nevertheless, it is the responsibility of the caller to free it with
DisposeSectionIterator. -
LLVMObjectFileIsSectionIteratorAtEnd
public static boolean LLVMObjectFileIsSectionIteratorAtEnd(long BR, long SI) Returns whether the given section iterator is at the end. -
LLVMObjectFileCopySymbolIterator
public static long LLVMObjectFileCopySymbolIterator(long BR) Retrieve a copy of the symbol iterator for this object file.If there are no symbols, the result is
NULL.The returned iterator is merely a shallow copy. Nevertheless, it is the responsibility of the caller to free it with
DisposeSymbolIterator. -
LLVMObjectFileIsSymbolIteratorAtEnd
public static boolean LLVMObjectFileIsSymbolIteratorAtEnd(long BR, long SI) Returns whether the given symbol iterator is at the end. -
LLVMDisposeSectionIterator
public static void LLVMDisposeSectionIterator(long SI) -
LLVMMoveToNextSection
public static void LLVMMoveToNextSection(long SI) -
LLVMMoveToContainingSection
public static void LLVMMoveToContainingSection(long Sect, long Sym) -
LLVMDisposeSymbolIterator
public static void LLVMDisposeSymbolIterator(long SI) -
LLVMMoveToNextSymbol
public static void LLVMMoveToNextSymbol(long SI) -
nLLVMGetSectionName
public static long nLLVMGetSectionName(long SI) -
LLVMGetSectionName
-
LLVMGetSectionSize
public static long LLVMGetSectionSize(long SI) -
nLLVMGetSectionContents
public static long nLLVMGetSectionContents(long SI) -
LLVMGetSectionContents
-
LLVMGetSectionAddress
public static long LLVMGetSectionAddress(long SI) -
LLVMGetSectionContainsSymbol
public static boolean LLVMGetSectionContainsSymbol(long SI, long Sym) -
LLVMGetRelocations
public static long LLVMGetRelocations(long Section) -
LLVMDisposeRelocationIterator
public static void LLVMDisposeRelocationIterator(long RI) -
LLVMIsRelocationIteratorAtEnd
public static boolean LLVMIsRelocationIteratorAtEnd(long Section, long RI) -
LLVMMoveToNextRelocation
public static void LLVMMoveToNextRelocation(long RI) -
nLLVMGetSymbolName
public static long nLLVMGetSymbolName(long SI) -
LLVMGetSymbolName
-
LLVMGetSymbolAddress
public static long LLVMGetSymbolAddress(long SI) -
LLVMGetSymbolSize
public static long LLVMGetSymbolSize(long SI) -
LLVMGetRelocationOffset
public static long LLVMGetRelocationOffset(long RI) -
LLVMGetRelocationSymbol
public static long LLVMGetRelocationSymbol(long RI) -
LLVMGetRelocationType
public static long LLVMGetRelocationType(long RI) -
nLLVMGetRelocationTypeName
public static long nLLVMGetRelocationTypeName(long RI) -
LLVMGetRelocationTypeName
-
nLLVMGetRelocationValueString
public static long nLLVMGetRelocationValueString(long RI) -
LLVMGetRelocationValueString
-
LLVMCreateObjectFile
public static long LLVMCreateObjectFile(long MemBuf) Deprecated: useCreateBinaryinstead. -
LLVMDisposeObjectFile
public static void LLVMDisposeObjectFile(long ObjectFile) Deprecated: useDisposeBinaryinstead. -
LLVMGetSections
public static long LLVMGetSections(long ObjectFile) Deprecated: UseObjectFileCopySectionIteratorinstead. -
LLVMIsSectionIteratorAtEnd
public static boolean LLVMIsSectionIteratorAtEnd(long ObjectFile, long SI) Deprecated: UseObjectFileIsSectionIteratorAtEndinstead. -
LLVMGetSymbols
public static long LLVMGetSymbols(long ObjectFile) Deprecated: UseObjectFileCopySymbolIteratorinstead. -
LLVMIsSymbolIteratorAtEnd
public static boolean LLVMIsSymbolIteratorAtEnd(long ObjectFile, long SI) Deprecated: UseObjectFileIsSymbolIteratorAtEndinstead.
-