# \[ANN\] TerminalScope.jl - An interface for Profile, SnoopCompile, and Cthulhu

**URL:** <https://discourse.julialang.org/t/ann-terminalscope-jl-an-interface-for-profile-snoopcompile-and-cthulhu/138941>\
**Category:** Package Announcements\
**Created:** [August 20, 2026, 1:14am UTC](https://discourse.julialang.org/t/ann-terminalscope-jl-an-interface-for-profile-snoopcompile-and-cthulhu/138941 "2026-08-20T01:14:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [August 20, 2026, 1:14am UTC](https://discourse.julialang.org/t/ann-terminalscope-jl-an-interface-for-profile-snoopcompile-and-cthulhu/138941/1 "2026-08-20T01:14:30Z")

</div>

Hi everyone!

I want to announce **TerminalScope.jl** , an interactive terminal user interface build using Tachikoma.jl (thanks @kahliburke!) to diagnose the performance of Julia code. It bundles four analyses under one macro:

- **Runtime profile** : where the time is spent, from the sampling profiler (using `Profile`);
- **Allocation profile** : where the memory is allocated, including what was allocated (using `Profile`);
- **Inference profile** : where the compiler spends its time inferring types (using `SnoopCompile`);
- **Invalidations** : which method definitions invalidate previously compiled code (using `SnoopCompile`).

On top of those, a **type-instability inspector** , based on `Cthulhu.@descend`, shows the source code annotated with the inferred types and lets you descend through the call sites, directly from any profiled frame.

 ![Runtime profile viewer](https://global.discourse-cdn.com/julialang/original/3X/f/8/f82210aac92414dfa61dba0e9b2faeebfdf90ad7.png)

Everything is reached through the `@scope` macro, whose first argument selects the mode:

```julia
using TerminalScope

@scope f(x) # Runtime profile (default mode).
@scope allocs f(x) # Allocation profile.
@scope inference f(x) # Type-inference profile.
@scope invalidations using SomePkg # Method invalidations.
@scope descend f(x) # Type-instability inspector.

```

Each mode opens a full-screen viewer with the frame list on the left and the source code of the selected row, updated live while navigating, on the right. Some highlights:

- A heat-colored **flame graph** of the whole profile along the bottom of the screen on terminals with Kitty graphics or Sixel support, following (and clickable to change) the current selection.
- **Mouse support** : the wheel scrolls the hovered panel and a click selects a row.
- **Vim-style navigation** , whole-tree frame **search** (including regex) with `/`, a **flat self-time ranking** with `s`, and **jump to your editor** at the selected frame with `e`.
- **Dark and light themes** , with every color overridable through Preferences.jl.

TerminalScope requires Julia 1.12 or later. I just ask for registration, so it will take 3 days to appear in the General registry.

- Repository: [GitHub - ronisbr/TerminalScope.jl: Interactive terminal UI to diagnose Julia code: runtime and allocation profiling, inference time, invalidations, and Cthulhu-style type-instability inspection. · GitHub](https://github.com/ronisbr/TerminalScope.jl)
- Documentation: [Home · Terminal Scope](https://ronisbr.github.io/TerminalScope.jl/dev)

Feedback, issues, and contributions are very welcome!

---

<div class="post-metadata">

**Author:** ![Ronis\_BR](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ronis_br/32/50999_2.png) [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Post date:** [August 24, 2026, 2:37pm UTC](https://discourse.julialang.org/t/ann-terminalscope-jl-an-interface-for-profile-snoopcompile-and-cthulhu/138941/2 "2026-08-24T14:37:59Z")

</div>

The package is now in Registry!

Here are some videos of how we can use it to analyze the code.

# Invalidations

# Performance (Profile)

# Allocations

# Type Stability (descend)

Note: When opening any file, you can type `e` to open this file using `$EDITOR`.
