Profiling
- Linux:
perf - Anywhere: vtune
When profiling, make sure to compile your code with:
-d:releaseto turn on optimizations-d:ltoto enable LTO which significantly helps Nim in general--debugger:nativeto enable native debug symbols- Incorporate libbacktrace or disable stack traces
- the stack trace algorithm that comes with nim is too slow for practical use
--stacktrace:offas an alternative