Commit graph

41 commits

Author SHA1 Message Date
Jon Riehl
aacfce25bf Manual merge from origin/master after applying PR#83. 2013-09-09 16:14:32 -05:00
Sergio Pascual
aae25f5e55 Remove shebangs from library code 2013-09-09 13:00:01 +02:00
Jon Riehl
4f815224f9 Added types for more of the Python C API. 2013-07-25 15:56:01 -05:00
Jon Riehl
f332fbf9de Added a few additional Python C API function declarations, used for comparing objects. 2013-07-23 16:42:59 -05:00
Jon Riehl
1adf3d871a Added support for UNARY_INVERT bytecode. 2013-07-23 16:42:46 -05:00
Jon Riehl
9fe9e8eb39 Incremental extensions to llpython to better support using the Python C-API. 2013-07-12 19:38:50 -05:00
Jon Riehl
e4f4d56fe6 Added support for POP_TOP and SETUP_LOOP to llpython.af_to_api. 2013-06-18 11:52:30 -05:00
Jon Riehl
a6cf8c4f71 Made some improvements to llpython.af_to_api, specifically attempting to normalize variable access so reference counting becomes the target API's responsibility. 2013-06-17 18:08:36 -05:00
Jon Riehl
d8297cf50b Added support for rudimentary control flow, and completely incorrect refcounting in llpython.af_to_api. 2013-06-14 18:18:30 -05:00
Jon Riehl
a8747d2125 Initial proof of concept for generic API calling code generator in llpython.af_to_api. 2013-06-14 16:00:42 -05:00
Jon Riehl
fcf5420803 Added argument naming to llpython.byte_translator. 2013-06-14 15:59:51 -05:00
Jon Riehl
fd41a93554 Added llpython.af_to_api module. Started work on a code generator that accepts address flows, and outputs an LLVM function that implements the given code object using (undefined) API calls for bytecode instructions. 2013-06-13 15:25:28 -05:00
Jon Riehl
5f81cab357 Moved most of bytecode_visitor.BytecodeFlowVisitor into a new parent class GenericFlowVisitor, which is a useful starting point for address-based flow visitors. 2013-06-11 17:11:38 -05:00
Jon Riehl
68030d51d1 Modified BytecodeFlowBuilder and AddressFlowBuilder to use a named tuple for representing bytecode instructions. 2013-06-11 16:44:15 -05:00
Jon Riehl
6c7d493441 Fixed llpython.type_flow's main routine. Was using addr_flow.build_addr_flow() which was removed. 2013-06-07 19:18:34 -05:00
Jon Riehl
0b24adb80a Modified various passes to use the inspect module instead of using type comparisons or isinstance. 2013-06-07 15:30:45 -05:00
Jon Riehl
ee557c55cc Added llpython.tests.test_all module for unit testing all llpython. 2013-06-06 14:13:39 -05:00
Jon Riehl
722453502c Continued generalization of byte_flow.demo_flow_builder(), moving traversal logic into visitor function opcode_util.visit_code_args(). Modified byte_control.main() to use visit_code_args(). 2013-06-06 14:08:09 -05:00
Jon Riehl
c55198095f Modified FlowTestMixin.build_and_test_flow() to return generated flow for further testing. 2013-06-06 14:04:48 -05:00
Jon Riehl
bba305774a Moved most of llpython.tests.test_addr_flow into llpython.tests.test_byte_flow, made some modifications to various modules to facilitate proper handling of try-finally. 2013-06-05 18:52:27 -05:00
Jon Riehl
4837bf194e Moved some utility functions into class methods of the BytecodeFlowBuilder class, and eliminated redundant code in AddressFlowBuilder. 2013-06-05 15:28:17 -05:00
Jon Riehl
102d6eac66 Adding basic unit test for llpython.addr_flow. 2013-06-05 13:49:02 -05:00
Jon Riehl
31119a48d4 Modified main routine in llpython.addr_flow to make it easier to determine which code object caused an exception in the translator. 2013-06-05 13:48:30 -05:00
Jon Riehl
b5a15a5019 Added function to iterate through nested code objects, llpython.opcode_util.itercodeobjs(), and used it in llpython.addr_flow. 2013-06-03 19:12:19 -05:00
Jon Riehl
c890cbdd92 Attempting to improve readability of opcode value stack action map using namedtuple in llpython.opcode_util. 2013-06-03 18:00:06 -05:00
Jon Riehl
643f0706e9 Checking in non-functional attempt at type dependency simplification pass in llpython.type_flow. 2013-06-03 16:00:46 -05:00
Jon Riehl
abbf972768 Added address flow builder, and type constraint generator. 2013-05-21 11:58:26 -05:00
Jon Riehl
c06f811473 Reintroduced dead code elimination to CFA pass to avoid dataflow problems. Updated tests. 2013-05-16 15:38:12 -05:00
Jon Riehl
c5d95e01e1 More work on CFA for try-finally in the presence of loops. 2013-05-15 18:40:44 -05:00
Jon Riehl
8ae1b70206 Initial attempt to support return statements in try-finally block in llpython.byte_control. Added incomplete unit tests. 2013-05-14 17:34:54 -05:00
Jon Riehl
d3b252531d Updates to llpython.opcode_util to better support loop and exception control flow.
* Inlcuded non-argument branching opcodes in the hasjump opcode list.
* Added all the SETUP_* opcodes to the hascbranch list.
* Modified itercode() to not output the EXTENDED_ARG bytecode.
* Cleaned up extendlabels(), and made it use the hasjump opcode list uniformly.
2013-05-14 14:52:11 -05:00
Jon Riehl
6f532f164a Working on full opcode coverage and support for exception control flow. 2013-05-14 14:52:11 -05:00
Jon Riehl
5ef00671e7 Add support for more bytecodes. 2013-05-14 14:52:11 -05:00
Jon Riehl
8787af154e Change idom() method to get_a_dom(), update uses, and documentation. 2013-05-14 14:52:11 -05:00
Hernan Grecco
b8da3c7a73 Changed imports in llpython 2013-03-05 18:11:08 -03:00
Ilan Schnell
5dd0948c65 cleanup 2013-01-31 17:54:20 -06:00
Jon Riehl
b895f1fc99 Added explicit branch to otherwise unterminated basic blocks in llpython.byte_translator. 2013-01-29 16:44:03 -06:00
Jon Riehl
ffc067f852 Attempt at a fix for issue #48. 2013-01-28 20:08:09 -06:00
Mark Florisson
60795adb5e Implement JUMP_IF_FALSE bytecode instruction in llpython 2013-01-24 20:10:41 -06:00
Travis E. Oliphant
ac791e5c38 Change name to llpython and remove llnumba references. 2012-11-07 12:14:01 -06:00
Travis E. Oliphant
bbc7a4ddf0 Ready for numba/llnumba -> llvmpy/llpython 2012-11-07 12:08:32 -06:00