-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
[Placement Group] Fix placement group high cpu usage part 1 #18652
[Placement Group] Fix placement group high cpu usage part 1 #18652
Conversation
@@ -109,12 +123,12 @@ std::string FormatPlacementGroupResource(const std::string &original_resource_na | |||
|
|||
bool IsBundleIndex(const std::string &resource, const PlacementGroupID &group_id, | |||
const int bundle_index) { | |||
return resource.find("_group_" + std::to_string(bundle_index) + "_" + group_id.Hex()) != | |||
std::string::npos; | |||
return resource.find(kGroupKeyword + std::to_string(bundle_index) + "_" + |
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.
I think std::to_string here will benefit from this (#18538)
Are you seeing anything different after that PR merged?
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.
It'll benefit small string if it's less than 22 chars.
I think overall it looks good. Some comments there. Please let me know if you have any concerns. |
Tests / lint broken |
Why are these changes needed?
Implement;
This also makes
GetBundle
to return const which is a more ideal semantic.This makes many_ppo runs 6+ hours rather than 1 hour.
With this PR #18650, it should make many_ppo run for a day without an issue.
For more detail please check the related issue.
Related issue number
Part of #18651
With this PR and #18650, this should fix the P0 release blocker #18541. But we should also fix the fundamental issue (I marked it as P1, and I can work on it next sprint)
Checks
scripts/format.sh
to lint the changes in this PR.