summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/ports_unix.yml32
-rw-r--r--ports/esp32/panichandler.c11
-rw-r--r--ports/unix/coverage.c12
-rw-r--r--ports/unix/variants/coverage/mpconfigvariant.h1
-rw-r--r--py/asmarm.h10
-rw-r--r--py/asmrv32.h2
-rw-r--r--py/asmthumb.h10
-rw-r--r--py/asmx64.h10
-rw-r--r--py/asmx86.h10
-rw-r--r--py/asmxtensa.h12
-rw-r--r--py/emitnative.c34
-rw-r--r--py/emitndebug.c8
-rw-r--r--py/mpconfig.h5
-rw-r--r--py/objcode.h2
-rw-r--r--py/profile.c2
-rw-r--r--py/runtime.h6
-rw-r--r--tests/misc/sys_settrace_cov.py23
-rw-r--r--tests/misc/sys_settrace_cov.py.exp2
-rw-r--r--tests/ports/unix/extra_coverage.py.exp4
-rwxr-xr-xtests/run-tests.py3
-rwxr-xr-xtools/ci.sh29
21 files changed, 148 insertions, 80 deletions
diff --git a/.github/workflows/ports_unix.yml b/.github/workflows/ports_unix.yml
index c5223a71e6..4b22926eaf 100644
--- a/.github/workflows/ports_unix.yml
+++ b/.github/workflows/ports_unix.yml
@@ -71,6 +71,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
+ - uses: actions/setup-python@v5
+ # Python 3.12 is the default for ubuntu-24.04, but that has compatibility issues with settrace tests.
+ # Can remove this step when ubuntu-latest uses a more recent Python 3.x as the default.
+ with:
+ python-version: '3.11'
- name: Install packages
run: source tools/ci.sh && ci_unix_coverage_setup
- name: Build
@@ -169,23 +174,6 @@ jobs:
if: failure()
run: tests/run-tests.py --print-failures
- settrace:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- - uses: actions/setup-python@v5
- # Python 3.12 is the default for ubuntu-24.04, but that has compatibility issues with settrace tests.
- # Can remove this step when ubuntu-latest uses a more recent Python 3.x as the default.
- with:
- python-version: '3.11'
- - name: Build
- run: source tools/ci.sh && ci_unix_settrace_build
- - name: Run main test suite
- run: source tools/ci.sh && ci_unix_settrace_run_tests
- - name: Print failures
- if: failure()
- run: tests/run-tests.py --print-failures
-
settrace_stackless:
runs-on: ubuntu-latest
steps:
@@ -267,6 +255,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
+ - uses: actions/setup-python@v5
+ # Python 3.12 is the default for ubuntu-24.04, but that has compatibility issues with settrace tests.
+ # Can remove this step when ubuntu-latest uses a more recent Python 3.x as the default.
+ with:
+ python-version: '3.11'
- name: Install packages
run: source tools/ci.sh && ci_unix_coverage_setup
- name: Build
@@ -287,6 +280,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
+ - uses: actions/setup-python@v5
+ # Python 3.12 is the default for ubuntu-24.04, but that has compatibility issues with settrace tests.
+ # Can remove this step when ubuntu-latest uses a more recent Python 3.x as the default.
+ with:
+ python-version: '3.11'
- name: Install packages
run: source tools/ci.sh && ci_unix_coverage_setup
- name: Build
diff --git a/ports/esp32/panichandler.c b/ports/esp32/panichandler.c
index e6ff98ded2..5211286f84 100644
--- a/ports/esp32/panichandler.c
+++ b/ports/esp32/panichandler.c
@@ -42,11 +42,20 @@
#endif
void __real_esp_panic_handler(void *);
-void esp_panic_handler_reconfigure_wdts(uint32_t timeout_ms);
void panic_print_str(const char *str);
+#if ESP_IDF_VERSION < ESP_IDF_VERSION_VAL(5, 4, 2)
+void esp_panic_handler_reconfigure_wdts(uint32_t timeout_ms);
+#else
+void esp_panic_handler_feed_wdts(void);
+#endif
+
void MICROPY_WRAP_PANICHANDLER_FUN(__wrap_esp_panic_handler)(void *info) {
+ #if ESP_IDF_VERSION < ESP_IDF_VERSION_VAL(5, 4, 2)
esp_panic_handler_reconfigure_wdts(1000);
+ #else
+ esp_panic_handler_feed_wdts();
+ #endif
const static char *msg = MICROPY_WRAP_PANICHANDLER_STR(
"\r\n"
diff --git a/ports/unix/coverage.c b/ports/unix/coverage.c
index b041141f0f..33e4208d92 100644
--- a/ports/unix/coverage.c
+++ b/ports/unix/coverage.c
@@ -582,12 +582,24 @@ static mp_obj_t extra_coverage(void) {
fun_bc.context = &context;
fun_bc.child_table = NULL;
fun_bc.bytecode = (const byte *)"\x01"; // just needed for n_state
+ #if MICROPY_PY_SYS_SETTRACE
+ struct _mp_raw_code_t rc = {};
+ fun_bc.rc = &rc;
+ #endif
mp_code_state_t *code_state = m_new_obj_var(mp_code_state_t, state, mp_obj_t, 1);
code_state->fun_bc = &fun_bc;
code_state->ip = (const byte *)"\x00"; // just needed for an invalid opcode
code_state->sp = &code_state->state[0];
code_state->exc_sp_idx = 0;
code_state->old_globals = NULL;
+ #if MICROPY_STACKLESS
+ code_state->prev = NULL;
+ #endif
+ #if MICROPY_PY_SYS_SETTRACE
+ code_state->prev_state = NULL;
+ code_state->frame = NULL;
+ #endif
+
mp_vm_return_kind_t ret = mp_execute_bytecode(code_state, MP_OBJ_NULL);
mp_printf(&mp_plat_print, "%d %d\n", ret, mp_obj_get_type(code_state->state[0]) == &mp_type_NotImplementedError);
}
diff --git a/ports/unix/variants/coverage/mpconfigvariant.h b/ports/unix/variants/coverage/mpconfigvariant.h
index cfefeb4672..2f5d9683b3 100644
--- a/ports/unix/variants/coverage/mpconfigvariant.h
+++ b/ports/unix/variants/coverage/mpconfigvariant.h
@@ -39,6 +39,7 @@
// Enable additional features.
#define MICROPY_DEBUG_PARSE_RULE_NAME (1)
+#define MICROPY_PY_SYS_SETTRACE (1)
#define MICROPY_TRACKED_ALLOC (1)
#define MICROPY_WARNINGS_CATEGORY (1)
#undef MICROPY_VFS_ROM_IOCTL
diff --git a/py/asmarm.h b/py/asmarm.h
index 0d68812145..405457d440 100644
--- a/py/asmarm.h
+++ b/py/asmarm.h
@@ -164,12 +164,12 @@ void asm_arm_bx_reg(asm_arm_t *as, uint reg_src);
// Holds a pointer to mp_fun_table
#define REG_FUN_TABLE ASM_ARM_REG_FUN_TABLE
-#define ASM_T asm_arm_t
-#define ASM_END_PASS asm_arm_end_pass
-#define ASM_ENTRY asm_arm_entry
-#define ASM_EXIT asm_arm_exit
+#define ASM_T asm_arm_t
+#define ASM_END_PASS asm_arm_end_pass
+#define ASM_ENTRY(as, num_locals, name) asm_arm_entry((as), (num_locals))
+#define ASM_EXIT asm_arm_exit
-#define ASM_JUMP asm_arm_b_label
+#define ASM_JUMP asm_arm_b_label
#define ASM_JUMP_IF_REG_ZERO(as, reg, label, bool_test) \
do { \
asm_arm_cmp_reg_i8(as, reg, 0); \
diff --git a/py/asmrv32.h b/py/asmrv32.h
index 99c2226ef3..dac9c028b0 100644
--- a/py/asmrv32.h
+++ b/py/asmrv32.h
@@ -718,7 +718,7 @@ void asm_rv32_emit_optimised_xor(asm_rv32_t *state, mp_uint_t rd, mp_uint_t rs);
void asm_rv32_emit_store_reg_reg_offset(asm_rv32_t *state, mp_uint_t source, mp_uint_t base, int32_t offset, mp_uint_t operation_size);
#define ASM_T asm_rv32_t
-#define ASM_ENTRY(state, labels) asm_rv32_entry(state, labels)
+#define ASM_ENTRY(state, labels, name) asm_rv32_entry(state, labels)
#define ASM_EXIT(state) asm_rv32_exit(state)
#define ASM_END_PASS(state) asm_rv32_end_pass(state)
diff --git a/py/asmthumb.h b/py/asmthumb.h
index 9cd9d32d83..5edf6573e1 100644
--- a/py/asmthumb.h
+++ b/py/asmthumb.h
@@ -403,12 +403,12 @@ void asm_thumb_b_rel12(asm_thumb_t *as, int rel);
#define REG_FUN_TABLE ASM_THUMB_REG_FUN_TABLE
-#define ASM_T asm_thumb_t
-#define ASM_END_PASS asm_thumb_end_pass
-#define ASM_ENTRY asm_thumb_entry
-#define ASM_EXIT asm_thumb_exit
+#define ASM_T asm_thumb_t
+#define ASM_END_PASS asm_thumb_end_pass
+#define ASM_ENTRY(as, num_locals, name) asm_thumb_entry((as), (num_locals))
+#define ASM_EXIT asm_thumb_exit
-#define ASM_JUMP asm_thumb_b_label
+#define ASM_JUMP asm_thumb_b_label
#define ASM_JUMP_IF_REG_ZERO(as, reg, label, bool_test) \
do { \
asm_thumb_cmp_rlo_i8(as, reg, 0); \
diff --git a/py/asmx64.h b/py/asmx64.h
index f2fb5da180..d80c5dcc13 100644
--- a/py/asmx64.h
+++ b/py/asmx64.h
@@ -154,12 +154,12 @@ void asm_x64_call_ind(asm_x64_t *as, size_t fun_id, int temp_r32);
// Holds a pointer to mp_fun_table
#define REG_FUN_TABLE ASM_X64_REG_FUN_TABLE
-#define ASM_T asm_x64_t
-#define ASM_END_PASS asm_x64_end_pass
-#define ASM_ENTRY asm_x64_entry
-#define ASM_EXIT asm_x64_exit
+#define ASM_T asm_x64_t
+#define ASM_END_PASS asm_x64_end_pass
+#define ASM_ENTRY(as, num_locals, name) asm_x64_entry((as), (num_locals))
+#define ASM_EXIT asm_x64_exit
-#define ASM_JUMP asm_x64_jmp_label
+#define ASM_JUMP asm_x64_jmp_label
#define ASM_JUMP_IF_REG_ZERO(as, reg, label, bool_test) \
do { \
if (bool_test) { \
diff --git a/py/asmx86.h b/py/asmx86.h
index 2cec38ed45..d2e078ad51 100644
--- a/py/asmx86.h
+++ b/py/asmx86.h
@@ -149,12 +149,12 @@ void asm_x86_call_ind(asm_x86_t *as, size_t fun_id, mp_uint_t n_args, int temp_r
// Holds a pointer to mp_fun_table
#define REG_FUN_TABLE ASM_X86_REG_FUN_TABLE
-#define ASM_T asm_x86_t
-#define ASM_END_PASS asm_x86_end_pass
-#define ASM_ENTRY asm_x86_entry
-#define ASM_EXIT asm_x86_exit
+#define ASM_T asm_x86_t
+#define ASM_END_PASS asm_x86_end_pass
+#define ASM_ENTRY(as, num_locals, name) asm_x86_entry((as), (num_locals))
+#define ASM_EXIT asm_x86_exit
-#define ASM_JUMP asm_x86_jmp_label
+#define ASM_JUMP asm_x86_jmp_label
#define ASM_JUMP_IF_REG_ZERO(as, reg, label, bool_test) \
do { \
if (bool_test) { \
diff --git a/py/asmxtensa.h b/py/asmxtensa.h
index 7f113ca12e..559b3cacd5 100644
--- a/py/asmxtensa.h
+++ b/py/asmxtensa.h
@@ -340,9 +340,9 @@ void asm_xtensa_l32r(asm_xtensa_t *as, mp_uint_t reg, mp_uint_t label);
#define ASM_NUM_REGS_SAVED ASM_XTENSA_NUM_REGS_SAVED
#define REG_FUN_TABLE ASM_XTENSA_REG_FUN_TABLE
-#define ASM_ENTRY(as, nlocal) asm_xtensa_entry((as), (nlocal))
-#define ASM_EXIT(as) asm_xtensa_exit((as))
-#define ASM_CALL_IND(as, idx) asm_xtensa_call_ind((as), (idx))
+#define ASM_ENTRY(as, nlocal, name) asm_xtensa_entry((as), (nlocal))
+#define ASM_EXIT(as) asm_xtensa_exit((as))
+#define ASM_CALL_IND(as, idx) asm_xtensa_call_ind((as), (idx))
#else
// Configuration for windowed calls with window size 8
@@ -370,9 +370,9 @@ void asm_xtensa_l32r(asm_xtensa_t *as, mp_uint_t reg, mp_uint_t label);
#define ASM_NUM_REGS_SAVED ASM_XTENSA_NUM_REGS_SAVED_WIN
#define REG_FUN_TABLE ASM_XTENSA_REG_FUN_TABLE_WIN
-#define ASM_ENTRY(as, nlocal) asm_xtensa_entry_win((as), (nlocal))
-#define ASM_EXIT(as) asm_xtensa_exit_win((as))
-#define ASM_CALL_IND(as, idx) asm_xtensa_call_ind_win((as), (idx))
+#define ASM_ENTRY(as, nlocal, name) asm_xtensa_entry_win((as), (nlocal))
+#define ASM_EXIT(as) asm_xtensa_exit_win((as))
+#define ASM_CALL_IND(as, idx) asm_xtensa_call_ind_win((as), (idx))
#endif
diff --git a/py/emitnative.c b/py/emitnative.c
index f3ab483e8a..3aacf69a81 100644
--- a/py/emitnative.c
+++ b/py/emitnative.c
@@ -419,6 +419,30 @@ static void emit_native_start_pass(emit_t *emit, pass_kind_t pass, scope_t *scop
emit->stack_info[i].vtype = VTYPE_UNBOUND;
}
+ char *qualified_name = NULL;
+
+ #if N_DEBUG
+ scope_t *current_scope = scope;
+ vstr_t *qualified_name_vstr = vstr_new(qstr_len(current_scope->simple_name));
+ size_t fragment_length = 0;
+ const byte *fragment_pointer;
+ for (;;) {
+ fragment_pointer = qstr_data(current_scope->simple_name, &fragment_length);
+ vstr_hint_size(qualified_name_vstr, fragment_length);
+ memmove(qualified_name_vstr->buf + fragment_length, qualified_name_vstr->buf, qualified_name_vstr->len);
+ memcpy(qualified_name_vstr->buf, fragment_pointer, fragment_length);
+ qualified_name_vstr->len += fragment_length;
+ if (current_scope->parent == NULL || current_scope->parent->simple_name == MP_QSTR__lt_module_gt_) {
+ break;
+ }
+ vstr_ins_char(qualified_name_vstr, 0, '.');
+ current_scope = current_scope->parent;
+ }
+ qualified_name = vstr_null_terminated_str(qualified_name_vstr);
+ #else
+ (void)qualified_name;
+ #endif
+
mp_asm_base_start_pass(&emit->as->base, pass == MP_PASS_EMIT ? MP_ASM_PASS_EMIT : MP_ASM_PASS_COMPUTE);
// generate code for entry to function
@@ -465,7 +489,7 @@ static void emit_native_start_pass(emit_t *emit, pass_kind_t pass, scope_t *scop
}
// Entry to function
- ASM_ENTRY(emit->as, emit->stack_start + emit->n_state - num_locals_in_regs);
+ ASM_ENTRY(emit->as, emit->stack_start + emit->n_state - num_locals_in_regs, qualified_name);
#if N_X86
asm_x86_mov_arg_to_r32(emit->as, 0, REG_PARENT_ARG_1);
@@ -536,7 +560,7 @@ static void emit_native_start_pass(emit_t *emit, pass_kind_t pass, scope_t *scop
if (emit->scope->scope_flags & MP_SCOPE_FLAG_GENERATOR) {
mp_asm_base_data(&emit->as->base, ASM_WORD_SIZE, (uintptr_t)emit->start_offset);
- ASM_ENTRY(emit->as, emit->code_state_start);
+ ASM_ENTRY(emit->as, emit->code_state_start, qualified_name);
// Reset the state size for the state pointed to by REG_GENERATOR_STATE
emit->code_state_start = 0;
@@ -568,7 +592,7 @@ static void emit_native_start_pass(emit_t *emit, pass_kind_t pass, scope_t *scop
emit->stack_start = emit->code_state_start + SIZEOF_CODE_STATE;
// Allocate space on C-stack for code_state structure, which includes state
- ASM_ENTRY(emit->as, emit->stack_start + emit->n_state);
+ ASM_ENTRY(emit->as, emit->stack_start + emit->n_state, qualified_name);
// Prepare incoming arguments for call to mp_setup_code_state
@@ -634,6 +658,10 @@ static void emit_native_start_pass(emit_t *emit, pass_kind_t pass, scope_t *scop
}
}
}
+
+ #if N_DEBUG
+ vstr_free(qualified_name_vstr);
+ #endif
}
static inline void emit_native_write_code_info_byte(emit_t *emit, byte val) {
diff --git a/py/emitndebug.c b/py/emitndebug.c
index c068a9a9a1..e49c5cdbff 100644
--- a/py/emitndebug.c
+++ b/py/emitndebug.c
@@ -108,8 +108,8 @@ static void asm_debug_end_pass(asm_debug_t *as) {
(void)as;
}
-static void asm_debug_entry(asm_debug_t *as, int num_locals) {
- asm_debug_printf(as, "ENTRY(num_locals=%d)\n", num_locals);
+static void asm_debug_entry(asm_debug_t *as, int num_locals, char *name) {
+ asm_debug_printf(as, "ENTRY(%s, num_locals=%d)\n", name != NULL ? name : "?", num_locals);
}
static void asm_debug_exit(asm_debug_t *as) {
@@ -195,8 +195,8 @@ static void asm_debug_setcc_reg_reg_reg(asm_debug_t *as, int op, int reg1, int r
#define ASM_T asm_debug_t
#define ASM_END_PASS asm_debug_end_pass
-#define ASM_ENTRY(as, num_locals) \
- asm_debug_entry(as, num_locals)
+#define ASM_ENTRY(as, num_locals, name) \
+ asm_debug_entry(as, num_locals, name)
#define ASM_EXIT(as) \
asm_debug_exit(as)
diff --git a/py/mpconfig.h b/py/mpconfig.h
index 94b8453003..cf0538cae4 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -426,6 +426,11 @@
#define MICROPY_EMIT_INLINE_RV32 (0)
#endif
+// Whether to enable the human-readable native instructions emitter
+#ifndef MICROPY_EMIT_NATIVE_DEBUG
+#define MICROPY_EMIT_NATIVE_DEBUG (0)
+#endif
+
// Convenience definition for whether any native emitter is enabled
#define MICROPY_EMIT_NATIVE (MICROPY_EMIT_X64 || MICROPY_EMIT_X86 || MICROPY_EMIT_THUMB || MICROPY_EMIT_ARM || MICROPY_EMIT_XTENSA || MICROPY_EMIT_XTENSAWIN || MICROPY_EMIT_RV32 || MICROPY_EMIT_NATIVE_DEBUG)
diff --git a/py/objcode.h b/py/objcode.h
index 8db9a34b6e..8f26bd9dbd 100644
--- a/py/objcode.h
+++ b/py/objcode.h
@@ -72,7 +72,7 @@ static inline const void *mp_code_get_proto_fun(mp_obj_code_t *self) {
#include "py/emitglue.h"
-#define MP_CODE_QSTR_MAP(context, idx) (context->constants.qstr_table[idx])
+#define MP_CODE_QSTR_MAP(context, idx) ((qstr)(context->constants.qstr_table[idx]))
typedef struct _mp_obj_code_t {
// TODO this was 4 words
diff --git a/py/profile.c b/py/profile.c
index 397d0291f9..b5a0c54728 100644
--- a/py/profile.c
+++ b/py/profile.c
@@ -80,7 +80,7 @@ static void frame_print(const mp_print_t *print, mp_obj_t o_in, mp_print_kind_t
"<frame at 0x%p, file '%q', line %d, code %q>",
frame,
MP_CODE_QSTR_MAP(code->context, 0),
- frame->lineno,
+ (int)frame->lineno,
MP_CODE_QSTR_MAP(code->context, prelude->qstr_block_name_idx)
);
}
diff --git a/py/runtime.h b/py/runtime.h
index a93488e2cd..f42039cab9 100644
--- a/py/runtime.h
+++ b/py/runtime.h
@@ -169,6 +169,12 @@ static inline void mp_thread_init_state(mp_state_thread_t *ts, size_t stack_size
ts->nlr_jump_callback_top = NULL;
ts->mp_pending_exception = MP_OBJ_NULL;
+ #if MICROPY_PY_SYS_SETTRACE
+ ts->prof_trace_callback = MP_OBJ_NULL;
+ ts->prof_callback_is_executing = false;
+ ts->current_code_state = NULL;
+ #endif
+
// If locals/globals are not given, inherit from main thread
if (locals == NULL) {
locals = mp_state_ctx.thread.dict_locals;
diff --git a/tests/misc/sys_settrace_cov.py b/tests/misc/sys_settrace_cov.py
new file mode 100644
index 0000000000..579c8a4a25
--- /dev/null
+++ b/tests/misc/sys_settrace_cov.py
@@ -0,0 +1,23 @@
+import sys
+
+try:
+ sys.settrace
+except AttributeError:
+ print("SKIP")
+ raise SystemExit
+
+
+def trace_tick_handler(frame, event, arg):
+ print("FRAME", frame)
+ print("LASTI", frame.f_lasti)
+ return None
+
+
+def f():
+ x = 3
+ return x
+
+
+sys.settrace(trace_tick_handler)
+f()
+sys.settrace(None)
diff --git a/tests/misc/sys_settrace_cov.py.exp b/tests/misc/sys_settrace_cov.py.exp
new file mode 100644
index 0000000000..423d78ec42
--- /dev/null
+++ b/tests/misc/sys_settrace_cov.py.exp
@@ -0,0 +1,2 @@
+FRAME <frame at 0x\[0-9a-f\]\+, file '\.\*/sys_settrace_cov.py', line \\d\+, code f>
+LASTI \\d\+
diff --git a/tests/ports/unix/extra_coverage.py.exp b/tests/ports/unix/extra_coverage.py.exp
index ac64edde69..ed21ced242 100644
--- a/tests/ports/unix/extra_coverage.py.exp
+++ b/tests/ports/unix/extra_coverage.py.exp
@@ -69,8 +69,8 @@ argv atexit byteorder exc_info
executable exit getsizeof implementation
intern maxsize modules path
platform print_exception ps1
-ps2 stderr stdin stdout
-tracebacklimit version version_info
+ps2 settrace stderr stdin
+stdout tracebacklimit version version_info
ementation
# attrtuple
(start=1, stop=2, step=3)
diff --git a/tests/run-tests.py b/tests/run-tests.py
index e45122b10e..faf1d2e3b4 100755
--- a/tests/run-tests.py
+++ b/tests/run-tests.py
@@ -16,7 +16,7 @@ import threading
import tempfile
# Maximum time to run a PC-based test, in seconds.
-TEST_TIMEOUT = 30
+TEST_TIMEOUT = float(os.environ.get('MICROPY_TEST_TIMEOUT', 30))
# See stackoverflow.com/questions/2632199: __file__ nor sys.argv[0]
# are guaranteed to always work, this one should though.
@@ -354,6 +354,7 @@ special_tests = [
"micropython/meminfo.py",
"basics/bytes_compare3.py",
"basics/builtin_help.py",
+ "misc/sys_settrace_cov.py",
"thread/thread_exc2.py",
"ports/esp32/partition_ota.py",
)
diff --git a/tools/ci.sh b/tools/ci.sh
index 8254336258..4007dfebfc 100755
--- a/tools/ci.sh
+++ b/tools/ci.sh
@@ -480,13 +480,6 @@ function ci_stm32_misc_build {
########################################################################################
# ports/unix
-CI_UNIX_OPTS_SYS_SETTRACE=(
- MICROPY_PY_BTREE=0
- MICROPY_PY_FFI=0
- MICROPY_PY_SSL=0
- CFLAGS_EXTRA="-DMICROPY_PY_SYS_SETTRACE=1"
-)
-
CI_UNIX_OPTS_SYS_SETTRACE_STACKLESS=(
MICROPY_PY_BTREE=0
MICROPY_PY_FFI=0
@@ -619,9 +612,9 @@ function ci_unix_standard_v2_run_tests {
}
function ci_unix_coverage_setup {
- sudo pip3 install setuptools
- sudo pip3 install pyelftools
- sudo pip3 install ar
+ pip3 install setuptools
+ pip3 install pyelftools
+ pip3 install ar
gcc --version
python3 --version
}
@@ -632,7 +625,7 @@ function ci_unix_coverage_build {
}
function ci_unix_coverage_run_tests {
- ci_unix_run_tests_full_helper coverage
+ MICROPY_TEST_TIMEOUT=60 ci_unix_run_tests_full_helper coverage
}
function ci_unix_coverage_run_mpy_merge_tests {
@@ -734,16 +727,6 @@ function ci_unix_float_clang_run_tests {
ci_unix_run_tests_helper CC=clang
}
-function ci_unix_settrace_build {
- make ${MAKEOPTS} -C mpy-cross
- make ${MAKEOPTS} -C ports/unix submodules
- make ${MAKEOPTS} -C ports/unix "${CI_UNIX_OPTS_SYS_SETTRACE[@]}"
-}
-
-function ci_unix_settrace_run_tests {
- ci_unix_run_tests_full_helper standard "${CI_UNIX_OPTS_SYS_SETTRACE[@]}"
-}
-
function ci_unix_settrace_stackless_build {
make ${MAKEOPTS} -C mpy-cross
make ${MAKEOPTS} -C ports/unix submodules
@@ -762,7 +745,7 @@ function ci_unix_sanitize_undefined_build {
}
function ci_unix_sanitize_undefined_run_tests {
- ci_unix_run_tests_full_helper coverage "${CI_UNIX_OPTS_SANITIZE_UNDEFINED[@]}"
+ MICROPY_TEST_TIMEOUT=60 ci_unix_run_tests_full_helper coverage "${CI_UNIX_OPTS_SANITIZE_UNDEFINED[@]}"
}
function ci_unix_sanitize_address_build {
@@ -773,7 +756,7 @@ function ci_unix_sanitize_address_build {
}
function ci_unix_sanitize_address_run_tests {
- ci_unix_run_tests_full_helper coverage "${CI_UNIX_OPTS_SANITIZE_ADDRESS[@]}"
+ MICROPY_TEST_TIMEOUT=60 ci_unix_run_tests_full_helper coverage "${CI_UNIX_OPTS_SANITIZE_ADDRESS[@]}"
}
function ci_unix_macos_build {