Skip to contentTimings
Things to know
- The timings go to stderr.
kscript --timings app.kscript > out.txt saves what the script printed and still shows the timings.
- For a script,
--timings goes before the script's name. After it, --timings is one of the script's own arguments ($args).
- Timing every call makes the run a little slower than it would otherwise be, so compare runs that were both timed.
- A statement such as
if or a loop is part of the function it is in: its time is that function's own time.
- Use the numbers to find what to make faster in KScript itself, as well as in your scripts: a slow
parse or check is worth reporting with the .trace.json file attached.