19#ifndef LLVM_C_TARGET_H
20#define LLVM_C_TARGET_H
24#include "llvm/Config/llvm-config.h"
41#define LLVM_TARGET(TargetName) \
42 void LLVMInitialize##TargetName##TargetInfo(void);
43#include "llvm/Config/Targets.def"
46#define LLVM_TARGET(TargetName) void LLVMInitialize##TargetName##Target(void);
47#include "llvm/Config/Targets.def"
50#define LLVM_TARGET(TargetName) \
51 void LLVMInitialize##TargetName##TargetMC(void);
52#include "llvm/Config/Targets.def"
56#define LLVM_ASM_PRINTER(TargetName) \
57 void LLVMInitialize##TargetName##AsmPrinter(void);
58#include "llvm/Config/AsmPrinters.def"
59#undef LLVM_ASM_PRINTER
62#define LLVM_ASM_PARSER(TargetName) \
63 void LLVMInitialize##TargetName##AsmParser(void);
64#include "llvm/Config/AsmParsers.def"
68#define LLVM_DISASSEMBLER(TargetName) \
69 void LLVMInitialize##TargetName##Disassembler(void);
70#include "llvm/Config/Disassemblers.def"
71#undef LLVM_DISASSEMBLER
77#define LLVM_TARGET(TargetName) LLVMInitialize##TargetName##TargetInfo();
78#include "llvm/Config/Targets.def"
86#define LLVM_TARGET(TargetName) LLVMInitialize##TargetName##Target();
87#include "llvm/Config/Targets.def"
95#define LLVM_TARGET(TargetName) LLVMInitialize##TargetName##TargetMC();
96#include "llvm/Config/Targets.def"
104#define LLVM_ASM_PRINTER(TargetName) LLVMInitialize##TargetName##AsmPrinter();
105#include "llvm/Config/AsmPrinters.def"
106#undef LLVM_ASM_PRINTER
113#define LLVM_ASM_PARSER(TargetName) LLVMInitialize##TargetName##AsmParser();
114#include "llvm/Config/AsmParsers.def"
115#undef LLVM_ASM_PARSER
122#define LLVM_DISASSEMBLER(TargetName) \
123 LLVMInitialize##TargetName##Disassembler();
124#include "llvm/Config/Disassemblers.def"
125#undef LLVM_DISASSEMBLER
133#ifdef LLVM_NATIVE_TARGET
134 LLVM_NATIVE_TARGETINFO();
135 LLVM_NATIVE_TARGET();
136 LLVM_NATIVE_TARGETMC();
147#ifdef LLVM_NATIVE_ASMPARSER
148 LLVM_NATIVE_ASMPARSER();
159#ifdef LLVM_NATIVE_ASMPRINTER
160 LLVM_NATIVE_ASMPRINTER();
171#ifdef LLVM_NATIVE_DISASSEMBLER
172 LLVM_NATIVE_DISASSEMBLER();
279 unsigned long long Offset);
MachineBasicBlock MachineBasicBlock::iterator DebugLoc DL
static GCRegistry::Add< ShadowStackGC > C("shadow-stack", "Very portable GC for uncooperative code generators")
#define LLVM_C_EXTERN_C_BEGIN
#define LLVM_C_EXTERN_C_END
struct LLVMOpaqueValue * LLVMValueRef
Represents an individual value in LLVM IR.
struct LLVMOpaquePassManager * LLVMPassManagerRef
struct LLVMOpaqueContext * LLVMContextRef
The top-level container for all LLVM global data.
struct LLVMOpaqueType * LLVMTypeRef
Each value in the LLVM IR has a type, an LLVMTypeRef.
struct LLVMOpaqueModule * LLVMModuleRef
The top-level container for all other LLVM Intermediate Representation (IR) objects.
static LLVMBool LLVMInitializeNativeAsmParser(void)
LLVMInitializeNativeTargetAsmParser - The main program should call this function to initialize the pa...
void LLVMSetModuleDataLayout(LLVMModuleRef M, LLVMTargetDataRef DL)
Set the data layout for a module.
LLVMTargetDataRef LLVMGetModuleDataLayout(LLVMModuleRef M)
Obtain the data layout for a module.
unsigned LLVMPreferredAlignmentOfGlobal(LLVMTargetDataRef TD, LLVMValueRef GlobalVar)
Computes the preferred alignment of a global variable in bytes for a target.
void LLVMDisposeTargetData(LLVMTargetDataRef TD)
Deallocates a TargetData.
char * LLVMCopyStringRepOfTargetData(LLVMTargetDataRef TD)
Converts target data to a target layout string.
LLVMTypeRef LLVMIntPtrTypeInContext(LLVMContextRef C, LLVMTargetDataRef TD)
Returns the integer type that is the same size as a pointer on a target.
static void LLVMInitializeAllTargetInfos(void)
LLVMInitializeAllTargetInfos - The main program should call this function if it wants access to all a...
unsigned LLVMABIAlignmentOfType(LLVMTargetDataRef TD, LLVMTypeRef Ty)
Computes the ABI alignment of a type in bytes for a target.
unsigned long long LLVMStoreSizeOfType(LLVMTargetDataRef TD, LLVMTypeRef Ty)
Computes the storage size of a type in bytes for a target.
enum LLVMByteOrdering LLVMByteOrder(LLVMTargetDataRef TD)
Returns the byte order of a target, either LLVMBigEndian or LLVMLittleEndian.
LLVMTypeRef LLVMIntPtrType(LLVMTargetDataRef TD)
Returns the integer type that is the same size as a pointer on a target.
static LLVMBool LLVMInitializeNativeAsmPrinter(void)
LLVMInitializeNativeTargetAsmPrinter - The main program should call this function to initialize the p...
static LLVMBool LLVMInitializeNativeDisassembler(void)
LLVMInitializeNativeTargetDisassembler - The main program should call this function to initialize the...
static void LLVMInitializeAllTargetMCs(void)
LLVMInitializeAllTargetMCs - The main program should call this function if it wants access to all ava...
unsigned LLVMPointerSizeForAS(LLVMTargetDataRef TD, unsigned AS)
Returns the pointer size in bytes for a target for a specified address space.
unsigned LLVMCallFrameAlignmentOfType(LLVMTargetDataRef TD, LLVMTypeRef Ty)
Computes the call frame alignment of a type in bytes for a target.
unsigned long long LLVMOffsetOfElement(LLVMTargetDataRef TD, LLVMTypeRef StructTy, unsigned Element)
Computes the byte offset of the indexed struct element for a target.
unsigned long long LLVMSizeOfTypeInBits(LLVMTargetDataRef TD, LLVMTypeRef Ty)
Computes the size of a type in bits for a target.
void LLVMAddTargetLibraryInfo(LLVMTargetLibraryInfoRef TLI, LLVMPassManagerRef PM)
Adds target library information to a pass manager.
struct LLVMOpaqueTargetLibraryInfotData * LLVMTargetLibraryInfoRef
unsigned LLVMPointerSize(LLVMTargetDataRef TD)
Returns the pointer size in bytes for a target.
LLVMTypeRef LLVMIntPtrTypeForAS(LLVMTargetDataRef TD, unsigned AS)
Returns the integer type that is the same size as a pointer on a target.
static void LLVMInitializeAllAsmParsers(void)
LLVMInitializeAllAsmParsers - The main program should call this function if it wants all asm parsers ...
unsigned long long LLVMABISizeOfType(LLVMTargetDataRef TD, LLVMTypeRef Ty)
Computes the ABI size of a type in bytes for a target.
LLVMTargetDataRef LLVMCreateTargetData(const char *StringRep)
Creates target data from a target layout string.
static LLVMBool LLVMInitializeNativeTarget(void)
LLVMInitializeNativeTarget - The main program should call this function to initialize the native targ...
static void LLVMInitializeAllTargets(void)
LLVMInitializeAllTargets - The main program should call this function if it wants to link in all avai...
struct LLVMOpaqueTargetData * LLVMTargetDataRef
LLVMTypeRef LLVMIntPtrTypeForASInContext(LLVMContextRef C, LLVMTargetDataRef TD, unsigned AS)
Returns the integer type that is the same size as a pointer on a target.
static void LLVMInitializeAllAsmPrinters(void)
LLVMInitializeAllAsmPrinters - The main program should call this function if it wants all asm printer...
static void LLVMInitializeAllDisassemblers(void)
LLVMInitializeAllDisassemblers - The main program should call this function if it wants all disassemb...
unsigned LLVMElementAtOffset(LLVMTargetDataRef TD, LLVMTypeRef StructTy, unsigned long long Offset)
Computes the structure element that contains the byte offset for a target.
unsigned LLVMPreferredAlignmentOfType(LLVMTargetDataRef TD, LLVMTypeRef Ty)
Computes the preferred alignment of a type in bytes for a target.