Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #2448

Re: a basic bytecode to machine code compiler

From Stefan Behnel <stefan_ml@behnel.de>
Subject Re: a basic bytecode to machine code compiler
Date 2011-04-02 12:30 +0200
References <4j7lp.5204$sS4.1784@newsfe11.iad> <4d95cba6$0$29992$c3e8da3$5496439d@news.astraweb.com> <mailman.80.1301672757.2990.python-list@python.org> <4d96f49b$0$29992$c3e8da3$5496439d@news.astraweb.com>
Newsgroups comp.lang.python
Message-ID <mailman.124.1301740231.2990.python-list@python.org> (permalink)

Show all headers | View raw


Steven D'Aprano, 02.04.2011 12:04:
> On Fri, 01 Apr 2011 17:45:39 +0200, Stefan Behnel wrote:
>
>> Steven D'Aprano, 01.04.2011 14:57:
>>> I suggest you check out the competitors:
>>>
>>> Shedskin is a Python to C++ compiler; Psyco is a JIT specialising
>>> compiler; Nuitka claims to be a C++ implementation that compiles to
>>> machine code; Berp claims to be a Haskell implementation that does the
>>> same; Compyler claims to be a native x86 assembly compiler; UnPython
>>> claims to be an experimental Python to C compiler.
>>>
>>>
>>> Of the six, as far as I know only Shedskin and Psyco are widely used.
>>
>> Erm, yes, right. If you want to exclude Cython, which arguably is the
>> only static Python compiler that actually has a large user base, then
>> those may really be the only two that are widely used. Except that Psyco
>> is certainly being used a lot more often than Shedskin, mainly because
>> it actually allows you to execute Python code.
>
> My apologies, I thought about including Cython in the list, but my
> understanding of it is that it is a derivative of Pyrex, and used for
> writing C extensions in a Python-like language (Python + type
> annotations). We were talking about talking ordinary, unmodified Python
> code and compiling it to machine code, and I didn't think either Pyrex or
> Cython do that.

Ok, no problem. Pyrex certainly doesn't play in the same league.

Cython actually supports most Python language features now (including 
generators in the development branch), both from Python 2 and Python 3. 
Chances are that the next release will actually compile most of your Python 
code unchanged, or only with minor adaptations.

Stefan

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

a basic bytecode to machine code compiler Rouslan Korneychuk <rouslank@msn.com> - 2011-03-31 18:33 -0400
  Re: a basic bytecode to machine code compiler Stefan Behnel <stefan_ml@behnel.de> - 2011-04-01 02:05 +0200
  Re: a basic bytecode to machine code compiler Terry Reedy <tjreedy@udel.edu> - 2011-03-31 20:52 -0400
  Re: a basic bytecode to machine code compiler Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-04-01 12:57 +0000
    Re: a basic bytecode to machine code compiler Stefan Behnel <stefan_ml@behnel.de> - 2011-04-01 17:45 +0200
      Re: a basic bytecode to machine code compiler Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-04-02 10:04 +0000
        Re: a basic bytecode to machine code compiler Stefan Behnel <stefan_ml@behnel.de> - 2011-04-02 12:30 +0200
          Re: a basic bytecode to machine code compiler John Nagle <nagle@animats.com> - 2011-04-02 12:05 -0700
            Re: a basic bytecode to machine code compiler Paul Rubin <no.email@nospam.invalid> - 2011-04-02 14:32 -0700
            Re: a basic bytecode to machine code compiler Robert Kern <robert.kern@gmail.com> - 2011-04-02 19:12 -0500
  Re: a basic bytecode to machine code compiler Rouslan Korneychuk <rouslank@msn.com> - 2011-04-01 15:31 -0400

csiph-web