Commit graph

83 commits

Author SHA1 Message Date
Siu Kwan Lam
206d512c10 Fix LLVMLinkModules for LLVM-3.1 2013-01-17 19:06:06 -06:00
Siu Kwan Lam
bdac4a809d Add lazy compilation option.
Unify execution engine creation through engine-builder internally.
2013-01-16 17:52:33 -06:00
Siu Kwan Lam
5b6a1d75f8 Fix breakage of LLVM 3.1.
Add LLVM version number in llvmpy.
2013-01-04 14:24:26 -06:00
Siu Kwan Lam
f01da12e16 Add CodeModel 2013-01-03 15:37:11 -06:00
Siu Kwan Lam
e8c7fcfd32 Add optional TargetMachine param to EngineBuilder.create. 2013-01-03 11:47:24 -06:00
Siu Kwan Lam
3b399f9d8b Adding target specific passes. 2013-01-02 17:42:28 -06:00
Siu Kwan Lam
ff92a05858 Begin to expose Pass class. 2013-01-02 17:42:28 -06:00
Siu Kwan Lam
10e83f306f Add PassManagerBuilder.loop_vectorize property 2012-12-31 10:45:21 -06:00
Siu Kwan Lam
5da98dac49 Add macros to enable support for llvm3.1. 2012-12-27 17:10:12 -06:00
xol
f3e9eb0b05 Fix for llvm 3.2 - TargetData -> DataLayout 2012-12-27 14:06:47 -06:00
Siu Kwan Lam
b9d05bb6fe Can now modify called_function of CallOrInvokeInstruction 2012-11-01 11:42:10 -05:00
Siu Kwan Lam
507ff73061 Add InlineAsm 2012-10-31 16:41:10 -05:00
Siu Kwan Lam
d781e83bd1 can now clone modules 2012-10-19 16:18:24 -05:00
Siu Kwan Lam
e0d1b94053 Add NamedMetaData 2012-10-16 16:35:20 -05:00
Siu Kwan Lam
e7ad6c7439 Remove the need to build temporary std::vector. 2012-09-19 14:20:19 -07:00
Siu Kwan Lam
9767ac4d47 Improve error-handling for PyCapsule_GetPointer and related functions. 2012-09-15 19:10:05 -07:00
Siu Kwan Lam
0079b1de07 Cleanup all memory allocations and their exception handling 2012-09-15 18:34:15 -07:00
Wladimir J. van der Laan
e2d8079b93 Support MetaDataString, and correctly represent MetaData Values in _make_value 2012-09-12 21:23:54 +02:00
Wladimir J. van der Laan
7f69beb258 Access to MetaData operands
This is not available in the C API, so add functions to extra.cpp:

- `LLVMMetaDataGetOperand` wraps MDNode::getOperand
- `LLVMMetaDataGetNumOperands` wraps MDNode::getNumOperands
2012-09-12 20:59:59 +02:00
Siu Kwan Lam
5ee6bba66b Fix invalid prototype after switches to size_t instead of unsigned int. 2012-09-10 17:22:20 -07:00
Siu Kwan Lam
82117d899e add support for metadata.
add related test.
2012-09-06 15:47:23 -07:00
Siu Kwan Lam
78cde30883 Revive inline_function() 2012-09-04 10:06:36 -07:00
Wladimir J. van der Laan
5bd4991f0b Implement property CallOrInvokeInstruction.called_function
Also add a testcase.
2012-09-02 13:23:47 +02:00
Siu Kwan Lam
5d14461c84 Fix ConstantExpr opcode to use C++ enum values.
Note: C++ opcode is different from C opcode values.
Add ConstantExpr opcode name.
Add test for these.
2012-09-01 20:53:33 -07:00
Siu Kwan Lam
d78253ebe3 Add control to alignment of ld/st inst 2012-08-21 18:28:35 -05:00
Siu Kwan Lam
1ed2049395 add method to retrieve host cpu name
add stub method to enginebuilder to setMCPU and setMAttrs -- these are not implemented in llvm3.1
2012-08-18 17:32:40 -07:00
Siu Kwan Lam
d1bcdd05d1 add NVPTX for LLVM 3.2;
auto-gen _intrinsic_ids.py  in setup.py;
2012-08-18 15:29:26 -07:00
Siu Kwan Lam
7880cdd3ba Fix get intrinsic 2012-08-15 16:13:38 -07:00
Siu Kwan Lam
8eb6a34d54 Replace fprintf with exception 2012-08-15 15:22:08 -07:00
Siu Kwan Lam
8b273490a9 Can create PTX target machine and print PTX asm 2012-08-14 16:50:32 -07:00
Siu Kwan Lam
f85713a736 Enable PTX backend 2012-08-14 15:05:22 -07:00
Siu Kwan Lam
ec71908874 Add target machine 2012-08-14 12:04:28 -07:00
Siu Kwan Lam
bed4f24cbd Added Module.to_native_object() and Module.to_native_assembly().
Added test for these new functions.
2012-08-09 15:41:55 -07:00
Siu Kwan Lam
5e15b27909 Atomic load/store must explicit define alignment. 2012-08-03 14:13:22 -07:00
Siu Kwan Lam
f479f85676 Add memory fence 2012-08-03 12:30:01 -07:00
Siu Kwan Lam
6ac0f3c369 Add atomic load/store 2012-08-03 11:56:59 -07:00
Siu Kwan Lam
fb72ab5c8d Add the rest of atomic op. 2012-08-03 10:14:09 -07:00
Siu Kwan Lam
acad5c9d8b Added atomic cmpxchg. 2012-08-02 17:54:40 -07:00
Siu Kwan Lam
9aadd489c3 Python3 ready. Py2.7 and Py3 working. Drop PyCObject for all.
Pre Py2.7 support should be possible by including  "capsulethunk.h". (See llvm/wrap.h)
2012-07-26 15:25:23 -07:00
Siu Kwan Lam
5bb4b8affb Added EngineBuilder.
Added test/enginebuilder.
2012-07-25 15:31:18 -07:00
Siu Kwan Lam
6a02c36f04 Added PassManagerBuilder.
Updated test/passes.py for PassManagerBuilder.
2012-07-24 23:42:28 -07:00
Siu Kwan Lam
99c7a0736e Comment out pass constants in C files. 2012-07-24 12:25:42 -07:00
Siu Kwan Lam
2d79cfa437 Replaced PASS_* constants with pass name lookup. 2012-07-23 17:39:40 -07:00
Siu Kwan Lam
c9902ab8cf Add opaque StructType;
Remove test/typehandle.py;
Add test/opaque.py to demonstrate recursive type.
2012-07-22 15:14:52 -07:00
Siu Kwan Lam
b71d22b570 Update StructType to LLVM 3.x (incomplete).
Bring back StructType.elements.
2012-07-22 00:00:04 -07:00
Siu Kwan Lam
9bbeee519b Added Module.id property (getter+setter).
Updated test/asm.py to use unittest.
2012-07-20 20:15:21 -07:00
Travis E. Oliphant
7b6aac79fb Add llvm::Module::addLibrary to exposed API 2012-06-21 01:25:23 -05:00
Nicolas Pinto
bf36c50e96 BUG: fix error: ‘printf’ was not declared in this scope 2012-03-15 13:13:26 -04:00
Travis E. Oliphant
796f5e264a Use correct casing for print method. 2012-03-08 07:18:18 -06:00
Travis E. Oliphant
3120dbf29e More changes to get llvm-py to compile with LLVM 3.0 2012-02-08 09:23:58 -06:00