-
Notifications
You must be signed in to change notification settings - Fork 16
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
Initialise point-to-point mappings from scheduler output (groundwork) #160
Conversation
@@ -6,6 +6,8 @@ | |||
#include <faabric/util/locks.h> |
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 diff is pretty messed up as I've removed a lot of the interface for this class. Best to look at full version:
formatByteArrayToIntString(kickOffData), | ||
formatByteArrayToIntString(expectedKickOffData)); | ||
return 1; | ||
} |
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 sort of point-to-point initialisation is done transparently now.
FAIL(); | ||
} | ||
} | ||
} |
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.
These tests were covering the old PointToPointBroker
API which has been simplified (and is tested below).
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.
LGTM, just a minor typo
At the moment, scheduling and point-to-point messaging are seen as two separate things, and the function/ executor doing the scheduling has to ensure that the point-to-point mappings are set up independently. It also means that the scheduled functions have to wait for confirmation from the master before performing any point-to-point messaging, as they cannot ensure the mappings have been set up when they start executing (this is equivalent to the barrier we use before executing MPI functions).
Ideally the point-to-point mappings would be set up transparently when a group of functions is scheduled, and the downstream functions wouldn't have to manually synchronise before doing point-to-point messaging.
The full implementation of this transparent point-to-point setup will be completed with the introduction of function groups in #141, but this PR contains a lot of the groundwork for it (to avoid bloating the other one).
Changes:
SchedulingDecision
object, which captures all the metadata from the scheduling, and is returned by the scheduler after scheduling has completed.PointToPointBroker
to only accept aSchedulingDecision
object as the input to set up the mapping (as it will only be the scheduler doing this setup in future).sendMessage
that checks if the mappings for that app are available on the current host, and does a blocking wait if not.SchedulingDecision
object returned fromcallFunctions
.Note that I've put the
SchedulingDecision
infaabric::util
as it's essentially just a struct used for passing data around, and things consuming it don't need a full dependency on thescheduling
module.