-
Notifications
You must be signed in to change notification settings - Fork 65
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
Enable tracing of thread pool tasks using NVTX #630
base: branch-25.04
Are you sure you want to change the base?
Enable tracing of thread pool tasks using NVTX #630
Conversation
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
/ok to test |
2aca97e
to
4efb3cf
Compare
#define KVIKIO_NVTX_FUNC_RANGE_IMPL() NVTX3_FUNC_RANGE_IN(kvikio::libkvikio_domain) | ||
|
||
// Implementation of KVIKIO_NVTX_SCOPED_RANGE(...) | ||
#define KVIKIO_NVTX_SCOPED_RANGE_IMPL_3(message, payload_v, color) \ |
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'm not sure why the variable has to be named payload_v
. Otherwise payload
would cause compile errors. Perhaps a name look-up related issue.
@@ -192,7 +194,8 @@ std::future<std::size_t> FileHandle::pread(void* buf, | |||
std::size_t gds_threshold, | |||
bool sync_default_stream) | |||
{ | |||
KVIKIO_NVTX_MARKER("FileHandle::pread()", size); | |||
auto& [nvtx_color, call_idx] = detail::get_next_color_and_call_idx(); | |||
KVIKIO_NVTX_SCOPED_RANGE("FileHandle::pread()", size, nvtx_color); |
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.
To be consistent with RemoteHandle
, the NVTX marker here is replaced with the scoped range.
This PR implements the basic feature outlined in #631.
The two good-to-haves are currently blocked.