diff options
| author | manobendro <manob7@hotmail.com> | 2023-02-02 21:47:40 +0600 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2023-02-20 10:44:14 +1100 |
| commit | 294098d28e2bad0ac0aad0d72595d11a82798096 (patch) | |
| tree | 589018682ec07720d027b06acfbdec3239cba439 | |
| parent | 4598b89ce9bd171dde92480e86050f6ceb3cfc83 (diff) | |
minimal: Increase heap size for Linux builds.
Otherwise use of the REPL is quite limited.
Fixes issue #10644.
| -rw-r--r-- | ports/minimal/main.c | 2 | ||||
| -rw-r--r-- | ports/minimal/mpconfigport.h | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/ports/minimal/main.c b/ports/minimal/main.c index 289327658..881a6d236 100644 --- a/ports/minimal/main.c +++ b/ports/minimal/main.c @@ -29,7 +29,7 @@ void do_str(const char *src, mp_parse_input_kind_t input_kind) { static char *stack_top; #if MICROPY_ENABLE_GC -static char heap[2048]; +static char heap[MICROPY_HEAP_SIZE]; #endif int main(int argc, char **argv) { diff --git a/ports/minimal/mpconfigport.h b/ports/minimal/mpconfigport.h index 02312e2e4..0f50f8d38 100644 --- a/ports/minimal/mpconfigport.h +++ b/ports/minimal/mpconfigport.h @@ -33,11 +33,13 @@ typedef long mp_off_t; #ifdef __linux__ #define MICROPY_MIN_USE_STDOUT (1) +#define MICROPY_HEAP_SIZE (25600) // heap size 25 kilobytes #endif #ifdef __thumb__ #define MICROPY_MIN_USE_CORTEX_CPU (1) #define MICROPY_MIN_USE_STM32_MCU (1) +#define MICROPY_HEAP_SIZE (2048) // heap size 2 kilobytes #endif #define MP_STATE_PORT MP_STATE_VM |
