Skip to content

Latest commit

 

History

History
31 lines (22 loc) · 484 Bytes

ps.md

File metadata and controls

31 lines (22 loc) · 484 Bytes

ps: Process management module

local ps = require "ps"
ps.sleep(n)

sleeps for n seconds.

ps.time()

returns the current time in seconds (the resolution is OS dependant).

ps.clock()

returns an approximation of the amount in seconds of CPU time used by the program, as returned by the underlying ISO C function clock.

ps.profile(func)

executes func and returns its execution time in seconds (using ps.clock).