summaryrefslogtreecommitdiffstatshomepage
Commit message (Collapse)AuthorAge
* py: Increase fixed size of stack-info in native emitter.Damien George2015-03-26
| | | | This is a temporary fix.
* py, compiler: When just bytecode, make explicit calls instead of table.Damien George2015-03-26
| | | | | | | | | | | | | | | | | | When just the bytecode emitter is needed there is no need to have a dynamic method table for the emitter back-end, and we can instead directly call the mp_emit_bc_XXX functions. This gives a significant reduction in code size and a very slight performance boost for the compiler. This patch saves 1160 bytes code on Thumb2 and 972 bytes on x86, when native emitters are disabled. Overall savings in code over the last 3 commits are: bare-arm: 1664 bytes. minimal: 2136 bytes. stmhal: 584 bytes (it has native emitter enabled). cc3200: 1736 bytes.
* py, compiler: Remove emit_pass1 code, using emit_bc to do its job.Damien George2015-03-26
| | | | | | | | | | | | | | | First pass for the compiler is computing the scope (eg if an identifier is local or not) and originally had an entire table of methods dedicated to this, most of which did nothing. With changes from previous commit, this set of methods can be removed and the methods from the bytecode emitter used instead, with very little modification -- this is what is done in this commit. This factoring has little to no impact on the speed of the compiler (tested by compiling 3763 Python scripts and timing it). This factoring reduces code size by about 270-300 bytes on Thumb2 archs, and 400 bytes on x86.
* py, compiler: Refactor load/store/delete_id logic to reduce code size.Damien George2015-03-26
| | | | Saves around 230 bytes on Thumb2 and 750 bytes on x86.
* cc3200: Minor refactorings on modwlan and pybsleep.Daniel Campora2015-03-26
|
* cc3200: Reenable active interrupts when waking from suspended mode.Daniel Campora2015-03-26
|
* objdict: Cast mp_obj_t to concrete types explicitly.Paul Sokolovsky2015-03-26
| | | | Continuation of refactoring applied previously to objlist.
* cc3200: Add callback support to the UART for RX interrupts.Daniel Campora2015-03-26
|
* cc3200: Remove superflous parameters from the SPI API.Daniel Campora2015-03-26
|
* tests: Skip some new tests when testing native emitter.Damien George2015-03-25
|
* tests: Add tests for SyntaxError, TypeError, and other missing things.Damien George2015-03-25
| | | | This is intended to improve coverage of the test suite.
* py: Fix bug in compiler which allowed through illegal augmented assign.Damien George2015-03-25
| | | | It allowed such things as (a, b) += c.
* py: Clean up some logic in VM to remove assert(0)'s.Damien George2015-03-25
| | | | Saves around 30 bytes code on Thumb2 archs.
* py: Simplify some logic in compiler; add comments about CPython compat.Damien George2015-03-25
|
* cc3200: Remove superflous params from the I2C API.Daniel Campora2015-03-25
|
* cc3200: Add GPIO25 to the pins list of the WiPy and the WiPy-SD.Daniel Campora2015-03-25
| | | | | | This allows to properly initialize the system led and add it to the sleep module so that it can be restored when resuming from suspended mode.
* cc3200: Rename the WiPy_SD to WiPy-SD.Daniel Campora2015-03-25
|
* cc3200: Roll back to the previous telnet and ftp timeouts.Daniel Campora2015-03-25
| | | | | | | | Unfortunately, these timeouts are the only realiable way (for now), to be able to detect broken connections due to half-open sockets. Such a thing occurs when getting out of the WiFi coverage area or when disconnecting from the AP (sometimes the client doesn't send the disconnect packet).
* cc3200: Keep WLAN enabled during the soft reset.Daniel Campora2015-03-25
|
* cc3200: Remove the cc3200.xml file. Latest CCS already ships with it.Daniel Campora2015-03-25
|
* py: Cast mp_obj_t to concrete types explicitly.Paul Sokolovsky2015-03-25
| | | | | | | | | | | mp_obj_t internal representation doesn't have to be a pointer to object, it can be anything. There's also a support for back-conversion in the form of MP_OBJ_UNCAST. This is kind of optimization/status quo preserver to minimize patching the existing code and avoid doing potentially expensive MP_OBJ_CAST over and over. But then one may imagine implementations where MP_OBJ_UNCAST is very expensive. But such implementations are unlikely interesting in practice.
* docs: uctypes: Describe couple more functions.Paul Sokolovsky2015-03-24
|
* stmhal: Optimise ADC.read_timed() so that it can sample up to 750kHz.Damien George2015-03-23
|
* objnamedtuple: Accept field list as a string.Paul Sokolovsky2015-03-23
| | | | | This change is required to unbreak some CPython stdlib modules (as included into micropython-lib).
* objstr: Expose mp_obj_str_split() for reuse in other modules.Paul Sokolovsky2015-03-23
|
* unix: Remove -Wdouble-promotion from main build, and 2 from coverage.Damien George2015-03-22
| | | | | The 2 removed from coverage build are: -Wredundant-decls and -Wstrict-prototypes.
* stmhal: Correctly clear wake-up flag before entering standby mode.Damien George2015-03-22
|
* objnamedtuple: Check that 2nd arg to namedtuple() is a list.Paul Sokolovsky2015-03-22
|
* stmhal: Expose all PYBv1.0 pins, include SD and USB pins.Damien George2015-03-22
| | | | | To have proper low power mode, need to configure all unused pins in input mode, so need to have them available.
* stmhal: Put flash in deep power-down mode when entering stop mode.Damien George2015-03-22
| | | | This can get PYBv1.0 stop current down to around 290uA.
* cc3200: Fix bug in telnet that caused the rx buffer to overflow.danicampora2015-03-22
|
* py: Combine duplicated code that converts members from a lookup.Damien George2015-03-21
| | | | | | | | | | | | Despite initial guess, this code factoring does not hamper performance. In fact it seems to improve speed by a little: running pystone(1.2) on pyboard (which gives a very stable result) this patch takes pystones from 1729.51 up to 1742.16. Also, pystones on x64 increase by around the same proportion (but it's much noisier). Taking a look at the generated machine code, stack usage with this patch is unchanged, and call is tail-optimised with all arguments in registers. Code size decreases by about 50 bytes on Thumb2 archs.
* cc3200: Reduce soft reset time. WLAN is not reinit, just reenabled.danicampora2015-03-21
|
* cc3200: Improve usability and robustness of the servers.danicampora2015-03-21
|
* cc3200: Remove superfluous code in pybsleep.danicampora2015-03-21
|
* cc3200: Add SPI module.danicampora2015-03-21
| | | | | Only MASTER mode is supported. Transfer width is configurable to 8, 16 or 32 bits.
* cc3200: Re-name pybsystick to mpsystick.danicampora2015-03-21
|
* unix: Bump stack limit and adjust for 64-bitness.Paul Sokolovsky2015-03-21
| | | | Without that, "import http.client" failed due to max recursion.
* tests: Make pyb/timer test check callback timing properly.Damien George2015-03-20
|
* stmhal: Fix a bug related to unhandled channel interrupts.Dave Hylands2015-03-20
| | | | | This also cleans up spurious interrupts which happen at timer initilaization time.
* py: Allow retrieving a function's __name__.stijn2015-03-20
| | | | Disabled by default. Enabled on unix and stmhal ports.
* runtime: mp_load_method_maybe(): Don't use confusing "base" term.Paul Sokolovsky2015-03-21
| | | | | | | "Base" should rather refer to "base type"."Base object for attribute lookup" should rather be just "object". Also, a case of common subexpression elimination.
* unix: When using separate obj output dirs, make -B is no longer relevant.Paul Sokolovsky2015-03-21
|
* unix: Move compiler warnings from production build to coverage build.Damien George2015-03-20
|
* stmhal: Remove some unnecessary declarations, purely for cleanup.Damien George2015-03-20
|
* objlist: list_reverse(): Fix typesafety error.Paul Sokolovsky2015-03-20
|
* tests: Adjust expected output, since Travis can't do git describe.Damien George2015-03-20
|
* py: Clarify API for map/set lookup when removing&adding at once.Damien George2015-03-20
| | | | Addresses issue #1160.
* tests: Add basic test for OrderedDict.Paul Sokolovsky2015-03-20
| | | | Mostly to have coverage of newly added code in map.c.
* py: Implement core of OrderedDict type.Paul Sokolovsky2015-03-20
| | | | | | | | | | | | Given that there's already support for "fixed table" maps, which are essentially ordered maps, the implementation of OrderedDict just extends "fixed table" maps by adding an "is ordered" flag and add/remove operations, and reuses 95% of objdict code, just making methods tolerant to both dict and OrderedDict. Some things are missing so far, like CPython-compatible repr and comparison. OrderedDict is Disabled by default; enabled on unix and stmhal ports.