summaryrefslogtreecommitdiff
path: root/tools/mpy-tool.py
AgeCommit message (Collapse)Author
2017-08-16tools/mpy-tool.py: Fix missing argument in dump() functionstijn
This makes the -d commandline argument usable again. Pass empty string as parent name as listing starts from the root.
2017-08-12tools/mpy-tool.py: Don't generate const_table if it's empty.Damien George
2017-05-16tools/mpy-tool.py: Fix regression with freezing floats in obj repr C.Damien George
Regression was introduced by ec534609f665cb791b8fc1eae1a44e514c297659
2017-05-13tools/mpy-tool.py: Use MP_ROM_xxx macros to support nanbox builds.Damien George
2017-05-01tools/mpy-tool: Make work if run from another directory.Paul Sokolovsky
By making sure we don't add relative paths to sys.path.
2017-04-22py: Add LOAD_SUPER_METHOD bytecode to allow heap-free super meth calls.Damien George
This patch allows the following code to run without allocating on the heap: super().foo(...) Before this patch such a call would allocate a super object on the heap and then load the foo method and call it right away. The super object is only needed to perform the lookup of the method and not needed after that. This patch makes an optimisation to allocate the super object on the C stack and discard it right after use. Changes in code size due to this patch are: bare-arm: +128 minimal: +232 unix x64: +416 unix nanbox: +364 stmhal: +184 esp8266: +340 cc3200: +128
2017-02-17py/persistentcode: Bump .mpy version due to change in bytecode.Damien George
2017-01-05tools/mpy-tool.py: Add support for OPT_CACHE_MAP_LOOKUP_IN_BYTECODE.Damien George
With caching of map lookups in the bytecode, frozen bytecode can still work but must be stored in RAM, not ROM. This patch allows mpy-tool.py to generate code that works with this optimisation, but it's not recommended to use it on embedded targets (because of lack of RAM).
2016-09-23py: Update opcode format table because 3 opcodes were removed, 1 added.Damien George
LIST_APPEND, MAP_ADD and SET_ADD have been removed, and STORE_COMP has been added in adaf0d865cd6c81fb352751566460506392ed55f.
2016-09-03tools/mpy-tool.py: Support freezing of complex numbers.Damien George
2016-09-02tools/mpy-tool.py: Compute the hash value for str/bytes objects.Damien George
This makes it more efficient at runtime to hash str/bytes objects.
2016-09-02tools/mpy-tool.py: Store qstr config values in global config object.Damien George
Makes it easier to access them without passing around another dict of the config values.
2016-08-10tools/mpy-tool.py: Support freezing float literals with obj-repr C.Damien George
The tool now generates code for freezing floats in obj-repr A, B or C, with the specific representation detected at compile time using macros.
2016-05-23tools/mpy-tool.py: Don't strip directories from the frozen source name.Damien George
Directories are now supported by the frozen import system (to implement frozen packages) so we should keep them.
2016-05-23tools/mpy-tool.py: Include .py extension in frozen filename.Damien George
So that it can be correctly stat'd when looking for frozen files.
2016-05-16tools/mpy-tool.py: Add checks for critical configuration vars.Damien George
When an mpy file is frozen it must know the values of certain configuration variables. This patch provides an explicit check in the generated C file that the configuration variables are what they are supposed to be.
2016-05-03tools/mpy-tool: Make sure that all C-level variables are unique.Damien George
Fixes issue #2023.
2016-04-15tools/mpy-tool.py: Add support for Python 2.7.Damien George
2016-04-13tools: Add mpy-tool.py, to work with .mpy files.Damien George
Currently it can freeze .mpy files.