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

WIP: add signal_fn for custom scheduler definition #45

Closed
wants to merge 1 commit into from

Conversation

carns
Copy link
Contributor

@carns carns commented Feb 8, 2018

Do not merge; this is a prototype for discussion/evaluation.

This pull request adds a new user-definable function pointer to user defined schedulers called signal(). If a scheduler associated with a pool defines this function, then it will be invoked when new work items are added to the pool.

The purpose of this feature is to allow idle schedulers to be awoken when new work arrives. It's use is demonstrated in a branch of the abt-snoozer scheduler here: https://xgitlab.cels.anl.gov/sds/abt-snoozer/tree/dev-sched-signal. The original (see origin/master) version of abt-snoozer defines its own pool that stacks on top of the default pool so that it can intercept the push() function for this purpose, which is a little awkward and exposes us to #26.

The patch does not yet correctly protect data structures in the modified ABTI_pool_retain() and ABTI_pool_release() functions.

The new variation of abt-snoozer is also incomplete; it could be simplified considerably now that it doesn't have to be organized to link a user defined scheduler and user defined pool via their data pointers.

@carns
Copy link
Contributor Author

carns commented Feb 14, 2018

Closing this PR. Will open a new one to consider based on feedback from @halimamer .

@pmrsbot
Copy link

pmrsbot commented Mar 2, 2018

Can one of the admins verify this patch?

@carns carns closed this Mar 2, 2018
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.

2 participants