mirror of
https://github.com/micropython/micropython.git
synced 2026-01-05 19:50:30 +01:00
alif/main: Replace mp_stack_set with mp_cstack_init_with_top.
Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
@@ -29,7 +29,6 @@
|
|||||||
#include "py/gc.h"
|
#include "py/gc.h"
|
||||||
#include "py/mperrno.h"
|
#include "py/mperrno.h"
|
||||||
#include "py/mphal.h"
|
#include "py/mphal.h"
|
||||||
#include "py/stackctrl.h"
|
|
||||||
#include "extmod/modbluetooth.h"
|
#include "extmod/modbluetooth.h"
|
||||||
#include "extmod/modmachine.h"
|
#include "extmod/modmachine.h"
|
||||||
#include "extmod/modnetwork.h"
|
#include "extmod/modnetwork.h"
|
||||||
@@ -92,8 +91,7 @@ int main(void) {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Initialise stack extents and GC heap.
|
// Initialise stack extents and GC heap.
|
||||||
mp_stack_set_top(&__StackTop);
|
mp_cstack_init_with_top(&__StackTop, &__StackTop - &__StackLimit);
|
||||||
mp_stack_set_limit(&__StackTop - &__StackLimit - 1024);
|
|
||||||
gc_init(&__GcHeapStart, &__GcHeapEnd);
|
gc_init(&__GcHeapStart, &__GcHeapEnd);
|
||||||
|
|
||||||
#if MICROPY_PY_LWIP
|
#if MICROPY_PY_LWIP
|
||||||
|
|||||||
@@ -97,6 +97,7 @@
|
|||||||
// Python internal features
|
// Python internal features
|
||||||
#define MICROPY_READER_VFS (1)
|
#define MICROPY_READER_VFS (1)
|
||||||
#define MICROPY_ENABLE_GC (1)
|
#define MICROPY_ENABLE_GC (1)
|
||||||
|
#define MICROPY_STACK_CHECK_MARGIN (1024)
|
||||||
#define MICROPY_ENABLE_EMERGENCY_EXCEPTION_BUF (1)
|
#define MICROPY_ENABLE_EMERGENCY_EXCEPTION_BUF (1)
|
||||||
#define MICROPY_LONGINT_IMPL (MICROPY_LONGINT_IMPL_MPZ)
|
#define MICROPY_LONGINT_IMPL (MICROPY_LONGINT_IMPL_MPZ)
|
||||||
#ifndef MICROPY_FLOAT_IMPL
|
#ifndef MICROPY_FLOAT_IMPL
|
||||||
|
|||||||
Reference in New Issue
Block a user