-
Notifications
You must be signed in to change notification settings - Fork 130
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
[fiber] Adds a fiber processing library #439
Closed
Closed
Changes from 1 commit
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
ebfaef2
[fiber] Adds the fiber processing library
henrikssn 5e481a5
[fiber] clang-format
henrikssn 8130d3b
[fiber] Fix avr tests
henrikssn 66e26e7
Fix: Bluepill BSP requires Uart2
rleh 6146163
[examples] Nucleo-F031 Sk6812: reduce led numbers to reduce memory usage
rleh a102c4a
[examples] blue_pill: Logger in BSP
rleh 7dd5a20
fix: example linux/fiber: target hosted-linux (instead of darwin)
rleh 4209527
[fiber] Make main fiber stack size configurable
chris-durand File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was kinda intended to reuse the main_stack_size, since that is now ignored (since there is no more non-fiber main()).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it's ignored. Isn't there still a main stack where the ISRs execute and all code before fibers run?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, at least on Cortex-M, AVRs don't have that option…
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, only thought about cortex-m. There is hosted as well and potential other platforms we might support in the future, so this has to go to some platform specific setting. It is still useful to be able to configure both stack sizes on cortex-m. What do you suggest?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm uncertain about this feature, since we cannot make AVR and hosted main a fiber, since we don't control how their
main()
is called. It would be inconsistent and confusing if the main function is a fiber only on Cortex-M. The only issue is whenmodm::yield()
is called before the scheduler is initialized, but perhaps we can just spin in that case or modm_assert on it. I would remove the main fiber and make everything explicit, even if it will require refactoring some examples in the future.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm unsure as well and would opt for consistency and removing the main fiber. That would also have the benefit of improved backwards compatibility for existing code with tiny 2-4kB RAM devices where splitting the stack to main + main fiber stack could be problematic.
docs generation is still broken:
Error generating documentation for device at90can64-16mu: 'NoneType' object is not subscriptable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This happens when lbuild has an error, usually when module dependencies are not satifed. I need to improve error reporting here…