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

New thread priority names #2752

Merged
merged 4 commits into from Jul 13, 2017
Merged

New thread priority names #2752

merged 4 commits into from Jul 13, 2017

Conversation

hkaiser
Copy link
Member

@hkaiser hkaiser commented Jul 10, 2017

Introducing explicit high priority and high priority (recursive) as thread priorities, deprecating thread_priority_critical (replaced by thread_priority_high_recursive).

This fixes #2747

@biddisco Please review.

…hread priorities

- deprecating thread_priority_critical (replaced by thread_priority_high_recursive)
@hkaiser
Copy link
Member Author

hkaiser commented Jul 12, 2017

From the comments you made on #2602 I take it that this can go ahead now, can't it?

@biddisco
Copy link
Contributor

My impression so far is that this is a big improvement and it can be merged if you're in a hurry.

I wanted to play some more just to check all corner cases.

@hkaiser
Copy link
Member Author

hkaiser commented Jul 12, 2017

Ok, we'll wait for your verdict, then.

@biddisco
Copy link
Contributor

2017-07-12-numqueues-2 fig_queues

The High priority tasks are now running much more predictably without being queued up behind incorrectly promoted lower priority ones.

I still feel that there is some work to do on the scheduler (attached is plot showing a comparison between the local_priority_queue_scheduler and a modified one of mine for our cholesky matrix solve test). My results for scheduling are so far are inconclusive - but this branch appears to be much better than previously and we are hitting the 800Gflops mark using the HPX scheduler on a 36core daint multicore node for most of the configurations tested.

Copy link
Contributor

@biddisco biddisco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A big improvement

if (thread_priority_high_recursive ==
threads::get_self_id()->get_priority())
{
data.priority = thread_priority_high_recursive;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this check that the promoted thread is "default" or normal. If I have a child task of a high_riority_recursive and I launch it as low priority, I think it should go low and not be promoted to high.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, this should additionally check whether data.priority == thread_priority_default. Which also means that we should make thread_priority_default and thread_priority_normal distinct in terms of enum values represented (just treat them in similar ways).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent catch, btw!

- also make sure high_recursive priority gets inherited only if no non-default priority is given
- flyby: fix get_thread_priority_name()
@hkaiser
Copy link
Member Author

hkaiser commented Jul 12, 2017

@biddisco: Would you be able to check one more time whether my latest changes are fine with the application you're using to test, please?

@biddisco
Copy link
Contributor

Seems to be working ok with the latest changes. I'm happy to see this merged ASAP.

@hkaiser hkaiser merged commit 236ef41 into master Jul 13, 2017
@hkaiser hkaiser deleted the fixing_2747 branch July 13, 2017 23:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inherited task priorities break certain DAG optimizations
2 participants