For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).
Mojo function
is_enabled
def is_enabled() -> Bool
Reports whether the libkineto profiler is currently enabled.
Cheap enough to call on the hot path to elide expensive trace-name
materialization on the disabled fast path. Wraps
KGEN_CompilerRT_RangeIsEnabled.
Example:
from profiling_range import Range, is_enabled
def dispatch_kernel() raises:
if is_enabled():
with Range("hot_kernel"):
launch()
else:
launch()Returns:
Bool: True while the libkineto profiler is enabled, False otherwise.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!