summaryrefslogtreecommitdiff
path: root/unix
AgeCommit message (Collapse)Author
2014-11-29Use MP_DEFINE_CONST_DICT macro to define module dicts.Damien George
This is just a clean-up of the code. Generated code is exactly the same.
2014-11-29modubinascii: Add, with hexlify() implementation.Paul Sokolovsky
2014-11-22moduhashlib: Initial module skeleton.Paul Sokolovsky
2014-11-16py: Make stream seek correctly check for ioctl fn; add seek for textio.Damien George
2014-11-17stream: Implement seek operation support via ioctl, wrapped in generic method.Paul Sokolovsky
Also, implement for unix port.
2014-11-05unix: Allow -X heapsize number take 'w' specifier for word size adjustment.Paul Sokolovsky
The specifier should go after the number, before size suffix like 'k' or 'm'. E.g.: "-X heapsize=100wk" will use 100K heap on 32-bit system and 200K - on 64-bit.
2014-11-05unix: fast: Set initial module dict size big to have high pystone score.Paul Sokolovsky
For this, introduce MICROPY_MODULE_DICT_SIZE config setting.
2014-11-02unix: Provide "fast" target to build interpreter for benchmarking.Paul Sokolovsky
This build is primarily intended for benchmarking, and may have random features enabled/disabled to get high scores in synthetic benchmarks. The intent is to show/prove that MicroPython codebase can compete with CPython, when configured appropriately. But the main MicroPython aim still remains to optimize for memory usage (which inevitibly leads to performance degradation in some areas on some workloads).
2014-10-31py: Make gc.enable/disable just control auto-GC; alloc is still allowed.Damien George
gc.enable/disable are now the same as CPython: they just control whether automatic garbage collection is enabled or not. If disabled, you can still allocate heap memory, and initiate a manual collection.
2014-10-29Add -Wpointer-arith flag to prevent problems with pointer arithmetic on void*stijn
2014-10-26unix: Make -v dump memory info at exit.Paul Sokolovsky
Also, move bytecode dumps to -v -v, because they're too verbose for just -v.
2014-10-26unix: Implement -m option (execute module from stdlib).Paul Sokolovsky
Support for packages as argument not implemented, but otherwise error and exit handling should be correct. This for example will allow to do: pip-micropython install micropython-test.pystone micropython -m test.pystone
2014-10-26unix/windows: Disable sigaction on windows port.Damien George
2014-10-25py: Add mp_pending_exception global variable, for VM soft interrupt.Damien George
This allows to implement KeyboardInterrupt on unix, and a much safer ctrl-C in stmhal port. First ctrl-C is a soft one, with hope that VM will notice it; second ctrl-C is a hard one that kills anything (for both unix and stmhal). One needs to check for a pending exception in the VM only for jump opcodes. Others can't produce an infinite loop (infinite recursion is caught by stack check).
2014-10-25py: Implement compile builtin, enabled only on unix port.Damien George
This should be pretty compliant with CPython, except perhaps for some corner cases to do with globals/locals context. Addresses issue #879.
2014-10-25unix: Allow -X heapsize= option take numbers with K & M suffixes.Paul Sokolovsky
For kilobytes and megabytes respectively.
2014-10-24py: Improve memory usage debugging; better GC AT dumping.Damien George
In unix port, mem_info(1) now prints pretty GC alloc table.
2014-10-23py: Add builtin memoryview object (mostly using array code).Damien George
2014-10-22extmod: Add uheapq module.Damien George
2014-10-21Implement kwargs for builtin open() and _io.FileIOstijn
This makes open() and _io.FileIO() more CPython compliant. The mode kwarg is fully iplemented. The encoding kwarg is allowed but not implemented; mainly to allow the tests to specify encoding for CPython, see #874
2014-10-18unix, stmhal: Implement file.readinto() method.Paul Sokolovsky
Also, usocket.readinto(). Known issue is that .readinto() should be available only for binary files, but micropython uses single method table for both binary and text files.
2014-10-17unix: Make -c option parse input script as a file, as per CPython.Damien George
Addresses issue #915.
2014-10-13moduzlib: Integrate into the system.Paul Sokolovsky
2014-10-11Merge branch 'modure' of https://github.com/pfalcon/micropython into ↵Damien George
pfalcon-modure
2014-10-11unix: Update comment MICROPY_GCREGS_SETJMP (untested -> undertested).Paul Sokolovsky
2014-10-11unix: Add comment about needed dependencies for MICROPY_FORCE_32BIT.Paul Sokolovsky
2014-10-11modure: Initial module, using re1.5 (which is based on re1 codebase).Paul Sokolovsky
https://github.com/pfalcon/re1.5
2014-10-09unix: Rename "microsocket" module to "usocket".Paul Sokolovsky
Per new conventions, we'd like to consistently use "u*" naming conventions for modules which don't offer complete CPython compatibility, while offer subset or similar API.
2014-10-07Allow real memory errors (from locked gc) to be reported with traceback.Dave Hylands
2014-10-05unix: Detect and print compile error.Damien George
2014-10-03py: Change [u]int to mp_[u]int_t in qstr.[ch], and some other places.Damien George
This should pretty much resolve issue #50.
2014-10-01unix: Do a proper clean-up on sys.exit/SystemExit.Damien George
Addresses issue #859.
2014-09-29unix: Remove unnecessary #defines from config.Damien George
2014-09-25py: For malloc and vstr functions, use size_t exclusively for int type.Damien George
It seems most sensible to use size_t for measuring "number of bytes" in malloc and vstr functions (since that's what size_t is for). We don't use mp_uint_t because malloc and vstr are not Micro Python specific.
2014-09-23Clean up logical flow for setting LDFLAGS to build for Linux and OSXblmorris
Add more specific comments describing what is going on.
2014-09-22Incorporate change in assignment logic suggested by dhylandsblmorris
2014-09-22Fix unix/Makefile to build on OSXblmorris
Force OSX to compile with clang even if gcc is available Change LDFLAGS syntax to be compatible with clang Fix questionable syntax on line 90 Remove extraneous tab character
2014-09-17py: Add native json printing using existing print framework.Damien George
Also add start of ujson module with dumps implemented. Enabled in unix and stmhal ports. Test passes on both.
2014-09-15py: Move definition of mp_sys_exit to core.Damien George
sys.exit always raises SystemExit so doesn't need a special implementation for each port. If C exit() is really needed, use the standard os._exit function. Also initialise mp_sys_path and mp_sys_argv in teensy port.
2014-09-06unix: Fix modffi to be able to return double on x86 machines.Damien George
2014-09-06py: Add support for emitting native x86 machine code.Damien George
2014-09-06unix: Don't use -Wno-error=cpp or #warning; fix strict alias warning.Damien George
For the sake of older versions of gcc (and other compilers), don't use the #warning CPP directive, nor the -Wno-error=cpp option. Also, fix a strict alias warning in modffi.c for older compilers, and add a test for ffi module. Addresses issue #847.
2014-09-03Code style/whitespace cleanup; remove obsolete headers.Damien George
And move the MAP_ANON redefinition from py/asmx64.c to unix/alloc.c.
2014-09-03unix: Auto-detect MICROPY_EMIT_X64 and MICROPY_GCREGS_SETJMP.Damien George
If not set, MICROPY_EMIT_X64 is set only if on x86-64 machine. If not set, MICROPY_GCREGS_SETJMP is set when on MIPS.
2014-09-03Add cache flush in py/asmarm.c and add new MP_PLAT_ALLOC_EXEC and ↵Fabian Vogt
MP_PLAT_FREE_EXEC macros Fixes issue #840
2014-08-30py: Change uint to mp_uint_t in runtime.h, stackctrl.h, binary.h.Damien George
Part of code cleanup, working towards resolving issue #50.
2014-08-30py: Change all uint to mp_uint_t in obj.h.Damien George
Part of code cleanup, working towards resolving issue #50.
2014-08-30py: Make tuple and list use mp_int_t/mp_uint_t.Damien George
Part of code cleanup, to resolve issue #50.
2014-08-30Change some parts of the core API to use mp_uint_t instead of uint/int.Damien George
Addressing issue #50, still some way to go yet.
2014-08-26Add pip-micropython to unix make install.Damien George
Also add -t/--target option to pip-micropython to allowing installing to the pyboard. Thanks to turbinenreiter/Sebastian Plamauer for the patch.