- 25 May, 2014 1 commit
-
-
Damien George authored
This completes non-automatic interning of strings in the parser, so that doc strings don't take up RAM. It complicates the parser and compiler, and bloats stmhal by about 300 bytes. It's complicated because now there are 2 kinds of parse-nodes that can be strings: interned leaves and non-interned structs.
-
- 21 May, 2014 1 commit
-
-
Damien George authored
MP_ALLOC_* -> MICROPY_ALLOC_* MICROPY_PATH_MAX -> MICROPY_ALLOC_PATH_MAX MICROPY_ENABLE_REPL_HELPERS -> MICROPY_HELPER_REPL MICROPY_ENABLE_LEXER_UNIX -> MICROPY_HELPER_LEXER_UNIX MICROPY_EXTRA_* -> MICROPY_PORT_* See issue #35.
-
- 12 May, 2014 1 commit
-
-
Damien George authored
-
- 10 May, 2014 1 commit
-
-
Damien George authored
bytecode is the more widely used. See issue #590.
-
- 08 May, 2014 1 commit
-
-
Damien George authored
You can now do: X = const(123) Y = const(456 + X) and the compiler will replace X and Y with their values. See discussion in issue #266 and issue #573.
-
- 07 May, 2014 2 commits
-
-
Damien George authored
-
Damien George authored
Just a start, no working code yet. As per issue #573.
-
- 03 May, 2014 1 commit
-
-
Damien George authored
Blanket wide to all .c and .h files. Some files originating from ST are difficult to deal with (license wise) so it was left out of those. Also merged modpyb.h, modos.h, modstm.h and modtime.h in stmhal/.
-
- 27 Apr, 2014 5 commits
-
-
Damien George authored
-
Damien George authored
It's the same as LOAD_CONST_STR.
-
Damien George authored
Messages are still explanatory, while taking a little less ROM.
-
Damien George authored
New way uses slightly less ROM and RAM, should be slightly faster, and, most importantly, allows to catch the error "non-keyword arg following keyword arg". Addresses issue #466.
-
Damien George authored
Implements 'def f(*, a)' and 'def f(*a, b)', but not default keyword-only args, eg 'def f(*, a=1)'. Partially addresses issue #524.
-
- 26 Apr, 2014 1 commit
-
-
Damien George authored
-
- 25 Apr, 2014 1 commit
-
-
Damien George authored
Also add a few STATIC's to some compile functions that should have them. Addresses issue #521.
-
- 21 Apr, 2014 1 commit
-
-
Damien George authored
-
- 20 Apr, 2014 1 commit
-
-
Damien George authored
Closed over variables are now passed on the stack, instead of creating a tuple and passing that. This way memory for the closed over variables can be allocated within the closure object itself. See issue #510 for background.
-
- 17 Apr, 2014 1 commit
-
-
Damien George authored
mp_obj_t->subscr now does load/store/delete.
-
- 13 Apr, 2014 1 commit
-
-
Damien George authored
Attempt to address issue #386. unique_code_id's have been removed and replaced with a pointer to the "raw code" information. This pointer is stored in the actual byte code (aligned, so the GC can trace it), so that raw code (ie byte code, native code and inline assembler) is kept only for as long as it is needed. In memory it's now like a tree: the outer module's byte code points directly to its children's raw code. So when the outer code gets freed, if there are no remaining functions that need the raw code, then the children's code gets freed as well. This is pretty much like CPython does it, except that CPython stores indexes in the byte code rather than machine pointers. These indices index the per-function constant table in order to find the relevant code.
-
- 12 Apr, 2014 1 commit
-
-
Damien George authored
-
- 11 Apr, 2014 5 commits
-
-
Damien George authored
With new order of evaluation of defaults, creating the tuple was done in the wrong spot.
-
Damien George authored
-
Damien George authored
This simplifies the compiler a little, since now it can do 1 pass over a function declaration, to determine default arguments. I would have done this originally, but CPython 3.3 somehow had the default keyword args compiled before the default position args (even though they appear in the other order in the text of the script), and I thought it was important to have the same order of execution when evaluating default arguments. CPython 3.4 has changed the order to the more obvious one, so we can also change.
-
Damien George authored
-
Damien George authored
-
- 10 Apr, 2014 5 commits
-
-
Damien George authored
Working towards trying to support compile-time constants (see discussion in issue #227), this patch allows the compiler to look inside arbitrary uPy objects at compile time. The objects to search are given by the macro MICROPY_EXTRA_CONSTANTS (so they must be constant/ROM objects), and the constant folding occures on forms base.attr (both base and attr must be id's). It works, but it breaks strict CPython compatibility, since the lookup will succeed even without importing the namespace.
-
Damien George authored
Can do this now that the stack size calculation is improved.
-
Damien George authored
Much less of a hack now. Hopefully it's correct!
-
Damien George authored
Labels should never be negative, and this modified type signature reflects that.
-
Damien George authored
-
- 09 Apr, 2014 6 commits
-
-
Damien George authored
Needed to reinstate 2 delete opcodes, to specifically check that a local is not deleted twice.
-
Damien George authored
So we can add more flags.
-
Damien George authored
-
Damien George authored
-
Damien George authored
Small reduction in ROM, heap and stack usage.
-
Damien George authored
Convert int types to uint where sensible, and then to uint8_t or uint16_t where possible to reduce RAM usage.
-
- 08 Apr, 2014 2 commits
-
-
Damien George authored
-
Damien George authored
-
- 06 Apr, 2014 2 commits
-
-
Damien George authored
On x64, native emitter now passes 70 of the tests.
-
Damien George authored
Also add command line option to unix port to select emitter.
-