Fix build with llvm-3.4
This commit is contained in:
parent
ce696c9b4e
commit
eb43529f7b
5 changed files with 35 additions and 34 deletions
|
|
@ -114,20 +114,38 @@ class DIBuilder:
|
|||
ref(DIType), # Ty
|
||||
)
|
||||
|
||||
createClassType = Method(DIType,
|
||||
ref(DIDescriptor), # Scope
|
||||
stringref_arg, # Name
|
||||
ref(DIFile), # File
|
||||
unsigned_arg, # LineNum
|
||||
uint64_arg, # SizeInBits
|
||||
uint64_arg, # AlignInBits
|
||||
uint64_arg, # OffsetInBits,
|
||||
unsigned_arg, # Flags
|
||||
ref(DIType), # DerivedFrom
|
||||
ref(DIArray), # Elements
|
||||
ptr(MDNode), # VTableHolder = 0
|
||||
ptr(MDNode), # TemplateParms = 0
|
||||
).require_only(10)
|
||||
if LLVM_VERSION <= (3, 3):
|
||||
createClassType = Method(DIType,
|
||||
ref(DIDescriptor), # Scope
|
||||
stringref_arg, # Name
|
||||
ref(DIFile), # File
|
||||
unsigned_arg, # LineNum
|
||||
uint64_arg, # SizeInBits
|
||||
uint64_arg, # AlignInBits
|
||||
uint64_arg, # OffsetInBits,
|
||||
unsigned_arg, # Flags
|
||||
ref(DIType), # DerivedFrom
|
||||
ref(DIArray), # Elements
|
||||
ptr(MDNode), # VTableHolder = 0
|
||||
ptr(MDNode), # TemplateParms = 0
|
||||
).require_only(10)
|
||||
else:
|
||||
createClassType = Method(DIType,
|
||||
ref(DIDescriptor), # Scope
|
||||
stringref_arg, # Name
|
||||
ref(DIFile), # File
|
||||
unsigned_arg, # LineNum
|
||||
uint64_arg, # SizeInBits
|
||||
uint64_arg, # AlignInBits
|
||||
uint64_arg, # OffsetInBits,
|
||||
unsigned_arg, # Flags
|
||||
ref(DIType), # DerivedFrom
|
||||
ref(DIArray), # Elements
|
||||
ref(DIType), # VTableHolder = DIType()
|
||||
ptr(MDNode), # TemplateParms = 0
|
||||
stringref_arg, # UniqueIdentifier
|
||||
).require_only(10)
|
||||
|
||||
|
||||
if LLVM_VERSION >= (3, 3):
|
||||
createStructType = Method(DIType,
|
||||
|
|
@ -303,7 +321,7 @@ class DIBuilder:
|
|||
bool_arg, # isDefinition
|
||||
unsigned_arg, # Virtuality=0
|
||||
unsigned_arg, # VTableIndex=0
|
||||
ptr(MDNode), # *VTableHolder=0
|
||||
ptr(MDNode) if LLVM_VERSION <= (3, 3) else ref(DIType), # VTableHolder
|
||||
unsigned_arg, # Flags=0
|
||||
bool_arg, # isOptimized=false
|
||||
ptr(Function), # *Fn=0
|
||||
|
|
|
|||
|
|
@ -88,9 +88,6 @@ class ExecutionEngine:
|
|||
isLazyCompilationDisabled = Method(cast(Bool, bool))
|
||||
DisableGVCompilation = Method(Void, cast(bool, Bool))
|
||||
isSymbolSearchingDisabled = Method(cast(Bool, bool))
|
||||
RegisterTable = Method(Void, ptr(Function), cast(int, VoidPtr))
|
||||
DeregisterTable = Method(Void, ptr(Function))
|
||||
DeregisterAllTables = Method()
|
||||
|
||||
_runFunction = CustomMethod('ExecutionEngine_RunFunction',
|
||||
PyObjectPtr, ptr(Function), PyObjectPtr)
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ class GlobalValue:
|
|||
|
||||
LinkageTypes = Enum('''
|
||||
ExternalLinkage, AvailableExternallyLinkage, LinkOnceAnyLinkage,
|
||||
LinkOnceODRLinkage, LinkOnceODRAutoHideLinkage, WeakAnyLinkage,
|
||||
LinkOnceODRLinkage, WeakAnyLinkage,
|
||||
WeakODRLinkage, AppendingLinkage, InternalLinkage, PrivateLinkage,
|
||||
LinkerPrivateLinkage, LinkerPrivateWeakLinkage, DLLImportLinkage,
|
||||
DLLExportLinkage, ExternalWeakLinkage, CommonLinkage
|
||||
|
|
|
|||
|
|
@ -34,13 +34,6 @@ class Target:
|
|||
hasJIT = _has()
|
||||
hasTargetMachine = _has()
|
||||
hasMCAsmBackend = _has()
|
||||
hasMCAsmParser = _has()
|
||||
hasAsmPrinter = _has()
|
||||
hasMCDisassembler = _has()
|
||||
hasMCInstPrinter = _has()
|
||||
hasMCCodeEmitter = _has()
|
||||
hasMCObjectStreamer = _has()
|
||||
hasAsmStreamer = _has()
|
||||
|
||||
createTargetMachine = Method(ptr(TargetMachine),
|
||||
cast(str, StringRef), # triple
|
||||
|
|
|
|||
|
|
@ -10,14 +10,7 @@ mthds = (
|
|||
("description:", "getShortDescription"),
|
||||
("has JIT:", "hasJIT" ),
|
||||
("has target machine:", "hasTargetMachine" ),
|
||||
("has asm backend:", "hasMCAsmBackend" ),
|
||||
("has asm parser:", "hasMCAsmParser" ),
|
||||
("has asm printer:", "hasAsmPrinter" ),
|
||||
("has disassembler:", "hasMCDisassembler" ),
|
||||
("has inst printer:", "hasMCInstPrinter" ),
|
||||
("has code emitter:", "hasMCCodeEmitter" ),
|
||||
("has object streamer:", "hasMCObjectStreamer"),
|
||||
("has asm streamer:", "hasAsmStreamer" )
|
||||
("has asm backend:", "hasMCAsmBackend" )
|
||||
)
|
||||
|
||||
for target in llvm.TargetRegistry.targetsList():
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue