summaryrefslogtreecommitdiffstatshomepage
Commit message (Collapse)AuthorAge
* py: Compress a little the bytecode emitter structure.Damien George2014-05-10
|
* py, emitters: Fix dummy_data size for bytecode and thumb.Damien George2014-05-10
| | | | | | | Thumb uses a bit less RAM, bytecode uses a tiny bit more, to avoid overflow of the dummy buffer in certain cases. Addresses issue #599.
* Merge branch 'master' of github.com:micropython/micropythonDamien George2014-05-10
|\
| * objstr: Implement .lower() and .upper().Paul Sokolovsky2014-05-10
| |
* | stmhal: Improve handling of out-of-memory in REPL.Damien George2014-05-10
| | | | | | | | | | | | Addresses issue #558, but it's likely that other out-of-memory errors could crash the pyboard. Reason is that qstrs use m_new and can raise an exception within the parser.
* | py, lexer: Add allocation policy config; return NULL if can't allocate.Damien George2014-05-10
|/
* py: Improve handling of memory error in parser.Damien George2014-05-10
| | | | | | | | | | | Parser shouldn't raise exceptions, so needs to check when memory allocation fails. This patch does that for the initial set up of the parser state. Also, we now put the parser object on the stack. It's small enough to go there instead of on the heap. This partially addresses issue #558.
* builtinimport: Fix broken namespace imports due to dup vstr_cut_tail_bytes().Paul Sokolovsky2014-05-10
|
* builtinimport: Fix comment orphaned by one of previous commits.Paul Sokolovsky2014-05-10
|
* modsys: Enable sys.exit() per port after all.Paul Sokolovsky2014-05-10
|
* objset: Add frozenset tests, skippable if frozenset not available.Paul Sokolovsky2014-05-10
|
* run-tests: Add support for skipping tests.Paul Sokolovsky2014-05-10
| | | | MicrpPython test should print single "SKIP" line for test to be skipped.
* stmhal: Implement draft version of sys.exit().Paul Sokolovsky2014-05-10
|
* modsys, unix: Add sys.exit(), should be implemented by a port.Paul Sokolovsky2014-05-10
|
* py: Disable frozenset by default, enable on unix.Paul Sokolovsky2014-05-10
| | | | Takes 416 text bytes on x86.
* objset: Give up and implement frozenset.Paul Sokolovsky2014-05-10
| | | | Tired of patching CPython stdlib for it.
* objtype: Don't treat inheritance from "object" as from native type.Paul Sokolovsky2014-05-10
| | | | | | | | | | | "object" type in MicroPython currently doesn't implement any methods, and hopefully, we'll try to stay like that for as long as possible. Even if we have to add something eventually, look up from there might be handled in adhoc manner, as last resort (that's not compliant with Python3 MRO, but we're already non-compliant). Hence: 1) no need to spend type trying to lookup anything in object; 2) no need to allocate subobject when explicitly inheriting from object; 3) and having multiple bases inheriting from object is not a case of incompatible multiple inheritance.
* py: Tidy up returning NULL which should be MP_OBJ_NOT_SUPPORTED.Damien George2014-05-10
|
* bare-arm: Change output file from flash.elf to firmware.elf.Damien George2014-05-10
|
* py: Combine native emitters to 1 glue function; distinguish viper.Damien George2014-05-10
| | | | | | | | This patch simplifies the glue between native emitter and runtime, and handles viper code like inline assember: return values are converted to Python objects. Fixes issue #531.
* stmhal: Fix setting of RTC: was BCD now BIN encoded.Damien George2014-05-10
| | | | Addresses issue #592.
* stm: Reorder mpconfig.h header inclusion to get stm building.Damien George2014-05-10
|
* py: Rename byte_code to bytecode everywhere.Damien George2014-05-10
| | | | bytecode is the more widely used. See issue #590.
* py: Fix base "detection" for int('0<hexdigit>', 16).Paul Sokolovsky2014-05-10
|
* bytes: Implement comparison and other binary operations.Paul Sokolovsky2014-05-10
| | | | Should support everything supported by strings.
* runtime0.h: Group binary ops by fives.Paul Sokolovsky2014-05-10
| | | | So one has some chance to convert numeric op code into symbol.
* Merge pull request #575 from stinos/windows-modtimePaul Sokolovsky2014-05-09
|\ | | | | Add modtime implementation for mingw
| * windows: Add modtime implementationstijn2014-05-09
|/
* Merge branch 'pfalcon-README-features-overview'Damien George2014-05-09
|\
| * README: Add articles, and update doc for deploying firmware.Damien George2014-05-09
| |
| * README: Add short overview of Python features supported.Paul Sokolovsky2014-05-09
|/ | | | Also, "upgrade" project to "early beta", and elaborate pyboard description.
* Add gc.enable, gc.disable; remove pyb.gc.Damien George2014-05-08
|
* stmhal: Add time.time() and time.localtime().Damien George2014-05-08
| | | | | | | time.time: returns seconds since 1/1/2000, as an integer. time.localtime: Returns 8-tuple: (year, month, date, hour, minute, second, weekday, yearday).
* Merge pull request #568 from stinos/windows-msvc-portPaul Sokolovsky2014-05-09
|\ | | | | Windows MS Visual C port
| * Windows MSVC portstijn2014-05-08
| | | | | | | | Extend the windows port so it compiles with the toolchain from Visual Studio 2013
* | py, compiler: Add basic support for A=const(123).Damien George2014-05-08
|/ | | | | | | | | | | 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.
* qemu-arm: fully integrated test suite.Ilya Dmitrichenko2014-05-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is primarily intended to provide testing of Thumb-specific code within Travis CI as well as if anyone else want to run it locally. As discussed in purposes. This is currently agains an emulated Cortex-M3 core, however in the near future it can extended to support M0, M0+ as well M4 (work in progress exists in sushihangover/qemu). It's probably true that most of the code base can be covered running uPy natively on a POSIX system, however we do have the tiny bit of assembly code. There may exist bugs related to endianness and type aliases, let alone potential standard library or compiler bugs or even architecture-specific optimisations. This could also incorporate lwIP (or other TCP/IP stack) integration as well as SDIO+FATFS drivers. The solution to inline the test cases was chose due to simplicity. It could alternatively be implemented in a number of different way (see #515), but this looked the simplest. Inclusion of tinytest was just to avoid writing boilerplate code for counting failed tests and other utility functions. Currently only a few functions are used, however this could be extended. Checking in the code instead of using submodule was a personal preference, but if people do want the pain of submodules, this can provided. This particular framework is also pretty good if one desires to run unit test on target. The approach with scripts being inlined is probably not quite suited for the size of memory an MCU has, but the tinytest itself should be good, if lower-level C code is to be unit tested.
* tools: inline test suite generator.Ilya Dmitrichenko2014-05-08
|
* tools: check-in errordeveloper/tinytest@eb2dbc858f6c3785468a96e98f2b944f10013163Ilya Dmitrichenko2014-05-08
|
* py: Fix stack access in thumb native emitter.Damien George2014-05-07
|
* Merge pull request #584 from stinos/windows-inputPaul Sokolovsky2014-05-07
|\ | | | | windows: Fix input.c missing in Makefile after changes for #582
| * windows: Fix input.c missing in Makefile after changes for #582stijn2014-05-07
| |
* | tests/bench: Add testcase for positional/kwargs to enumerate().Paul Sokolovsky2014-05-07
| | | | | | | | | | Inspired by discussion in #577. So, in this case of builtin function, passing args by keyword has less than 1% overhead.
* | tests/bench: Add tests for various ways to pass function args.Paul Sokolovsky2014-05-07
| | | | | | | | | | Passing 3 args with keywords is for example 50% slower than via positional args.
* | tests/bench: Add variation on loop_count/while_down_ne test.Paul Sokolovsky2014-05-07
| |
* | tests/bench: Add testcases for lookup in 5-el instance and namedtuple.Paul Sokolovsky2014-05-07
| | | | | | | | | | | | | | | | | | | | | | ... and we have not that bad mapping type after all - lookup time is ~ the same as in one-attr instance. My namedtuple implementation on the other hand degrades awfully. So, need to rework it. First observation is that named tuple fields are accessed as attributes, so all names are interned at the program start. Then, really should store field array as qstr[], and do quick 32/64 bit scan thru it.
* | tests/bench: Time namedtuple field access.Paul Sokolovsky2014-05-07
|/ | | | That's higher than instance field access - behold the power of hashing.
* py: Fix emitcpy, to work with latest changes to PASS variables.Damien George2014-05-07
|
* tests: Add a test for native code on pyboard.Damien George2014-05-07
|
* tests: Add inline assembler test for pyboard.Damien George2014-05-07
|