Published May 12, 2026 | Version v2.3.0
Software Open

Scalene: a high-performance, high-precision CPU, GPU, and memory profiler for Python

Description

What's Changed

Headlines

  • Adds call graphs ("flame graphs") spanning from Python to native code, organized by % of time
  • Timeline view of call graphs ("flame chart"), including GIL, I/O, and GC activity
  • Flame graph for memory allocations, attributing memory to call stacks
  • Improved memory attribution (now tracked per-thread)
  • Adds proper support for free-threaded Python

New feature work

  • True free-threaded Python support: full memory + CPU profiling by @emeryberger in https://github.com/plasma-umass/scalene/pull/1026
  • Bucket native-thread allocations under <native> (#857) by @emeryberger in https://github.com/plasma-umass/scalene/pull/1031
  • Native (C/C++) stack collection via signal-handler unwinding by @emeryberger in https://github.com/plasma-umass/scalene/pull/1034
  • Stitched Python+native stacks (combined_stacks) by @emeryberger in https://github.com/plasma-umass/scalene/pull/1035
  • GUI: combined_stacks viewer (top-N stitched Python+native stacks) by @emeryberger in https://github.com/plasma-umass/scalene/pull/1037
  • Timeline view for stitched Python+native stacks by @emeryberger in https://github.com/plasma-umass/scalene/pull/1040
  • Memory flame chart + sync per-sample stack capture by @emeryberger in https://github.com/plasma-umass/scalene/pull/1042
  • Shrink stack+timeline RAM, harden profiler self-exclusion by @emeryberger in https://github.com/plasma-umass/scalene/pull/1043
  • Shrink combined_stacks JSON and enforce schema validation by @emeryberger in https://github.com/plasma-umass/scalene/pull/1044
  • Timeline + memory-stacks polish: axes, gridlines, source-line tooltips by @emeryberger in https://github.com/plasma-umass/scalene/pull/1045
  • Minify the GUI bundle (-56% on disk) by @emeryberger in https://github.com/plasma-umass/scalene/pull/1046
  • GUI improvements: resizable charts, C++ demangling, stack filtering by @emeryberger in https://github.com/plasma-umass/scalene/pull/1047
  • Add per-thread native stack sampling for worker threads by @emeryberger in https://github.com/plasma-umass/scalene/pull/1048
  • Make --stacks the default; add --no-stacks opt-out by @emeryberger in https://github.com/plasma-umass/scalene/pull/1050
  • Drop C-side smear from per-line memory attribution and the flame view by @emeryberger in https://github.com/plasma-umass/scalene/pull/1051

Bug fixes

  • Fix root cause of resource tracker death in child processes (#1017) by @emeryberger in https://github.com/plasma-umass/scalene/pull/1024
  • Fix SIGSEGV on free-threaded Python with memory profiling by @emeryberger in https://github.com/plasma-umass/scalene/pull/1025
  • Fix memory profiling regressions by @emeryberger in https://github.com/plasma-umass/scalene/pull/1027
  • Fix CLI line number truncation for lines > 999 by @emeryberger in https://github.com/plasma-umass/scalene/pull/1028
  • Fix issue #1022: pytest-xdist + --profile-all on Linux dropped user samples by @emeryberger in https://github.com/plasma-umass/scalene/pull/1055
  • Clamp core_utilization to [0, 1] (fixes #1032) by @emeryberger in https://github.com/plasma-umass/scalene/pull/1033

Full Changelog: https://github.com/plasma-umass/scalene/compare/v2.2.1...v2.3.0

Notes

If you use or refer to Scalene, please cite it as below.

Files

plasma-umass/scalene-v2.3.0.zip

Files (9.1 MB)

Name Size Download all
md5:935baddd0eb8f33e119efbe783e98800
9.1 MB Preview Download

Additional details

Related works