Php/docs/luasandbox.enableprofiler

提供:Dev Guides
< Php
2020年12月14日 (月) 11:21時点におけるNotes (トーク | 投稿記録)による版 (autoload)
(差分) ← 古い版 | 最新版 (差分) | 新しい版 → (差分)
移動先:案内検索

LuaSandbox::enableProfiler

(PECL luasandbox >= 1.1.0)

LuaSandbox::enableProfilerEnable the profiler.


説明

public LuaSandbox::enableProfiler ([ float $period = 0.02 ] ) : bool

Enables the profiler. Profiling will begin when Lua code is entered.

The profiler periodically samples the Lua environment to record the running function. Testing indicates that at least on Linux, setting a period less than 1ms will lead to a high overrun count but no performance problems.


パラメータ

period
Sampling period in seconds.


返り値

Returns a boolean indicating whether the profiler is enabled.


参考