Skip to content

Conversation

bashbaug
Copy link
Owner

The command buffer emulation layer currently implements event profiling by tracking event profiling on command-queue barriers before and after command-buffer content, but some implementations do not properly implement event profiling on barriers. As a workaround for these implementations, track event profiling on an empty kernel immediately after the command-queue barriers instead.

Because it is less efficient to use the empty kernel for event profiling (the current implementation requires a kernel compilation per command-buffer, in addition to the additional runtime cost associated with the empty kernel every time the command buffer is executed), this codepath is disabled by default, but may be enabled with an environment variable.

@bashbaug bashbaug merged commit dfc7466 into main Aug 29, 2025
5 checks passed
@bashbaug bashbaug deleted the cmdbuf-kernel-for-profiling branch August 29, 2025 20:11
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.

1 participant