mindreframer/ProFi.lua

语言: Lua

git: https://github.com/mindreframer/ProFi.lua

一个Lua剖析器ProFi的非官方git镜像
a non-official git mirror for ProFi, a Lua profiler
README.md (中文)

Proke v1.3,作者:Luke Perkin 2012.使用许可证http://www.opensource.org/licenses/with-license.php。

来源:https://gist.github.com/perky/2838755

例:

LUA     ProFi =需要'ProFi'     财务管理信息系统:启动()     some_function()     another_function()     coroutine.resume(some_coroutine)     财务管理信息系统:停止()     ProFi:writeReport('MyProfilingReport.txt')

API:

参数指定为:type / name / default。

  ProFi:start( string/once/nil )
  ProFi:stop()
  ProFi:checkMemory( number/interval/0, string/note/'' )
  ProFi:writeReport( string/filename/'ProFi.txt' )
  ProFi:reset()
  ProFi:setHookCount( number/hookCount/0 )
  ProFi:setGetTimeMethod( function/getTimeMethod/os.clock )
  ProFi:setInspect( string/methodName, number/levels/1 )

本文使用googletrans自动翻译,仅供参考, 原文来自github.com

en_README.md

ProFi v1.3, by Luke Perkin 2012. MIT Licence http://www.opensource.org/licenses/mit-license.php.

Origin: https://gist.github.com/perky/2838755

Example:

lua ProFi = require 'ProFi' ProFi:start() some_function() another_function() coroutine.resume( some_coroutine ) ProFi:stop() ProFi:writeReport( 'MyProfilingReport.txt' )

API:

Arguments are specified as: type/name/default.

  ProFi:start( string/once/nil )
  ProFi:stop()
  ProFi:checkMemory( number/interval/0, string/note/'' )
  ProFi:writeReport( string/filename/'ProFi.txt' )
  ProFi:reset()
  ProFi:setHookCount( number/hookCount/0 )
  ProFi:setGetTimeMethod( function/getTimeMethod/os.clock )
  ProFi:setInspect( string/methodName, number/levels/1 )