From 2f86480ed9c3a91fd4d84508b2c31842df73b0f5 Mon Sep 17 00:00:00 2001 From: Radoslaw Koppel Date: Tue, 30 Jan 2024 13:15:36 +0100 Subject: [PATCH] tests: kernel: common: Enable tests with LTO MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit enables some kernel tests with Link Time Optimization enabled. Signed-off-by: Radosław Koppel --- tests/kernel/common/testcase.yaml | 7 +++++++ tests/kernel/interrupt/testcase.yaml | 20 ++++++++++++++++++++ 2 files changed, 27 insertions(+) diff --git a/tests/kernel/common/testcase.yaml b/tests/kernel/common/testcase.yaml index 91e505c85a420e..d02a4f5ae8ff18 100644 --- a/tests/kernel/common/testcase.yaml +++ b/tests/kernel/common/testcase.yaml @@ -47,3 +47,10 @@ tests: tags: picolibc extra_configs: - CONFIG_PICOLIBC=y + kernel.common.lto: + filter: CONFIG_ISR_TABLES_LOCAL_DECLARATION_SUPPORTED + tags: lto + extra_configs: + - CONFIG_TEST_USERSPACE=n + - CONFIG_ISR_TABLES_LOCAL_DECLARATION=y + - CONFIG_LTO=y diff --git a/tests/kernel/interrupt/testcase.yaml b/tests/kernel/interrupt/testcase.yaml index cbe58c65e475a4..47cbba93e0da83 100644 --- a/tests/kernel/interrupt/testcase.yaml +++ b/tests/kernel/interrupt/testcase.yaml @@ -52,3 +52,23 @@ tests: extra_configs: - CONFIG_SHARED_INTERRUPTS=y filter: not CONFIG_TRUSTED_EXECUTION_NONSECURE + arch.shared_interrupt.lto: + # excluded because of failures during test_prevent_interruption + platform_exclude: qemu_cortex_m0 + arch_exclude: + # same as above, #22956 + - nios2 + # test needs 2 working interrupt lines + - xtensa + # TODO: make test work on this arch + - mips + tags: + - kernel + - interrupt + - lto + extra_configs: + - CONFIG_SHARED_INTERRUPTS=y + - CONFIG_TEST_USERSPACE=n + - CONFIG_ISR_TABLES_LOCAL_DECLARATION=y + - CONFIG_LTO=y + filter: not CONFIG_TRUSTED_EXECUTION_NONSECURE and CONFIG_ISR_TABLES_LOCAL_DECLARATION_SUPPORTED