summaryrefslogtreecommitdiff
path: root/unix
AgeCommit message (Collapse)Author
2014-06-05unix: Add setjmp-based GC register helper implementation.Paul Sokolovsky
As I suspected for a long time, for x86, register helper doesn't really make any difference - there's simply not enough register to keep anything in them for any prolonged time. Anything gets pushed on stack anyway. So, on x86, uPy passed all tests even with empty reg helper. So, this setjmp implementation goes as "untested".
2014-06-03py: Instead of having "debug on" var, have "optimization level" var.Paul Sokolovsky
This allows to have multiple "optimization" levels (CPython has two (-OO removes docstrings), we can have more).
2014-06-03unix: Properly print script filename in case of error.Paul Sokolovsky
2014-06-01Rename bultins config variables to MICROPY_PY_BUILTINS_*.Damien George
This renames: MICROPY_PY_FROZENSET -> MICROPY_PY_BUILTINS_FROZENSET MICROPY_PY_PROPERTY -> MICROPY_PY_BUILTINS_PROPERTY MICROPY_PY_SLICE -> MICROPY_PY_BUILTINS_SLICE MICROPY_ENABLE_FLOAT -> MICROPY_PY_BUILTINS_FLOAT See issue #35 for discussion.
2014-05-31unix: 64-bit cleanness.Paul Sokolovsky
2014-05-31unix: Add poorman's stack usage info to mem_info() dump.Paul Sokolovsky
2014-05-31modsocket: Add some comments on intended usage/API design of module.Paul Sokolovsky
2014-05-31modsocket: Remove stale ifdef.Paul Sokolovsky
2014-05-28unix/gccollect.c: Make Clang workaround apply only to it. Unbreaks gcc builds.Paul Sokolovsky
2014-05-28Revert "Fix DEBUG=1 builds"Paul Sokolovsky
This reverts commit 6e76f7bc90fcd130db888f8804b8555dc8f3a484. This patch tries to workaround a previous clang workaround. Instead of going into workaround of workaround spiral, the original workaround should be tamed.
2014-05-26Fix DEBUG=1 buildsDave Hylands
Without this fix, I get the following error: CC gccollect.c gccollect.c: In function ‘gc_helper_get_regs’: gccollect.c:63:1: error: bp cannot be used in asm here
2014-05-26modos: stat(): Accept bytes argument.Paul Sokolovsky
2014-05-25Change const byte* to const char* where sensible.Damien George
This removes need for some casts (at least, more than it adds need for new casts!).
2014-05-24Add SystemExit exception and use it in unix/ and stmhal/ ports.Damien George
Addresses issue #598.
2014-05-24Rename configuration variables controling Python features.Damien George
Now of the form MICROPY_PY_*. See issue #35.
2014-05-24modsocket: 64-bit cleanness.Paul Sokolovsky
2014-05-24unix modsocket: Make .makefile() method more compliant.Paul Sokolovsky
.makefile() should allow to specify which stream time to create - byte or text.
2014-05-21unix: Fix casting issue, int to small int object.Damien George
2014-05-21Tidy up some configuration options.Damien George
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.
2014-05-21unix, Mac support: Generate order.def via Makefile.Damien George
2014-05-21Merge pull request #607 from Anton-2/osx-clangDamien George
Allow compilation of unix port under clang on OS X
2014-05-19py: Implement proper separation between io.FileIO and io.TextIOWrapper.Paul Sokolovsky
io.FileIO is binary I/O, ans actually optional. Default file type is io.TextIOWrapper, which provides str results. CPython3 explicitly describes io.TextIOWrapper as buffered I/O, but we don't have buffering support yet anyway.
2014-05-15modos: Clean 64-bit issues.Paul Sokolovsky
2014-05-14unix: Add "_os" module with stat().Paul Sokolovsky
stat() is bad function to use using FFI, because its ABI is largely private. To start with, Glibc .so doesn't even have "stat" symbol. Then, layout of struct stat is too implementation-dependent. So, introduce _os to deal with stat() and other similar cases.
2014-05-13Merge pull request #600 from stinos/unix-exitcodeDamien George
unix: Use standard return codes for main
2014-05-13py, unix: Add copyright for modules I worked closely on.Paul Sokolovsky
2014-05-12unix: Implement -O option to turn off __debug__ flag.Damien George
2014-05-12py: Rename BYTE_CODE to BYTECODE (this was missed in previous rename).Damien George
2014-05-13unix: Fix linker errors when time/ffi modules are disabledstijn
When disabling these via mpconfigport.mk or on the commandline, the correspoding build options are not set and the sources are not built so the modules should not be added to the MICROPY_EXTRA_BUILTIN_MODULES list since they are undefined.
2014-05-12Fix some unused variables, and silence a clang warning about initialization ↵Antonin ENFRUN
override in vmentrytable.h
2014-05-12unix: Add asm statements needed to read registers with clang. Code generated ↵Antonin ENFRUN
by gcc 4.9.0 is unchanged (same statements, different order). Both are inefficient, saving unmodified registers on the stack.
2014-05-12unix: Create __bss_start and _end symbols for Mach-O targets.Antonin ENFRUN
It's a hack, but can't find a cleaner way to do it.
2014-05-11unix: Use standard return codes for mainstijn
As in the CPython manual: "Unix programs generally use 2 for command line syntax errors and 1 for all other kind of errors"
2014-05-11py: Rename MICROPY_SYS_EXIT to MICROPY_MOD_SYS_EXIT.Damien George
For consistency with MICROPY_MOD_SYS_STDFILES, etc.
2014-05-11Merge pull request #597 from stinos/mingw-compilationDamien George
mingw: Fix compilation issues
2014-05-10modsys: Enable sys.exit() per port after all.Paul Sokolovsky
2014-05-10modsys, unix: Add sys.exit(), should be implemented by a port.Paul Sokolovsky
2014-05-10py: Disable frozenset by default, enable on unix.Paul Sokolovsky
Takes 416 text bytes on x86.
2014-05-10mingw: Fix compilation issuesstijn
- use lowercase windows.h - fix for mingw32 using preprocessor-unfriendly definition of CLOCKS_PER_SEC
2014-05-09windows: Add modtime implementationstijn
2014-05-07unix: Add missing stdio.h header for readline.Damien George
2014-05-07Add input command for unixDave Hylands
2014-05-07stream: Make non-blcoking stream support configurable.Paul Sokolovsky
Enable only on unix. To avoid unpleasant surprises with error codes.
2014-05-07unix modsocket: Add comments re: recv() vs read(), etc. semantics.Paul Sokolovsky
2014-05-06modgc: Add new module for GC-related functionality.Paul Sokolovsky
2014-05-05py, unix: Add -v option, print bytecode dump if used.Paul Sokolovsky
This will work if MICROPY_DEBUG_PRINTERS is defined, which is only for unix/windows ports. This makes it convenient to user uPy normally, but easily get bytecode dump on the spot if needed, without constant recompiles back and forth. TODO: Add more useful debug output, adjust verbosity level on which specifically bytecode dump happens.
2014-05-04unix: Remove test class and code.Damien George
2014-05-03Add license header to (almost) all files.Damien George
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/.
2014-05-03py, stream: Implement readlines for a stream.Damien George
2014-05-03Don't print git hash as well as git tag in banner.v1.0Damien George