<feed xmlns='http://www.w3.org/2005/Atom'>
<title>suspect-devices/circuitpython/py/malloc.c, branch 2.x</title>
<subtitle>CircuitPython - a Python implementation for teaching coding with microcontrollers</subtitle>
<id>https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=2.x</id>
<link rel='self' href='https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=2.x'/>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/'/>
<updated>2017-08-15T01:53:36+00:00</updated>
<entry>
<title>py: Add verbose debug compile-time flag MICROPY_DEBUG_VERBOSE.</title>
<updated>2017-08-15T01:53:36+00:00</updated>
<author>
<name>Stefan Naumann</name>
<email>me@stefannaumann.de</email>
</author>
<published>2017-07-24T16:55:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=ace9fb54053c29574bdf81ffacc5ddcf9d4b45d9'/>
<id>urn:sha1:ace9fb54053c29574bdf81ffacc5ddcf9d4b45d9</id>
<content type='text'>
It enables all the DEBUG_printf outputs in the py/ source code.
</content>
</entry>
<entry>
<title>all: Use the name MicroPython consistently in comments</title>
<updated>2017-07-31T08:35:40+00:00</updated>
<author>
<name>Alexander Steffen</name>
<email>devel.20.webmeister@spamgourmet.com</email>
</author>
<published>2017-06-30T07:22:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=55f33240f3d7051d4213629e92437a36f1fac50e'/>
<id>urn:sha1:55f33240f3d7051d4213629e92437a36f1fac50e</id>
<content type='text'>
There were several different spellings of MicroPython present in comments,
when there should be only one.
</content>
</entry>
<entry>
<title>py/gc: Add MICROPY_GC_CONSERVATIVE_CLEAR option to always zero memory.</title>
<updated>2016-08-26T05:35:26+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-08-26T05:35:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=5ffe1d8dc07930818bbac6a88bec2aa5bd973402'/>
<id>urn:sha1:5ffe1d8dc07930818bbac6a88bec2aa5bd973402</id>
<content type='text'>
There can be stray pointers in memory blocks that are not properly zero'd
after allocation.  This patch adds a new config option to always zero all
allocated memory (via gc_alloc and gc_realloc) and hence help to eliminate
stray pointers.

See issue #2195.
</content>
</entry>
<entry>
<title>py/malloc: Provide a proper malloc-based implementation of realloc_ext.</title>
<updated>2016-02-23T13:53:38+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2016-02-23T13:53:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=e9d1a94bf099d585d0f8d3b0dddb8e0a397afcff'/>
<id>urn:sha1:e9d1a94bf099d585d0f8d3b0dddb8e0a397afcff</id>
<content type='text'>
</content>
</entry>
<entry>
<title>py: Improve allocation policy of qstr data.</title>
<updated>2015-07-14T21:56:32+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-06-13T20:53:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=ade9a052365247be5ed4ce8b53c2164a576a4a05'/>
<id>urn:sha1:ade9a052365247be5ed4ce8b53c2164a576a4a05</id>
<content type='text'>
Previous to this patch all interned strings lived in their own malloc'd
chunk.  On average this wastes N/2 bytes per interned string, where N is
the number-of-bytes for a quanta of the memory allocator (16 bytes on 32
bit archs).

With this patch interned strings are concatenated into the same malloc'd
chunk when possible.  Such chunks are enlarged inplace when possible,
and shrunk to fit when a new chunk is needed.

RAM savings with this patch are highly varied, but should always show an
improvement (unless only 3 or 4 strings are interned).  New version
typically uses about 70% of previous memory for the qstr data, and can
lead to savings of around 10% of total memory footprint of a running
script.

Costs about 120 bytes code size on Thumb2 archs (depends on how many
calls to gc_realloc are made).
</content>
</entry>
<entry>
<title>py: Add MICROPY_MALLOC_USES_ALLOCATED_SIZE to allow simpler malloc API.</title>
<updated>2015-03-03T21:23:13+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-02-27T09:54:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=d891452a73165966497f1c79b64276faaa664597'/>
<id>urn:sha1:d891452a73165966497f1c79b64276faaa664597</id>
<content type='text'>
</content>
</entry>
<entry>
<title>py: Put all global state together in state structures.</title>
<updated>2015-01-07T20:33:00+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-01-01T23:30:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=b4b10fd350852e321624d74983cca286091b55a1'/>
<id>urn:sha1:b4b10fd350852e321624d74983cca286091b55a1</id>
<content type='text'>
This patch consolidates all global variables in py/ core into one place,
in a global structure.  Root pointers are all located together to make
GC tracing easier and more efficient.
</content>
</entry>
<entry>
<title>py: Move to guarded includes, everywhere in py/ core.</title>
<updated>2015-01-01T20:32:09+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-01-01T20:27:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=51dfcb4bb7613ed164952712d9a5235a7b833cde'/>
<id>urn:sha1:51dfcb4bb7613ed164952712d9a5235a7b833cde</id>
<content type='text'>
Addresses issue #1022.
</content>
</entry>
<entry>
<title>py: Make gc.enable/disable just control auto-GC; alloc is still allowed.</title>
<updated>2014-10-31T21:30:46+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-31T21:30:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=109c1de015eeee385020233e2f8cc6f921149103'/>
<id>urn:sha1:109c1de015eeee385020233e2f8cc6f921149103</id>
<content type='text'>
gc.enable/disable are now the same as CPython: they just control whether
automatic garbage collection is enabled or not.  If disabled, you can
still allocate heap memory, and initiate a manual collection.
</content>
</entry>
<entry>
<title>py: Clean up edge cases of malloc/realloc/free.</title>
<updated>2014-10-23T11:02:00+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-23T11:02:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=37378f8a9d2b358fdde0f3451d816b7f506846cc'/>
<id>urn:sha1:37378f8a9d2b358fdde0f3451d816b7f506846cc</id>
<content type='text'>
</content>
</entry>
</feed>
