gh-90473: Decrease recursion limit and skip tests on WASI (GH-92803)

This commit is contained in:
Christian Heimes 2022-05-19 12:43:16 +02:00 committed by GitHub
parent e48ac9c100
commit 137fd3d88a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 109 additions and 14 deletions

View file

@ -12,8 +12,14 @@ extern "C" {
struct pyruntimestate;
struct _ceval_runtime_state;
/* WASI has limited call stack. wasmtime 0.36 can handle sufficient amount of
C stack frames for little more than 750 recursions. */
#ifndef Py_DEFAULT_RECURSION_LIMIT
# define Py_DEFAULT_RECURSION_LIMIT 1000
# ifdef __wasi__
# define Py_DEFAULT_RECURSION_LIMIT 750
# else
# define Py_DEFAULT_RECURSION_LIMIT 1000
# endif
#endif
#include "pycore_interp.h" // PyInterpreterState.eval_frame