RTEMS | rtems_test_spin_for_ticks() fails to execute a minimum workload (#5575)

Gedare Bloom (@gedare) gitlab at rtems.org
Thu May 14 16:00:17 UTC 2026



Gedare Bloom created an issue: https://gitlab.rtems.org/rtems/rtos/rtems/-/issues/5575



## Summary
<!--
Please provide as much information as possible such as error messages or attaching logs
-->

The test helper `rtems_test_spin_for_ticks( rtems_interval ticks )` is used in a few places where it is assumed that it executes for at least `ticks` CPU time. However, the function will not execute a complete tick the first time it is called except by some chance. When the rounding error is less than the function's overhead, the minimum workload of `ticks` time is not achieved.

## Steps to reproduce

This results in failures especially on simulators, I have seen it crop up in `sp69` running risc-v with s-mode in qemu.

<!-- Pre-set options
- milestone
-->

-- 
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/issues/5575
You're receiving this email because of your account on gitlab.rtems.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260514/b3fed9f1/attachment.htm>


More information about the bugs mailing list