17 lines
733 B
Plaintext
17 lines
733 B
Plaintext
:sig
|
|
DValue request_perf()
|
|
|
|
:params
|
|
return value : performance snapshot for the active request/workspace
|
|
|
|
:see
|
|
>sys
|
|
>time_precise
|
|
|
|
:content
|
|
Returns a DValue with timing and process metadata such as worker pid, parent pid, request count, request start times, native dispatch, workspace setup and birth, context application, guest execution, and hostcall timing. Hostcall totals include component resolution; MySQL, memcache, and component resolution also expose their own count and microsecond fields. The profiling hostcall itself is excluded from those totals so repeated snapshots remain comparable.
|
|
|
|
:example
|
|
DValue perf = request_perf();
|
|
print(perf.get_type_name() != "invalid" ? "captured a timing snapshot" : "no data", "\n");
|