Paul Sokolovsky
04c27e5eaa
lib/utils/pyexec: Use full path to readline.h header, per latest conventions.
8 years ago
Paul Sokolovsky
c3f519adfe
tests/extmod/machine_pinbase: Skip if machine.PinBase is not available.
8 years ago
Paul Sokolovsky
bd6622abe8
unix: Cache libaxtls.a in local build dir.
Allows to build the library variant for other ports in parallel.
8 years ago
Paul Sokolovsky
6aa7c805cc
esp8266: Cache Xtensa-built libaxtls.a in local build dir.
Allows to build the library variant for other archs in parallel.
8 years ago
Paul Sokolovsky
bcd0e9a7fa
esp8266/moduos: Add rmdir() function.
8 years ago
Paul Sokolovsky
0a6f599cf2
extmod/vfs_fat: Implement rmdir() method.
Shares the code with remove() method due to the same underlying f_unlink()
FatFs operation.
8 years ago
Paul Sokolovsky
780114e398
extmod/modussl_axtls: Add dummy setblocking() method.
Accepts only value of True.
8 years ago
Paul Sokolovsky
0b52228739
tests: Add test for extended arguments to stream .write() method.
8 years ago
Paul Sokolovsky
ad9b9c7621
py/stream: Implement 2- and 3-arg write() method as an extension to CPython.
3-arg form:
stream.write(data, offset, length)
2-arg form:
stream.write(data, length)
These allow efficient buffer writing without incurring extra memory
allocation for slicing or creating memoryview() object, what is
important for low-memory ports.
All arguments must be positional. It might be not so bad idea to standardize
on 3-arg form, but 2-arg case would need check and raising an exception
anyway then, so instead it was just made to work.
8 years ago
Paul Sokolovsky
be313ea215
esp8266: Select axTLS for SSL implementation, following recent refactor.
8 years ago
Paul Sokolovsky
20283aec10
extmod/modussl_axtls: Further changes to allow alternative SSL modules.
Make variable MICROPY_SSL_AXTLS=1 should be defined to activate modussl_axtls
and link with -laxtls.
8 years ago
Paul Sokolovsky
e32d1e17bb
extmod/modussl: Rename to modussl_axtls.c, to allow impl using other SSL libs.
8 years ago
Damien George
dfe056df6f
drivers/wiznet5k: Fix indentation so it's not misleading.
Otherwise gcc 6.1.1 raises a misleading-indentation error.
8 years ago
Damien George
ee622cc1ed
unix/mpthreadport: Adjust minimum thread stack, and stack limit check.
The minimum thread stack size is set by pthreads (16k bytes) so we must
use that value for our minimum. The stack limit check is also adjusted
to work correctly for 32-bit builds.
8 years ago
Paul Sokolovsky
26d5e91bf3
lib/axtls: Update, fixes esp8266 build.
8 years ago
Damien George
3593d8e10c
py/nlrx64.S: Prefix mp_thread_get_state with an underscore on Mac.
8 years ago
Anton Sokolchenko
e9f3fb7662
mpy-cross: Fix Makefile to handle gc-sections linker flags on OS X.
8 years ago
Daniel Tralamazza
9626662819
qemu-arm: Enable gcc LTO option for nlrthumb.c
LTO can't "see" inside naked functions, but we can mark `nlr_push_tail` as used.
8 years ago
Paul Sokolovsky
7711d87563
lib/axtls: Upgrade to axTLS 1.5.4 + MicroPython patchset.
8 years ago
Paul Sokolovsky
e3f0f31e07
examples/http_server*: Update for buffered-like streams (read line by line).
Since "read-exactly" stream refactor, where stream.read(N) will read
exactly N bytes (unless EOF), http_server* examples can't any longer do
client_socket.read(4096) and expect to get full request (it will block
on HTTP/1.1 client). Instead, read request line by line, as the HTTP
protocol requires.
8 years ago
Damien George
1459a8d5c9
docs: Bump version to 1.8.2.
8 years ago
Damien George
56bb6f3979
travis: Run unix thread tests.
8 years ago
Damien George
2b5a1067c0
tests/run-tests: If running thread tests on unix, don't run mutate ones.
They will fail because the GIL is disabled on the unix build.
8 years ago
Damien George
3096928d5a
unix: Disable the GIL to improve performance of non-thread code.
Threading support is still very new so stay conservative at this point
and enable threading without the GIL. This requires users to protect
concurrent access of mutatable Python objects (eg lists) with locks at
the Python level (something you should probably do anyway). The
advantage is that there is less of a performance hit for non-threaded
code, because the VM does not need to constantly release/acquire the GIL.
In the future the GIL will be made more efficient. There is also room to
improve the efficiency of non-GIL code by not using mutex's if there is
only one thread active.
8 years ago
Paul Sokolovsky
520f35632d
unix/main: When preparing sys.path, allocate exact strings on uPy heap.
Due to the way modern compilers work (allocating space for stack vars once
at tha start of function, and deallocating once on exit from), using
intermediate stack buffer of big size caused blockage of 4K (PATH_MAX)
on stack for the entire duration of MicroPython execution.
8 years ago
Paul Sokolovsky
649b69a1db
unix/main: Improve help for -X options a bit.
8 years ago
Paul Sokolovsky
0e5e14fe7c
unix/main: Error out on unknown value of suffix in -X heapsize= option.
E.g. -X heapsize=16Kfoo, -X heapsize=1G will lead to error.
8 years ago
Paul Sokolovsky
a4c8a1ffe8
extmod/moduos_dupterm: Reuse dupterm_arr_obj for write operations.
Instead of allocating new array object header again and again, causing
memory fragmentation.
8 years ago
Paul Sokolovsky
ec7fe92531
py/objarray: Split out header to allow direct access to object.
This follows source code/header file organization similar to few other
objects, and intended to be used only is special cases, where efficiency/
simplicity matters.
8 years ago
Paul Sokolovsky
380561836d
esp8266/esp_mphal: Properly handle dupterm EOF after switching to readinto().
8 years ago
Paul Sokolovsky
a22b6ebff1
esp8266/esp_mphal: call_dupterm_read: Use readinto() method.
It's memory fragmentation hazard to allocate 1-char string each time by
calling read() method.
8 years ago
Paul Sokolovsky
e07ef8f1a2
esp8266/main: Init recently added dupterm_arr_obj port state var.
8 years ago
Paul Sokolovsky
426112ce88
extmod/moduos_dupterm: Reserve buffer bytearray object for dupterm.
Allocating it for each read/write operation is a memory fragmentation
hazard.
8 years ago
Paul Sokolovsky
d83177b248
unix/mpconfigport_minimal.h: Allow to print a string within 1KB of heap.
By adjusting parser allocation policy.
8 years ago
Paul Sokolovsky
e965d2b82a
unix/Makefile: Make "minimal" build be minimal again.
8 years ago
Paul Sokolovsky
4cfe3e84b0
esp8266/README: Promote from "highly experimental" to "experimental".
8 years ago
Paul Sokolovsky
b8f45166c6
esp8266: Switch webrepl to use frozen bytecode.
8 years ago
Paul Sokolovsky
dec51e3519
esp8266: Switch webrepl_setup to use frozen bytecode.
8 years ago
Paul Sokolovsky
686367dcfc
esp8266: Explicitly collect garbage in bootstrap scripts.
Leads to less fragmentation at teh time user code starts.
8 years ago
Paul Sokolovsky
417dc0c05d
extmod/modbtree: Fixes for nanbox build.
8 years ago
Paul Sokolovsky
43241ceaac
unix: Enable btree module.
But disable it for coverage build, as its extra warninsg aren't compatible
with K&R C BerkeleyDB uses.
8 years ago
Paul Sokolovsky
b09cd0e1ec
extmod/modbtree: Fix unused argument warning.
8 years ago
Paul Sokolovsky
737bd9c314
py/mpconfig.h: Mention MICROPY_PY_BTREE config option.
However, as it requires linking with external libraries, it actually
should be ste on Makefile level.
8 years ago
Paul Sokolovsky
ae184cb9de
py/builtinimport: Disable "imported as namespace package" warning.
Namespace packages are natural part of Python3, CPython3 doesn't have such
warning, it made sense only from point of view of Python2 legacy.
8 years ago
Paul Sokolovsky
c880f91ac0
extmod/modwebrepl: Add readinto() method.
8 years ago
Paul Sokolovsky
03b0279c6d
extmod/modwebsocket: Add readinto() method.
8 years ago
Paul Sokolovsky
92a9078a6f
tests/meminfo: Update for addition of "max free sz" output.
8 years ago
Paul Sokolovsky
749cbaca7f
py/gc: Calculate (and report) maximum contiguous free block size.
Just as maximum allocated block size, it's reported in allocation units
(not bytes).
8 years ago
Radomir Dopieralski
35962eaab0
esp8266/modpybuart: allow setting baudrate and other params
8 years ago
Paul Sokolovsky
d1b7ba5dc1
esp8266/websocket_helper.py: Fix typo in debug output.
8 years ago