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

Native testing with FreeRTOS #144

Draft
wants to merge 14 commits into
base: main
Choose a base branch
from
Draft

Native testing with FreeRTOS #144

wants to merge 14 commits into from

Conversation

lptr
Copy link
Member

@lptr lptr commented Mar 30, 2024

This should work on Linux, on Windows under WSL, and on macOS, as we are using the Posix port of FreeRTOS. It works mostly, but when we try to delete a task upon completion, we fail, with the following stacktrace:

__pthread_kill_implementation@0x00007ffff7af19fc (Unknown Source:44)
__pthread_kill_internal@0x00007ffff7af19fc (Unknown Source:78)
__GI___pthread_kill@0x00007ffff7af19fc (Unknown Source:89)
__GI_raise@0x00007ffff7a9d476 (Unknown Source:26)
__GI_abort@0x00007ffff7a837f3 (Unknown Source:79)
??@0x00007ffff7e2db9e (Unknown Source:0)
??@0x00007ffff7e3920c (Unknown Source:0)
std::terminate()@0x00007ffff7e39277 (Unknown Source:0)
__gxx_personality_v0@0x00007ffff7e38afc (Unknown Source:0)
??@0x00007ffff7c9aa06 (Unknown Source:0)
_Unwind_ForcedUnwind@0x00007ffff7c9b100 (Unknown Source:0)
__GI___pthread_unwind@0x00007ffff7af8446 (Unknown Source:130)
__do_cancel@0x00007ffff7af0cba (Unknown Source:280)
__GI___pthread_exit@0x00007ffff7af0cba (Unknown Source:36)
prvSwitchThread@0x00005555555aab1f (\home\lptr\Workspace\kivancsi\ugly-duckling\test-lib\freertos\src\port.c:532)
prvPortYieldFromISR@0x00005555555aab9b (\home\lptr\Workspace\kivancsi\ugly-duckling\test-lib\freertos\src\port.c:330)
vPortYield@0x00005555555ab0c3 (\home\lptr\Workspace\kivancsi\ugly-duckling\test-lib\freertos\src\port.c:338)
vTaskDelete@0x00005555555ad722 (\home\lptr\Workspace\kivancsi\ugly-duckling\test-lib\freertos\src\tasks.c:2324)
farmhub::kernel::Task::~Task@0x00005555555b086b (\home\lptr\Workspace\kivancsi\ugly-duckling\src\kernel\Task.hpp:173)
farmhub::kernel::Task::executeTask@0x00005555555b086b (\home\lptr\Workspace\kivancsi\ugly-duckling\src\kernel\Task.hpp:183)
prvWaitForStart@0x00005555555aaf5e (\home\lptr\Workspace\kivancsi\ugly-duckling\test-lib\freertos\src\port.c:499)

There's also the question of compiling FreeRTOS not from copied-over sources.

@lptr lptr added the internal Internal change label Mar 30, 2024
@lptr lptr self-assigned this Mar 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal Internal change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant