<feed xmlns='http://www.w3.org/2005/Atom'>
<title>suspect-devices/circuitpython/py/compile.c, branch travis-esp8266</title>
<subtitle>CircuitPython - a Python implementation for teaching coding with microcontrollers</subtitle>
<id>https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=travis-esp8266</id>
<link rel='self' href='https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=travis-esp8266'/>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/'/>
<updated>2016-05-20T11:46:20+00:00</updated>
<entry>
<title>py: Declare constant data as properly constant.</title>
<updated>2016-05-20T11:46:20+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-05-20T11:38:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=3ff16ff52e45d4c0bf1df5fa650b72d6d835451b'/>
<id>urn:sha1:3ff16ff52e45d4c0bf1df5fa650b72d6d835451b</id>
<content type='text'>
Otherwise some compilers (eg without optimisation) will put this read-only
data in RAM instead of ROM.
</content>
</entry>
<entry>
<title>py: Fix constant folding and inline-asm to work with new async grammar.</title>
<updated>2016-04-13T14:26:39+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-04-13T14:21:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=eacbd7aeba3bdd634b56af544e40da87779f4a95'/>
<id>urn:sha1:eacbd7aeba3bdd634b56af544e40da87779f4a95</id>
<content type='text'>
</content>
</entry>
<entry>
<title>py: add async/await/async for/async with syntax</title>
<updated>2016-04-13T14:26:38+00:00</updated>
<author>
<name>pohmelie</name>
<email>multisosnooley@gmail.com</email>
</author>
<published>2016-01-27T20:23:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=81ebba7e0236163b7594938201bf3a6b802ebfaa'/>
<id>urn:sha1:81ebba7e0236163b7594938201bf3a6b802ebfaa</id>
<content type='text'>
They are sugar for marking function as generator, "yield from"
and pep492 python "semantically equivalents" respectively.

@dpgeorge was the original author of this patch, but @pohmelie made
changes to implement `async for` and `async with`.
</content>
</entry>
<entry>
<title>py: Implement basic with support in native emitter.</title>
<updated>2016-04-07T07:53:24+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-04-07T07:53:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=2c915e1ae61785ab6e33189581fb353ebd40d0ca'/>
<id>urn:sha1:2c915e1ae61785ab6e33189581fb353ebd40d0ca</id>
<content type='text'>
</content>
</entry>
<entry>
<title>py: Combine continuous block of emit steps into with_cleanup emit call.</title>
<updated>2016-04-07T07:50:38+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-04-07T07:50:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=ce8b4e87494a11f389de7629e82043d6fb70284e'/>
<id>urn:sha1:ce8b4e87494a11f389de7629e82043d6fb70284e</id>
<content type='text'>
Because different emitters need to handle with-cleanup in different ways.
</content>
</entry>
<entry>
<title>py: Don't allocate an extra parse node for power exponent.</title>
<updated>2016-03-16T13:04:51+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-03-16T13:04:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=3acaa28b52587bace3a4e8382fbf06ed6f6e4aaf'/>
<id>urn:sha1:3acaa28b52587bace3a4e8382fbf06ed6f6e4aaf</id>
<content type='text'>
Previous to this patch, the "**b" in "a**b" had its own parse node with
just one item (the "b").  Now, the "b" is just the last element of the
power parse-node.  This saves (a tiny bit of) RAM when compiling.
</content>
</entry>
<entry>
<title>py: Add MICROPY_DYNAMIC_COMPILER option to config compiler at runtime.</title>
<updated>2016-02-25T10:05:46+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-02-11T22:30:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=ea23520403777f9b026f49245d39f8be1ccdbdac'/>
<id>urn:sha1:ea23520403777f9b026f49245d39f8be1ccdbdac</id>
<content type='text'>
This new compile-time option allows to make the bytecode compiler
configurable at runtime by setting the fields in the mp_dynamic_compiler
structure.  By using this feature, the compiler can generate bytecode
that targets any MicroPython runtime/VM, regardless of the host and
target compile-time settings.

Options so far that fall under this dynamic setting are:
- maximum number of bits that a small int can hold;
- whether caching of lookups is used in the bytecode;
- whether to use unicode strings or not (lexer behaviour differs, and
  therefore generated string constants differ).
</content>
</entry>
<entry>
<title>py/inlineasm: Add ability to specify return type of asm_thumb funcs.</title>
<updated>2016-01-27T14:27:10+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-01-15T15:20:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=8f54c08691faa3dd859852d211230fd7d9791abd'/>
<id>urn:sha1:8f54c08691faa3dd859852d211230fd7d9791abd</id>
<content type='text'>
Supported return types are: object, bool, int, uint.

For example:

@micropython.asm_thumb
def foo(r0, r1) -&gt; uint:
    add(r0, r0, r1)
</content>
</entry>
<entry>
<title>py/parse: Optimise away parse node that's just parenthesis around expr.</title>
<updated>2016-01-07T13:07:52+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-01-07T13:07:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=93b3726240ed50aa162d47519d38b1713f93298a'/>
<id>urn:sha1:93b3726240ed50aa162d47519d38b1713f93298a</id>
<content type='text'>
Before this patch, (x+y)*z would be parsed to a tree that contained a
redundant identity parse node corresponding to the parenthesis.  With
this patch such nodes are optimised away, which reduces memory
requirements for expressions with parenthesis, and simplifies the
compiler because it doesn't need to handle this identity case.

A parenthesis parse node is still needed for tuples.
</content>
</entry>
<entry>
<title>py: Add MICROPY_ENABLE_COMPILER and MICROPY_PY_BUILTINS_EVAL_EXEC opts.</title>
<updated>2015-12-18T12:35:44+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-12-18T12:35:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=dd5353a4054024a411aa343a22ffcd16195a16ad'/>
<id>urn:sha1:dd5353a4054024a411aa343a22ffcd16195a16ad</id>
<content type='text'>
MICROPY_ENABLE_COMPILER can be used to enable/disable the entire compiler,
which is useful when only loading of pre-compiled bytecode is supported.
It is enabled by default.

MICROPY_PY_BUILTINS_EVAL_EXEC controls support of eval and exec builtin
functions.  By default they are only included if MICROPY_ENABLE_COMPILER
is enabled.

Disabling both options saves about 40k of code size on 32-bit x86.
</content>
</entry>
</feed>
