<feed xmlns='http://www.w3.org/2005/Atom'>
<title>suspect-devices/circuitpython/py/emitglue.c, branch v1.3.5</title>
<subtitle>CircuitPython - a Python implementation for teaching coding with microcontrollers</subtitle>
<id>https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=v1.3.5</id>
<link rel='self' href='https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=v1.3.5'/>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/'/>
<updated>2014-10-26T22:36:56+00:00</updated>
<entry>
<title>unix: Make -v dump memory info at exit.</title>
<updated>2014-10-26T22:36:56+00:00</updated>
<author>
<name>Paul Sokolovsky</name>
<email>pfalcon@users.sourceforge.net</email>
</author>
<published>2014-10-26T21:20:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=429e3f077e8034d934cf5decdb77bdd64a130808'/>
<id>urn:sha1:429e3f077e8034d934cf5decdb77bdd64a130808</id>
<content type='text'>
Also, move bytecode dumps to -v -v, because they're too verbose for just -v.
</content>
</entry>
<entry>
<title>py: Store bytecode arg names in bytecode (were in own array).</title>
<updated>2014-10-25T19:23:13+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-25T14:07:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=1084b0f9c21b093618da4494508dec9ca8467e35'/>
<id>urn:sha1:1084b0f9c21b093618da4494508dec9ca8467e35</id>
<content type='text'>
This saves a lot of RAM for 2 reasons:

1. For functions that don't have default values, var args or var kw
args (which is a large number of functions in the general case), the
mp_obj_fun_bc_t type now fits in 1 GC block (previously needed 2 because
of the extra pointer to point to the arg_names array).  So this saves 16
bytes per function (32 bytes on 64-bit machines).

2. Combining separate memory regions generally saves RAM because the
unused bytes at the end of the GC block are saved for 1 of the blocks
(since that block doesn't exist on its own anymore).  So generally this
saves 8 bytes per function.

Tested by importing lots of modules:

- 64-bit Linux gave about an 8% RAM saving for 86k of used RAM.
- pyboard gave about a 6% RAM saving for 31k of used RAM.
</content>
</entry>
<entry>
<title>py: Fix debug-printing of bytecode line numbers.</title>
<updated>2014-10-24T14:42:50+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-24T14:42:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=564963a1700bfca8f053f864ad170d4a34a26270'/>
<id>urn:sha1:564963a1700bfca8f053f864ad170d4a34a26270</id>
<content type='text'>
Also move the raw bytecode printing code from emitglue to mp_bytecode_print.
</content>
</entry>
<entry>
<title>py: Fix line number printing for file with 1 line.</title>
<updated>2014-08-26T22:35:57+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-08-26T22:35:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=b427d6ae8686f4a9520509cb73ab9f1327ceadc1'/>
<id>urn:sha1:b427d6ae8686f4a9520509cb73ab9f1327ceadc1</id>
<content type='text'>
With a file with 1 line (and an error on that line), used to show the
line as number 0.  Now shows it correctly as line number 1.

But, when line numbers are disabled, it now prints line number 1 for any
line that has an error (instead of 0 as previously).  This might end up
being confusing, but requires extra RAM and/or hack logic to make it
print something special in the case of no line numbers.
</content>
</entry>
<entry>
<title>py: Fix bug where GC collected native/viper/asm function data.</title>
<updated>2014-08-24T15:28:17+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-08-24T15:28:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=3c658a4e755a75e495303957208486e583ddb270'/>
<id>urn:sha1:3c658a4e755a75e495303957208486e583ddb270</id>
<content type='text'>
Because (for Thumb) a function pointer has the LSB set, pointers to
dynamic functions in RAM (eg native, viper or asm functions) were not
being traced by the GC.  This patch is a comprehensive fix for this.

Addresses issue #820.
</content>
</entry>
<entry>
<title>py: Allow viper to have type annotations.</title>
<updated>2014-08-15T15:45:41+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-08-15T15:45:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=2ac4af6946543ae96cf3659468e1b8cabb057f85'/>
<id>urn:sha1:2ac4af6946543ae96cf3659468e1b8cabb057f85</id>
<content type='text'>
Viper functions can now be annotated with the type of their arguments
and return value.  Eg:

@micropython.viper
def f(x:int) -&gt; int:
    return x + 1
</content>
</entry>
<entry>
<title>Rename machine_(u)int_t to mp_(u)int_t.</title>
<updated>2014-07-03T12:25:24+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-07-03T12:25:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=40f3c026823f8951a2fa04e9c7fc93c75bc27bec'/>
<id>urn:sha1:40f3c026823f8951a2fa04e9c7fc93c75bc27bec</id>
<content type='text'>
See discussion in issue #50.
</content>
</entry>
<entry>
<title>py: Include mpconfig.h before all other includes.</title>
<updated>2014-06-21T19:43:22+00:00</updated>
<author>
<name>Paul Sokolovsky</name>
<email>pfalcon@users.sourceforge.net</email>
</author>
<published>2014-06-21T19:43:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=59c675a64c1d9757d50ad4627da67a6f996a99fb'/>
<id>urn:sha1:59c675a64c1d9757d50ad4627da67a6f996a99fb</id>
<content type='text'>
It defines types used by all other headers.

Fixes #691.
</content>
</entry>
<entry>
<title>py: Implement default keyword only args.</title>
<updated>2014-06-07T21:01:00+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-06-07T21:01:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=f0778a7ccbbdd1d7bf116a6939c7eb05173e1987'/>
<id>urn:sha1:f0778a7ccbbdd1d7bf116a6939c7eb05173e1987</id>
<content type='text'>
Should finish addressing issue #524.
</content>
</entry>
<entry>
<title>showbc: Make micropython -v also dump bytecode in hex form.</title>
<updated>2014-06-02T22:39:13+00:00</updated>
<author>
<name>Paul Sokolovsky</name>
<email>pfalcon@users.sourceforge.net</email>
</author>
<published>2014-06-02T22:38:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=f753971e5dc6af3ae399400a1258ca67279d8ea0'/>
<id>urn:sha1:f753971e5dc6af3ae399400a1258ca67279d8ea0</id>
<content type='text'>
</content>
</entry>
</feed>
