- 10 Apr, 2014 2 commits
-
-
Damien George authored
-
Damien George authored
Labels should never be negative, and this modified type signature reflects that.
-
- 09 Apr, 2014 3 commits
-
-
Damien George authored
Needed to reinstate 2 delete opcodes, to specifically check that a local is not deleted twice.
-
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
This makes the runtime and object APIs more consistent. mp_store_subscr functionality now moved into objects (ie list and dict store_item).
-
Damien George authored
At this point, all opcodes are now implemented! Some del opcodes have been combined with store opcodes, with the value to store being MP_OBJ_NULL.
-
- 02 Apr, 2014 1 commit
-
-
Damien George authored
Very little has changed. In Python 3.4 they removed the opcode STORE_LOCALS, but in Micro Python we only ever used this for CPython compatibility, so it was a trivial thing to remove. It also allowed to clean up some dead code (eg the 0xdeadbeef in class construction), and now class builders use 1 less stack word. Python 3.4.0 introduced the LOAD_CLASSDEREF opcode, which I have not yet understood. Still, all tests (apart from bytecode test) still pass. Bytecode tests needs some more attention, but they are not that important anymore.
-
- 31 Mar, 2014 3 commits
-
-
Damien George authored
These are default arguments after a bare *.
-
Damien George authored
Adding this bytecode allows to remove 4 others related to function/method calls with * and ** support. Will also help with bytecodes that make functions/closures with default positional and keyword args.
-
Damien George authored
In preparation for implementing default keyword arguments.
-
- 30 Mar, 2014 1 commit
-
-
Damien George authored
Mostly just a global search and replace. Except rt_is_true which becomes mp_obj_is_true. Still would like to tidy up some of the names, but this will do for now.
-
- 27 Mar, 2014 4 commits
-
-
Damien George authored
-
Damien George authored
-
Damien George authored
Rationale: setting up the stack (state for locals and exceptions) is really part of the "code", it's the prelude of the function. For example, native code adjusts the stack pointer on entry to the function. Native code doesn't need to know n_state for any other reason. So putting the state size in the bytecode prelude is sensible. It reduced ROM usage on STM by about 30 bytes :) And makes it easier to pass information about the bytecode between functions.
-
Damien George authored
-
- 26 Mar, 2014 1 commit
-
-
Paul Sokolovsky authored
-
- 17 Mar, 2014 1 commit
-
-
xbe authored
Remove unnecessary includes. Add includes that improve portability.
-
- 20 Feb, 2014 1 commit
-
-
Paul Sokolovsky authored
Assuming we have truncating (floor) division, way to do ceiling division by N is to use formula (x + (N-1)) / N. Specifically, 63 bits, if stored 7 bits per byte, require exactly 9 bytes. 64 bits overflow that and require 10 bytes.
-
- 19 Feb, 2014 2 commits
-
-
Paul Sokolovsky authored
-
Paul Sokolovsky authored
-
- 16 Feb, 2014 1 commit
-
-
Paul Sokolovsky authored
For this, record argument names along with each bytecode function. The code still includes extensive debug logging support so far.
-
- 15 Feb, 2014 1 commit
-
-
Damien George authored
-
- 12 Feb, 2014 1 commit
-
-
Paul Sokolovsky authored
-
- 01 Feb, 2014 4 commits
-
-
Damien George authored
IS_NOT and NOT_IN are now compiled to IS + NOT and IN + NOT, with a new special NOT bytecode.
-
Damien George authored
Still todo: break/continue from within the finally block itself.
-
Damien George authored
-
Paul Sokolovsky authored
TODO: Decide if we really need separate bytecode for creating functions with default arguments - we would need same for closures, then there're keywords arguments too. Having all combinations is a small exponential explosion, likely we need just 2 cases - simplest (no defaults, no kw), and full - defaults & kw.
-
- 29 Jan, 2014 2 commits
-
-
Damien George authored
-
Damien George authored
LOAD_METHOD bug was: emitbc did not correctly calculate the amount of stack usage for a LOAD_METHOD operation. small int bug was: int was being used to pass small ints, when it should have been machine_int_t.
-
- 25 Jan, 2014 1 commit
-
-
Damien George authored
-
- 24 Jan, 2014 2 commits
-
-
Damien George authored
There can be multiple emitters allocated during compile (eg byte code and native).
-
Paul Sokolovsky authored
-
- 21 Jan, 2014 1 commit
-
-
Damien George authored
Can now have null bytes in strings. Can define ROM qstrs per port using qstrdefsport.h
-
- 19 Jan, 2014 1 commit
-
-
Damien George authored
Exceptions know source file, line and block name. Also tidy up some debug printing functions and provide a global flag to enable/disable them.
-
- 18 Jan, 2014 1 commit
-
-
Damien George authored
Byte code has a map from byte-code offset to source-code line number, used to give better error messages.
-
- 11 Jan, 2014 2 commits
-
-
Damien George authored
-
John R. Lenton authored
-
- 06 Jan, 2014 2 commits