News › performance
By Zayden R., September 21, 2026
The Linux perf script command has been overhauled, replacing embedded scripting with a faster Python module. Engineers will notice significant performance improvements with scripts now running in a fraction of the time.
A sweeping update to the Linux kernel's perf subsystem introduces a new Python module, significantly boosting the performance of the perf script command. Spearheaded by Google engineer Ian Rogers, this overhaul replaces the previously embedded Python and Perl scripts with standalone Python scripts that leverage a new C-based Python extension module.
The practical impact is striking. Where a Python script previously took 3.7 seconds to execute, it now completes in just 0.1 seconds using the new module. This dramatic reduction in execution time is part of a broader effort to address high overhead and complex build dependencies associated with the old system.
The update arrives through a substantial set of 49 patches, transitioning the perf codebase to this new module and discarding the old libpython-based code along with legacy scripts. In total, the changes span approximately 21,000 lines of code, underscoring the scale of this improvement.
For engineers relying on Linux perf for performance profiling and analysis, this update means less waiting and more efficient workflows. The enhancements are currently under review, and those interested can follow the discussions on the mailing list.
In short, this is a solid improvement for anyone who regularly engages with Linux performance scripting. With the backing of Gemini 3.1 Pro, Rogers and his team have provided a solution that makes perf scripting not only faster but also cleaner and more sustainable for future developments.