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

doc: a note about creating threads w/ same prio #5292

Merged
merged 1 commit into from
Apr 11, 2016

Conversation

OlegHahm
Copy link
Member

No description provided.

@OlegHahm OlegHahm added Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation Area: doc Area: Documentation Area: core Area: RIOT kernel. Handle PRs marked with this with care! labels Apr 11, 2016
@OlegHahm OlegHahm added this to the Release 2016.04 milestone Apr 11, 2016
@haukepetersen
Copy link
Contributor

honestly, I think this added text sounds a little vague. AFAIK the behavior for multiple threads with the same prio is well defined an deterministic (round robin if equal prio), right? Also, why should the number of threads be 'signifiacantly' lower than the available prio levels, isn't 'num_of_threads <= prio levels' the more precise statement here?

@cgundogan
Copy link
Member

Could you elaborate on why it is not a good idea? Does it break priority handling? Loss of interrupts? Deadlocks?

@OlegHahm
Copy link
Member Author

AFAIK the behavior for multiple threads with the same prio is well defined an deterministic (round robin if equal prio), right?

I'm not so sure about the "well defined". AFAIK it is neither well documented nor completely deterministic, in a sense that a thread with the same priority may run as long as it wants and other threads on the same priority gets only scheduled if the first thread yields or another thread with higher priority gets scheduled. Of course, this is somewhat deterministic, too - as basically any computer program is. ;-)

Also, why should the number of threads be 'significantly' lower than the available prio levels

This was not a condition, but a statement.

isn't 'num_of_threads <= prio levels' the more precise statement here?

What's the difference?

@OlegHahm OlegHahm added the CI: needs squashing Commits in this PR need to be squashed; If set, CI systems will mark this PR as unmergable label Apr 11, 2016
@OlegHahm
Copy link
Member Author

Updated the text and tried to address your comments.

@haukepetersen
Copy link
Contributor

better :-) ACK when squashed

@OlegHahm OlegHahm force-pushed the thread_prio_doc_enhancement branch from 0319307 to 57e9a25 Compare April 11, 2016 10:12
@OlegHahm OlegHahm added CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR and removed CI: needs squashing Commits in this PR need to be squashed; If set, CI systems will mark this PR as unmergable labels Apr 11, 2016
@miri64
Copy link
Member

miri64 commented Apr 11, 2016

May I ask, why this is added as note? Notes are added to the documentation at the very bottom, but the content seems to me important enough to be in the details section.

@OlegHahm
Copy link
Member Author

Why should the note go to the bottom? (At least with my local doxygen version that doesn't happen.)

@miri64
Copy link
Member

miri64 commented Apr 11, 2016

Oh, you're right.

@OlegHahm OlegHahm added CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR and removed CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Apr 11, 2016
@OlegHahm OlegHahm merged commit b505053 into RIOT-OS:master Apr 11, 2016
@OlegHahm OlegHahm deleted the thread_prio_doc_enhancement branch April 11, 2016 13:35
@cgundogan
Copy link
Member

backport needed?

@OlegHahm
Copy link
Member Author

I don't think so, because http://doc.riot-os.org is built from master.

@miri64
Copy link
Member

miri64 commented Apr 17, 2016

Something we might want to consider to change, as soon as the documentation is somewhat matured enough. Documentation that refers to newer versions of an API while it is recommended to use a stable version seems a little bit undesirable to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: core Area: RIOT kernel. Handle PRs marked with this with care! Area: doc Area: Documentation CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants