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

Improve how thread priority is applied #162

Open
wants to merge 82 commits into
base: main
Choose a base branch
from

Conversation

TrentHouliston
Copy link
Member

@TrentHouliston TrentHouliston commented Dec 23, 2024

Restore the API keeping the enums, and make ThreadPriority be an RAII object to better handle setting and restoring it. Also change what each of the levels mean now that enums let specific behaviour be assigned.

CMurtagh-LGTM and others added 5 commits December 15, 2024 17:28
… object to better handle setting and restoring it. Also change what each of the levels mean now that enums let specific behaviour be assigned.

Have also snuck in some extra changes in this commit that I'll be pulling out into other PRs
…t be emitted (#161)

This pulls the logging code out into its own class as it was getting
more complex.

It also allows limiting sending of logs from a reactor. Sending out
every trace message was causing a lot of overhead.

Now there are two variables in each reactor, one to describe the
displayed log level `log_level` and one to describe the minimum emitted
log level `min_log_level`
@TrentHouliston TrentHouliston changed the base branch from cmurtagh/priority_fixes to main December 23, 2024 10:38
src/util/ThreadPriority.cpp Outdated Show resolved Hide resolved
@WongAaronSW
Copy link
Contributor

It is important to note that when testing some of these UnitTests will require elevated permissions:
When running on a Linux Environment, a user must setup their binary's capabilities.

sudo setcap 'cap_sys_nice=eip' ./tests/util/ThreadPriority

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Thread pinning/scheduling
4 participants