llvm::timeTraceProfilerBegin

Manually begin a time section with lazily computed metadata.

Synopsis

Declared in <llvm/Support/TimeProfiler.h>

TimeTraceProfilerEntry*
timeTraceProfilerBegin(
    StringRef Name,
    llvm::function_ref<TimeTraceMetadata()> MetaData);

Return Value

Profiler entry for the begun section, or nullptr if tracing is off.

Parameters

NameDescription
NameEvent name shown in the trace.
MetaDataClosure that produces file, line, and detail metadata; not called if tracing is disabled.