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


Groups > comp.lang.python > #72511 > unrolled thread

Micro Python -- a lean and efficient implementation of Python 3

Started byDamien George <damien.p.george@gmail.com>
First post2014-06-03 13:27 +0100
Last post2014-06-03 14:04 +0000
Articles 2 — 2 participants

Back to article view | Back to comp.lang.python


Contents

  Micro Python -- a lean and efficient implementation of Python 3 Damien George <damien.p.george@gmail.com> - 2014-06-03 13:27 +0100
    Re: Micro Python -- a lean and efficient implementation of Python 3 Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-06-03 14:04 +0000

#72511 — Micro Python -- a lean and efficient implementation of Python 3

FromDamien George <damien.p.george@gmail.com>
Date2014-06-03 13:27 +0100
SubjectMicro Python -- a lean and efficient implementation of Python 3
Message-ID<mailman.10619.1401798433.18130.python-list@python.org>
Hi,

We would like to announce Micro Python, an implementation of Python 3
optimised to have a low memory footprint.

While Python has many attractive features, current implementations
(read CPython) are not suited for embedded devices, such as
microcontrollers and small systems-on-a-chip.  This is because CPython
uses an awful lot of RAM -- both stack and heap -- even for simple
things such as integer addition.

Micro Python is a new implementation of the Python 3 language, which
aims to be properly compatible with CPython, while sporting a very
minimal RAM footprint, a compact compiler, and a fast and efficient
runtime.  These goals have been met by employing many tricks with
pointers and bit stuffing, and placing as much as possible in
read-only memory.

Micro Python has the following features:

- Supports almost full Python 3 syntax, including yield (compiles
99.99% of the Python 3 standard library).
- Most scripts use significantly less RAM in Micro Python, and various
benchmark programs run faster, compared with CPython.
- A minimal ARM build fits in 80k of program space, and with all
features enabled it fits in around 200k on Linux.
- Micro Python needs only 2k RAM for a basic REPL.
- It has 2 modes of AOT (ahead of time) compilation to native machine
code, doubling execution speed.
- There is an inline assembler for use in time-critical
microcontroller applications.
- It is written in C99 ANSI C and compiles cleanly under Unix (POSIX),
Mac OS X, Windows and certain ARM based microcontrollers.
- It supports a growing subset of Python 3 types and operations.
- Part of the Python 3 standard library has already been ported to
Micro Python, and work is ongoing to port as much as feasible.

More info at:

http://micropython.org/

You can follow the progress and contribute at github:

www.github.com/micropython/micropython
www.github.com/micropython/micropython-lib

--
Damien / Micro Python team.

[toc] | [next] | [standalone]


#72520

FromSteven D'Aprano <steve+comp.lang.python@pearwood.info>
Date2014-06-03 14:04 +0000
Message-ID<538dd5d8$0$29978$c3e8da3$5496439d@news.astraweb.com>
In reply to#72511
On Tue, 03 Jun 2014 13:27:11 +0100, Damien George wrote:

> Hi,
> 
> We would like to announce Micro Python, an implementation of Python 3
> optimised to have a low memory footprint.

Fantastic!




-- 
Steven D'Aprano
http://import-that.dreamwidth.org/

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web