0xYUANTI / tpython

Variant of the Python 2.5 interpreter with direct threaded code and superinstructions.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Quickstart
==========
(1) code.h goes into Python-2.5.2/Include, codeobject.c should be copied
into Python-2.5.2/Objects and ceval* into Python-2.5.2/Python.

(2) Build Python:
configure && make

(3) Re-compile Python/ceval.c with -fno-gcse. E.g.
touch Python/ceval.c followed by
make OPT='-DNDEBUG -g -fwrapv -O3 -fno-gcse -Wall -Wstrict-prototypes' python

Details
=======
The various ceval-*.i files are generated by Vmgen and a few AWK scripts.

ceval.vmg contains the VM instruction descriptions which Vmgen uses to
generate ceval-disasm.i, ceval-gen.i, ceval-labels.i, ceval-peephole.i,
and ceval-vm.i.

ceval-vm.i is then post-processed for increased readability by mangler.awk.

ceval-translate.i and ceval-disasm-bytes.i are generated by two five line 
AWK scripts which are available upon request.

To obtain Vmgen, install Gforth 0.6.2 and apply prims2x.patch (a trivial
single character change which will probably be incorporated into future
versions of Vmgen).

Failing testcases
=================
test_doctest    (2 of 419)
test_hotshot    (1 of 4)
test_inspect    (1 of 41)
test_subprocess (1 of 44)
test_trace      (34 of 40)

Questions
=========
Mail to cadr4u@gmail.com welcome!

Cheers,
-jakob

About

Variant of the Python 2.5 interpreter with direct threaded code and superinstructions.


Languages

Language:C 100.0%