-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[Autoscheduler] Reduce task weight coercion overhead #8995
Conversation
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.
cc @tqchen @junrushao1994
5d6e1cd
to
fe34cbb
Compare
LGTM. BTW this is interesting that we observe meaningful amount of time is used in error handling. Would you like to provide some details? Just curious 😄 Thanks a lot! |
@junrushao1994 the (hidden) place this ends up getting hit is this function: self.objective_func = lambda costs: sum(c * w for c, w in zip(costs, task_weights)) because
Note that either part of this change is sufficient to make the cost negligible. The open question is whether there may be other scenarios where the |
fe34cbb
to
4589ea9
Compare
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.
Looks good. Thanks @petersalas!
Co-authored-by: Peter Salas <psalas@octoml.ai>
Co-authored-by: Peter Salas <psalas@octoml.ai>
In autoscheduler, a meaningful amount of time is spent collecting (discarded) backtraces in the
TaskScheduler
objective_func
due to failingReflectionVTable::GetAttr
calls during coercion.Modify
extract_tasks
to returnList[int]
instead ofList[IntImm]
to remove coercion altogether from theobjective_func
.