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

Support child profilers adding their deviceProperties to logger #1008

Closed

Conversation

fwenguang
Copy link
Contributor

This patch is intended to support our out-of-tree Kineto plugin in adding its deviceProperties.

@fwenguang
Copy link
Contributor Author

Hi @sraikund16 , could you help review this?

@sraikund16
Copy link
Contributor

This is a cool idea, thanks for submitting this. I think this will affect our internal testing so I'll try to dedicate some time to make sure things work this week.

@@ -123,6 +123,22 @@ void ChromeTraceLogger::handleTraceStart(
"traceEvents": [)JSON";
}

void ChromeTraceLogger::handleTraceStart(
Copy link
Contributor

Choose a reason for hiding this comment

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

wondering if we want to get rid of definition on L107

@@ -66,6 +66,13 @@ class MemoryTraceLogger : public ActivityLogger {
metadata_ = metadata;
}

void handleTraceStart(
Copy link
Contributor

Choose a reason for hiding this comment

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

Same as comment above

@@ -306,7 +308,17 @@ void CuptiActivityProfiler::processTraceInternal(ActivityLogger& logger) {
for (auto& pair : versionMetadata_) {
addMetadata(pair.first, pair.second);
}
logger.handleTraceStart(metadata_);
std::vector<std::string> device_properties;
if (auto props = devicePropertiesJson(); !props.empty()) {
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: can we define these vars outside of the if statement? I think our internal linter will complain about lines like these

@facebook-github-bot
Copy link
Contributor

@sraikund16 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

sraikund16 pushed a commit to sraikund16/kineto that referenced this pull request Nov 6, 2024
…rch#1008)

Summary:
This patch is intended to support our out-of-tree Kineto plugin in adding its deviceProperties.


Reviewed By: aaronenyeshi

Differential Revision: D65496183

Pulled By: sraikund16
@facebook-github-bot
Copy link
Contributor

@sraikund16 merged this pull request in 2fb2248.

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.

4 participants