all: Fix auto-enable of MICROPY_GCREGS_SETJMP to select GC behaviour.

Only enable it if MICROPY_GCREGS_SETJMP is not already defined, and no
supported architecture is defined.
This commit is contained in:
Damien George
2020-04-30 12:30:27 +10:00
parent 710426024a
commit 5c8bf12acf
4 changed files with 4 additions and 4 deletions

View File

@@ -97,7 +97,7 @@ extern const struct _mp_obj_module_t mp_module_os;
// Do not change anything beyond this line
//////////////////////////////////////////
#if !defined(__x86_64__) || !defined(__i386__) || !defined(__thumb2__) || !defined(__thumb__) || !defined(__arm__)
#if !(defined(MICROPY_GCREGS_SETJMP) || defined(__x86_64__) || defined(__i386__) || defined(__thumb2__) || defined(__thumb__) || defined(__arm__))
// Fall back to setjmp() implementation for discovery of GC pointers in registers.
#define MICROPY_GCREGS_SETJMP (1)
#endif