[pypy-dev] How can I make more readable the C code obtained from the PyPy translate

RCU alex.e.susu at gmail.com
Thu May 9 21:34:33 CEST 2013

     I am new to PyPy.

     I managed to write a few RPython programs and translate them with PyPy translate.
     As a few others have noticed, as well, (see for example 
http://grokbase.com/t/python/pypy-dev/124mqreh2r/output-readable-c and 
https://bugs.pypy.org/issue1220), the generated C code is very cryptic (when compared to 
the input RPython script).
     As far as I understand, this is so because of the following facts:
	- the RPython code gets compiled to Python bytecode and then translated to more basic 
operations (an IR which I think it does not have a particular name in the PyPy toolchain - 
or does it? :) )
	- heavy optimizations are being applied on this IR before generating code with the C backend.

     So, is there any simple way to generate more readable C code (more similar, if 
possible, to RPython script) - maybe some translate.py options I am missing?

   Thank you,

More information about the pypy-dev mailing list