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

[PROFILING] Profiling over RPC #8885

Merged
merged 4 commits into from
Sep 9, 2021
Merged

Conversation

tkonolige
Copy link
Contributor

Allow for profiling over RPC by serializing the returned report beforesending it. Also remove collectors argument when profiling over rpc because it cannot be serialized.

@jwfromm @leandron

Tristan Konolige added 3 commits August 30, 2021 15:46
Allow for profiling over RPC by serializing the returned report before
sending it. Also remove collectors argument when profiling over rpc
because it cannot be serialized.
Copy link
Contributor

@jwfromm jwfromm left a comment

Choose a reason for hiding this comment

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

Some minor nitpicks but otherwise LGTM.

self.module = _ffi_api._VirtualMachineDebug(exe.module)

# Make sure the constructor of the VM module is on the proper device
if device.device_type >= rpc_base.RPC_SESS_MASK:
Copy link
Contributor

Choose a reason for hiding this comment

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

Checking device type using a >= is kind of confusing. If there isn't a better way to check can you explain why the >= works in a comment.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

while (reader.NextArrayItem()) {
calls.push_back(parse_metrics(&reader));
}
// reader.EndArray();
Copy link
Contributor

Choose a reason for hiding this comment

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

should these commented out lines be removed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I like leaving these lines in as it makes it clear where the end of each Array/Object is.

@masahi masahi merged commit c650f9a into apache:main Sep 9, 2021
ylc pushed a commit to ylc/tvm that referenced this pull request Sep 29, 2021
* [PROFILING] Profiling over RPC

Allow for profiling over RPC by serializing the returned report before
sending it. Also remove collectors argument when profiling over rpc
because it cannot be serialized.

* lint

* fixes

* add comments
ylc pushed a commit to ylc/tvm that referenced this pull request Jan 13, 2022
* [PROFILING] Profiling over RPC

Allow for profiling over RPC by serializing the returned report before
sending it. Also remove collectors argument when profiling over rpc
because it cannot be serialized.

* lint

* fixes

* add comments
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.

None yet

3 participants