Damien George
c7969857f4
Merge branch 'pfalcon-vm-alloca'
11 years ago
Damien George
1b87d1098a
Merge branch 'vm-alloca' of github.com:pfalcon/micropython into pfalcon-vm-alloca
Conflicts:
py/vm.c
Fixed stack underflow check. Use UINT_FMT/INT_FMT where necessary.
Specify maximum VM-stack byte size by multiple of machine word size, so
that on 64 bit machines it has same functionality as 32 bit.
11 years ago
Damien George
6c13d7965e
Merge branch 'master' of github.com:micropython/micropython
11 years ago
Damien George
4d659f566f
tests: Add feature test for when heap allocation is disabled.
11 years ago
Damien George
6e18835b94
Merge pull request #643 from dhylands/fix-af-csv
Add a comma to make the .csv look proper in github
11 years ago
Damien George
a053e37b2c
tests: Change --test_dirs to --test-dirs.
11 years ago
Damien George
e7412ab37b
Merge pull request #632 from stinos/tests-dir-argument
tests: Add argument to allow specifying which directories to test
11 years ago
Damien George
5b5562c1d1
py: Fix stack underflow with optimised for loop.
11 years ago
Damien George
049a01d148
tests: Add another test for break-from-for-loop.
11 years ago
Paul Sokolovsky
b4ebad3310
vm: Factor out structure with code execution state and pass it around.
This improves stack usage in callers to mp_execute_bytecode2, and is step
forward towards unifying execution interface for function and generators
(which is important because generators don't even support full forms
of arguments passing (keywords, etc.)).
11 years ago
Paul Sokolovsky
b16523aa95
vm: Don't unconditionally allocate state on stack, do that only if needed.
This makes sure that only as much stack allocated as actually used, reducing
stack usage for each Python function call.
11 years ago
Paul Sokolovsky
ff8da0b835
vm: Detect stack underflow in addition to overflow.
11 years ago
Paul Sokolovsky
ae9c82d5f3
objstr: str_uni_istype(): Spurious whitespace on empty lines.
11 years ago
Paul Sokolovsky
f69b9d379c
objstr: str_uni_istype(): Codestyle.
11 years ago
Paul Sokolovsky
69a8b23651
Merge pull request #644 from kimbauters/master
add methods isspace(), isalpha(), isdigit(), isupper() and islower() to str
11 years ago
Kim Bauters
a3f4b83018
add methods isspace(), isalpha(), isdigit(), isupper() and islower() to str
11 years ago
Dave Hylands
b5fb9b22e2
Add a comma to make the .csv look proper in github
11 years ago
Paul Sokolovsky
1f07b7e3c3
py: Reformat few long functions argument lists for clarity.
11 years ago
Paul Sokolovsky
3dfa76cb85
unix: 64-bit cleanness.
11 years ago
Paul Sokolovsky
914bcf16d8
unix: Add poorman's stack usage info to mem_info() dump.
11 years ago
Paul Sokolovsky
b30a777ace
objfun: Typo fixes in comments.
11 years ago
Paul Sokolovsky
347b3a3d1f
modsocket: Add some comments on intended usage/API design of module.
11 years ago
Paul Sokolovsky
50b08c920a
modsocket: Remove stale ifdef.
11 years ago
Paul Sokolovsky
ccd0e0afcd
tests: Add test for break in for.
For #635 / 25c84643b6
.
11 years ago
Damien George
25c84643b6
py: Fix break from within a for loop.
Needed to pop the iterator object when breaking out of a for loop. Need
also to be careful to unwind exception handler before popping iterator.
Addresses issue #635 .
11 years ago
Paul Sokolovsky
8827682b35
objstr: *strip(): If nothing is stripped, don't create dup string.
11 years ago
Paul Sokolovsky
bcdffe53c6
objstr: *strip(): Fix handling of one-char subject strings.
11 years ago
Paul Sokolovsky
059f95b2cb
Merge pull request #633 from stinos/msvc-fix-genhdr-dep
msvc: Only update generated headers when there are changes
11 years ago
Paul Sokolovsky
97953f6ce7
qemu-arm: Add port README.
Based on https://github.com/micropython/micropython/pull/630 by @errordeveloper .
11 years ago
Damien George
f55cf10101
py: Implement bignum '&' with negatives on lhs and rhs.
Needs proper coverage testing. Doesn't implement -ve & -ve.
Addresses issue #611 .
11 years ago
stijn
48d641e41a
msvc: Only update generated headers when there are changes
This fixes generating the headers casuing complete rebuilds,
even when the headere's content didn't really change.
11 years ago
Damien George
d1e355ea8e
py: Fix check of small-int overflow when parsing ints.
Also unifies use of SMALL_INT_FITS macro across parser and runtime.
11 years ago
Damien George
813ed3bda6
py: Make int(<longint>) work by just returning the longint.
11 years ago
Damien George
503d611033
py: Implement long int parsing in int(...).
Addresses issue #627 .
11 years ago
Paul Sokolovsky
1d567592b1
unix/gccollect.c: Make Clang workaround apply only to it. Unbreaks gcc builds.
11 years ago
stijn
8ac3b578e5
tests: Add argument to allow specifying which directories to test
11 years ago
Paul Sokolovsky
168a9ce863
Revert "Fix DEBUG=1 builds"
This reverts commit 6e76f7bc90
.
This patch tries to workaround a previous clang workaround. Instead of going
into workaround of workaround spiral, the original workaround should be tamed.
11 years ago
Damien George
ae13758dd7
Merge pull request #631 from stinos/fix-win-def
windows: Complete rename of MICROPY_PATH_MAX to MICROPY_ALLOC_PATH_MAX (...
11 years ago
Damien George
4de2fe10b4
Merge pull request #629 from dhylands/fix-unix-debug
Fix unix DEBUG=1 builds
11 years ago
stijn
34c24a0fc2
windows: Complete rename of MICROPY_PATH_MAX to MICROPY_ALLOC_PATH_MAX ( 58ebde4
)
11 years ago
Dave Hylands
6e76f7bc90
Fix DEBUG=1 builds
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
11 years ago
Paul Sokolovsky
0405b2210d
modos: stat(): Accept bytes argument.
11 years ago
Paul Sokolovsky
d07bf029b7
tests: Add small testcase for 3-arg slices.
11 years ago
Damien George
d8675541a9
py, vm: Where possible, make variables local to each opcode.
This helps the compiler do its optimisation, makes it clear which
variables are local per opcode and which global, and makes it consistent
when extra variables are needed in an opcode (in addition to old obj1,
obj2 pair, for example).
Could also make unum local, but that's for another time.
11 years ago
Damien George
f600a6a085
py: Slightly improve efficiency of mp_obj_new_str; rename str_new.
Reorder interning logic in mp_obj_new_str, to be more efficient.
str_new is globally accessible, so should be prefixed with mp_obj_.
11 years ago
Damien George
2617eebf2f
Change const byte* to const char* where sensible.
This removes need for some casts (at least, more than it adds need
for new casts!).
11 years ago
Damien George
f88fc7bd23
Merge branch 'pfalcon-keep-strings-uninterned'
11 years ago
Damien George
5042bce8fb
py: Don't automatically intern strings in parser.
This completes non-automatic interning of strings in the parser, so that
doc strings don't take up RAM. It complicates the parser and compiler,
and bloats stmhal by about 300 bytes. It's complicated because now
there are 2 kinds of parse-nodes that can be strings: interned leaves
and non-interned structs.
11 years ago
Paul Sokolovsky
5fd5af98d0
objlist: Implement support for arbitrary (3-arg) slices.
11 years ago
Paul Sokolovsky
de4b9329f9
py: Refactor slice helpers, preparing to support arbitrary slicing.
11 years ago