[pypy-dev] translating pypy benchmarks to C

Ghitulete Razvan razvan.ghitulete at gmail.com
Mon Feb 25 09:13:33 CET 2013


On Sun, Feb 24, 2013 at 8:47 PM, Alex Gaynor <alex.gaynor at gmail.com> wrote:

> What you are doing will not generate any information about how fast Python
> can be. It will show you the speed of RPython or Cython on baremetal, these
> are *NOT* python.
>
>
I really disapprove of this language purity stuff. If it compiles, it
works. If it runs it's perfect. The idea behind this attempt is to see what
can be done if one removes all possible overhead. So I would not like to go
down that rabbit hole.

On Sun, Feb 24, 2013 at 11:14 PM, Armin Rigo <arigo at tunes.org> wrote:

> Hi Ghitulete,
>
> So are you saying that you don't want to use CPython because it's C,
> and you want to try C-less alternatives, or at least things that don't
> use libc?  Then look elsewhere.  An RPython program (which is
> definitely something different than a Python program) is translated to
> C code that uses libc.  Changing this would be possible, but certainly
> not less work than, say, changing CPython to not use the libc.  Which,
> I seem to recall, has been done long ago in an experiment of "booting
> CPython".
>

I have never said I want to try C-less alternatives, but as to my knowledge
the only common ground between CPython and C, si that part of CPython is
written in C, as opposed to generating C code. What I need is to get the
equivalent C code of a python program. CPython on the other hand would need
to have a VM to run the bytecode in, which I not plan on doing.

On Sun, Feb 24, 2013 at 9:17 PM, Leonardo Santagada <santagada at gmail.com>
 wrote:

>
> So what I think you need is a pypy binary that can run without an os...
> the pypy binary needs a libc to access stuff, if you have one that you are
> using with other C software in your project maybe you can port pypy to
> it... probably a pthreads library will also be needed. What you need is to
> define a new platform and port the whole pypy to it... probably cross
> compiling from linux. I think that is how the arm port works and should be
> doable.
>
>
I have pondered on doing that, but even though it is doable, it would
require quite an effort as it would need a more complete environment than
what I already have. Also, by porting pypy I would yet again get another
layer between python code and hardware.



-- 
Sincerely,
Razvan Ghitulete
Universitatea Politehnica Bucuresti
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pypy-dev/attachments/20130225/dced4d4c/attachment.html>


More information about the pypy-dev mailing list