Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

up_squared: tests/kernel/threads/thread_apis/ failed #28549

Closed
chen-png opened this issue Sep 21, 2020 · 1 comment · Fixed by #28658
Closed

up_squared: tests/kernel/threads/thread_apis/ failed #28549

chen-png opened this issue Sep 21, 2020 · 1 comment · Fixed by #28658
Assignees
Labels
area: Tests Issues related to a particular existing or missing test bug The issue is a bug, or the PR is fixing a bug priority: medium Medium impact/importance bug

Comments

@chen-png
Copy link
Collaborator

chen-png commented Sep 21, 2020

To Reproduce
Steps to reproduce the behavior:

  1. west build -b up_squared -p auto tests/kernel/threads/thread_apis/
  2. west flash ~/up_squared.sh
  3. see error
**Logs and console output**
*** Booting Zephyr OS build v2.4.0-rc2  ***
Running test suite threads_lifecycle

START - test_threads_spawn_params
PASS - test_threads_spawn_params

START - test_threads_spawn_priority
PASS - test_threads_spawn_priority

START - test_threads_spawn_delay
PASS - test_threads_spawn_delay
......
START - test_threads_cpu_mask
PASS - test_threads_cpu_mask

START - test_threads_suspend_timeout
PASS - test_threads_suspend_timeout

START - test_threads_suspend
PASS - test_threads_suspend

START - test_thread_join
ztest_thread: method 0, create join_thread
ztest_thread: joining join_thread
join_thread: sleeping forever
ztest_thread: k_thread_join() returned with -11
ztest_thread: method 1, create join_thread
ztest_thread: joining join_thread
ztest_thread: k_thread_join() returned with -16
ztest_thread: method 2, create join_thread
ztest_thread: joining join_thread
join_thread: self-exiting
ztest_thread: k_thread_join() returned with 0
ztest_thread: method 3, create join_thread
ztest_thread: create control_thread
ztest_thread: joining join_thread
join_thread: sleeping forever
control_thread: killing join thread
ztest_thread: k_thread_join() returned with 0
ztest_thread: method 4, create join_thread
ztest_thread: create control_thread
ztest_thread: joining join_thread
join_thread: sleeping forever
control_thread: killing join thread
ztest_thread: k_thread_join() returned with 0
**Assertion failed at WEST_TOPDIR/zephyr/tests/kernel/threads/thread_apis/src/main.c:403: test_thread_join: (interval < JOIN_TIMEOUT_MS is false)
join took too long (117 ms)
FAIL - test_thread_join**

START - test_thread_join_isr
ztest_thread: method 7, create join_thread
isr: joining join_thread
isr: k_thread_join() returned with -16
ztest_thread: method 6, create join_thread
join_thread: self-exiting
isr: joining join_thread
isr: k_thread_join() returned with 0
PASS - test_thread_join_isr

START - test_thread_join_deadlock
PASS - test_thread_join_deadlock

START - test_abort_from_isr
PASS - test_abort_from_isr

Test suite threads_lifecycle failed.

PROJECT EXECUTION FAILED

Environment (please complete the following information):

  • OS: Fedora31
  • Toolchain: zephyr-sdk-0.11.4
  • Commit ID: 122bc38
@chen-png chen-png added bug The issue is a bug, or the PR is fixing a bug area: Tests Issues related to a particular existing or missing test labels Sep 21, 2020
@dcpleung
Copy link
Member

Git bisect to last good commit e9d1545 x86: add new page table generation script

@MaureenHelm MaureenHelm added the priority: medium Medium impact/importance bug label Sep 22, 2020
dcpleung added a commit to dcpleung/zephyr that referenced this issue Sep 23, 2020
When doing test_thread_join with OTHER_ABORT_TIMEOUT, the interval
between two k_uptime_get() includes the two k_thread_create() which
means the interval delta does not exactly count the time spent
in k_thread_join(). On x86_64 with userspace, time spent inside
k_thread_create() scales with memory size as it needs to create
a new page table for the thread. So to actually measure
the time spent in k_thread_join(), the locations where uptime is
obtained need to be moved.

Fixes zephyrproject-rtos#28549

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
MaureenHelm pushed a commit that referenced this issue Sep 24, 2020
When doing test_thread_join with OTHER_ABORT_TIMEOUT, the interval
between two k_uptime_get() includes the two k_thread_create() which
means the interval delta does not exactly count the time spent
in k_thread_join(). On x86_64 with userspace, time spent inside
k_thread_create() scales with memory size as it needs to create
a new page table for the thread. So to actually measure
the time spent in k_thread_join(), the locations where uptime is
obtained need to be moved.

Fixes #28549

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Tests Issues related to a particular existing or missing test bug The issue is a bug, or the PR is fixing a bug priority: medium Medium impact/importance bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants