# \#profiling

**URL:** https://discourse.julialang.org/tag/profiling/335.md

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

---

## [\[ANN\] CodeGlass – see what your code is actually doing](https://discourse.julialang.org/t/ann-codeglass-see-what-your-code-is-actually-doing/137020)

<div class="topic-metadata">

**Author:** [@Tyrone](https://discourse.julialang.org/u/Tyrone)\
**Replies:** 17\
**Last updated:** [September 3, 2026, 8:07am UTC](https://discourse.julialang.org/t/ann-codeglass-see-what-your-code-is-actually-doing/137020 "2026-09-03T08:07:02Z")

</div>

Hi all, Over the past few years, we’ve been building runtime analysis tools for different languages and use cases, including Julia. Today, we would like to officially announce the release of our Julia profiling toolbox:…

---

## [ANN: ProfilePerfetto.jl – Easy profiling with interactive viewer](https://discourse.julialang.org/t/ann-profileperfetto-jl-easy-profiling-with-interactive-viewer/136920)

<div class="topic-metadata">

**Author:** [@fonsp](https://discourse.julialang.org/u/fonsp)\
**Replies:** 10\
**Last updated:** [May 3, 2026, 9:00pm UTC](https://discourse.julialang.org/t/ann-profileperfetto-jl-easy-profiling-with-interactive-viewer/136920 "2026-05-03T21:00:27Z")

</div>

New package: ProfilePerfetto.jl I made a new package! With @perfetto, you can profile a piece of code, and view the profile using the Perfetto browser-based trace viewer. Example using ProfilePerfetto @perfetto\_open my…

---

## [Why do \`@allocated\` and \`Profile.Allocs.@profile\` give different results?](https://discourse.julialang.org/t/why-do-allocated-and-profile-allocs-profile-give-different-results/134956)

<div class="topic-metadata">

**Author:** [@matthias314](https://discourse.julialang.org/u/matthias314)\
**Replies:** 1\
**Last updated:** [March 10, 2026, 2:52pm UTC](https://discourse.julialang.org/t/why-do-allocated-and-profile-allocs-profile-give-different-results/134956 "2026-03-10T14:52:52Z")

</div>

The number of allocations reported by Profile.Allocs.@profile agrees with @allocations, but the total number of bytes allocated differs from @allocated for some reason: using Profile.Allocs f(n) = sum(2\*collect(1:n)) …

---

## [\[ANN\] ZoneProfilers.jl: Another interface for the Tracy profiler](https://discourse.julialang.org/t/ann-zoneprofilers-jl-another-interface-for-the-tracy-profiler/133806)

<div class="topic-metadata">

**Author:** [@nhz2](https://discourse.julialang.org/u/nhz2)\
**Replies:** 0\
**Last updated:** [November 11, 2025, 11:22pm UTC](https://discourse.julialang.org/t/ann-zoneprofilers-jl-another-interface-for-the-tracy-profiler/133806 "2025-11-11T23:22:52Z")

</div>

I have been working on an interface for the tracy profiler to profile a multithreaded program I am working on. There are two closely related packages. ZoneProfilers.jl provides utilities to mark up code and a P…

---

## [What is included in the output of \`--trace-compile\`?](https://discourse.julialang.org/t/what-is-included-in-the-output-of-trace-compile/133016)

<div class="topic-metadata">

**Author:** [@lkdvos](https://discourse.julialang.org/u/lkdvos)\
**Replies:** 2\
**Last updated:** [October 9, 2025, 9:47pm UTC](https://discourse.julialang.org/t/what-is-included-in-the-output-of-trace-compile/133016 "2025-10-09T21:47:32Z")

</div>

I’m playing around a bit with the new --trace-compile-timing flag for julia 1.12, and while I am excited about this feature, there are a couple questions I’m having for which I can’t seem to easily find an answer. The s…

---

## [Viewing profiling info with signal-triggered profile](https://discourse.julialang.org/t/viewing-profiling-info-with-signal-triggered-profile/131541)

<div class="topic-metadata">

**Author:** [@Ken\_Williams](https://discourse.julialang.org/u/Ken_Williams)\
**Replies:** 0\
**Last updated:** [August 11, 2025, 10:39pm UTC](https://discourse.julialang.org/t/viewing-profiling-info-with-signal-triggered-profile/131541 "2025-08-11T22:39:41Z")

</div>

When capturing profiling data as described in Profiling - Triggered During Execution, is there a way to view the results in VS Code’s normal flame graph view? I haven’t found any good way to comb through the results, I …

---

## [New on Forem: “Profile a short-running function”](https://discourse.julialang.org/t/new-on-forem-profile-a-short-running-function/129581)

<div class="topic-metadata">

**Author:** [@oheil](https://discourse.julialang.org/u/oheil)\
**Replies:** 0\
**Last updated:** [June 2, 2025, 7:37pm UTC](https://discourse.julialang.org/t/new-on-forem-profile-a-short-running-function/129581 "2025-06-02T19:37:05Z")

</div>

@nsajko shows some insights into profiling Julia on Forem: Thanks for sharing this!

---

## [Slow array access during labeling algorithm](https://discourse.julialang.org/t/slow-array-access-during-labeling-algorithm/128366)

<div class="topic-metadata">

**Author:** [@Walter](https://discourse.julialang.org/u/Walter)\
**Replies:** 9\
**Last updated:** [May 7, 2025, 8:03pm UTC](https://discourse.julialang.org/t/slow-array-access-during-labeling-algorithm/128366 "2025-05-07T20:03:12Z")

</div>

Hi all, I switched from Python to Julia and are currently implementing a column generation algorithm for a vehicle routing problem. To generate a column (route) with negative reduced cost, I use a labeling algorithm. T…

---

## [Which profile visualizers show type instability](https://discourse.julialang.org/t/which-profile-visualizers-show-type-instability/125376)

<div class="topic-metadata">

**Author:** [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Replies:** 2\
**Last updated:** [January 30, 2025, 12:38pm UTC](https://discourse.julialang.org/t/which-profile-visualizers-show-type-instability/125376 "2025-01-30T12:38:41Z")

</div>

I cannot get ProfileView.jl to work on Wayland because of a shared library incompatibility. I will file a bug report as soon as I isolate the problem, but in the meantime I am looking for a replacement/alternative. Whic…

---

## [Troubleshooting allocations in SymbolicUtils code](https://discourse.julialang.org/t/troubleshooting-allocations-in-symbolicutils-code/122027)

<div class="topic-metadata">

**Author:** [@ctessum](https://discourse.julialang.org/u/ctessum)\
**Replies:** 2\
**Last updated:** [November 1, 2024, 8:57am UTC](https://discourse.julialang.org/t/troubleshooting-allocations-in-symbolicutils-code/122027 "2024-11-01T08:57:34Z")

</div>

Hello! I have some a model here that is having some performance issues. I’ve included below a screenshot of a performance profile: As you can see, the majority of the time is being taken up by a macro expansion in S…

---

## [Is VSCode \`@profview\` broken on 1.11?](https://discourse.julialang.org/t/is-vscode-profview-broken-on-1-11/121630)

<div class="topic-metadata">

**Author:** [@gdalle](https://discourse.julialang.org/u/gdalle)\
**Replies:** 4\
**Last updated:** [October 26, 2024, 8:45am UTC](https://discourse.julialang.org/t/is-vscode-profview-broken-on-1-11/121630 "2024-10-26T08:45:42Z")

</div>

When I run the profiling code from this example in VSCode with Julia 1.11, the flame graph is empty. With Julia 1.10 it displays the usual way. function profile\_test(n) for i = 1:n A = randn(100,100,20) …

---

## [@profile slows down MPI?](https://discourse.julialang.org/t/profile-slows-down-mpi/121700)

<div class="topic-metadata">

**Author:** [@johnomotani](https://discourse.julialang.org/u/johnomotani)\
**Replies:** 0\
**Last updated:** [October 24, 2024, 2:10pm UTC](https://discourse.julialang.org/t/profile-slows-down-mpi/121700 "2024-10-24T14:10:33Z")

</div>

Is anybody else having problems when trying to @profile an MPI program? I seem to find that when I add @profile my code slows down a lot, with a load of time being spent in MPI calls (a lot more than I would expect). I t…

---

## [How can this weird \`@profview\` vs \`@time\` result be explained?](https://discourse.julialang.org/t/how-can-this-weird-profview-vs-time-result-be-explained/121234)

<div class="topic-metadata">

**Author:** [@jules](https://discourse.julialang.org/u/jules)\
**Replies:** 2\
**Last updated:** [October 13, 2024, 5:18am UTC](https://discourse.julialang.org/t/how-can-this-weird-profview-vs-time-result-be-explained/121234 "2024-10-13T05:18:39Z")

</div>

I’m trying to profile record in Makie to see where there might be optimization potential. So I was just calling @profview on a simple record invocation with a throwaway plot, like this: julia\> using GLMakie julia\> @pro…

---

## [Help diagnosing slow compilation](https://discourse.julialang.org/t/help-diagnosing-slow-compilation/117938)

<div class="topic-metadata">

**Author:** [@benninkrs](https://discourse.julialang.org/u/benninkrs)\
**Replies:** 4\
**Last updated:** [August 12, 2024, 3:36am UTC](https://discourse.julialang.org/t/help-diagnosing-slow-compilation/117938 "2024-08-12T03:36:03Z")

</div>

I have a function that runs very fast but is slow to compile. I have tried using SnoopCompile functions @snoop\_inference and @snoop\_llvm, but they don’t seem to show where the large latency is residing. I’m new to comp…

---

## [Spending a lot of time in \`materialize\` called by \`findall\`](https://discourse.julialang.org/t/spending-a-lot-of-time-in-materialize-called-by-findall/117859)

<div class="topic-metadata">

**Author:** [@Oblomov](https://discourse.julialang.org/u/Oblomov)\
**Replies:** 14\
**Last updated:** [August 7, 2024, 6:01am UTC](https://discourse.julialang.org/t/spending-a-lot-of-time-in-materialize-called-by-findall/117859 "2024-08-07T06:01:08Z")

</div>

Hello all, I’m new to Julia and as an exercise I’ve ported a medium-complex Python code to Julia. Even without particular optimizations, the Julia code is 4 to 5 times faster than Python (nice!), but I’ve decided to try…

---

## [Nice talk about Go PGO. What is the state in Julia?](https://discourse.julialang.org/t/nice-talk-about-go-pgo-what-is-the-state-in-julia/115715)

<div class="topic-metadata">

**Author:** [@Dan](https://discourse.julialang.org/u/Dan)\
**Replies:** 8\
**Last updated:** [June 24, 2024, 4:40pm UTC](https://discourse.julialang.org/t/nice-talk-about-go-pgo-what-is-the-state-in-julia/115715 "2024-06-24T16:40:48Z")

</div>

These devs get it! The first 10 minutes are about the Go ecosystem and are worth it for any language devs. The rest are a great introduction to optimization issues and PGO. P.S. What is the state of PGO in Julia? I wo…

---

## [Solving type instability when using Graphs.jl](https://discourse.julialang.org/t/solving-type-instability-when-using-graphs-jl/112862)

<div class="topic-metadata">

**Author:** [@alemelis](https://discourse.julialang.org/u/alemelis)\
**Replies:** 4\
**Last updated:** [April 12, 2024, 10:50am UTC](https://discourse.julialang.org/t/solving-type-instability-when-using-graphs-jl/112862 "2024-04-12T10:50:56Z")

</div>

This is the flame plot I get when profiling my iterative solver. You can see it’s pointed by tiny red blocks, which I’m trying to address one by one. In particular I’m now looking at the one highlighted by the red a…

---

## [Profiling code with heavy IO times](https://discourse.julialang.org/t/profiling-code-with-heavy-io-times/111589)

<div class="topic-metadata">

**Author:** [@ianfiske](https://discourse.julialang.org/u/ianfiske)\
**Replies:** 0\
**Last updated:** [March 13, 2024, 7:57pm UTC](https://discourse.julialang.org/t/profiling-code-with-heavy-io-times/111589 "2024-03-13T19:57:46Z")

</div>

Usually I can get a lot of mileage out of the user-friendly @profview macro and I get all the info I need to spot performance bottlenecks. However, sometimes I have code where there is a lot of IO (e.g., downloading var…

---

## [Failed to profile CUDA.jl with Nsight Systems 2024.1.1](https://discourse.julialang.org/t/failed-to-profile-cuda-jl-with-nsight-systems-2024-1-1/110051)

<div class="topic-metadata">

**Author:** [@yuwenchen95](https://discourse.julialang.org/u/yuwenchen95)\
**Replies:** 4\
**Last updated:** [February 13, 2024, 11:19am UTC](https://discourse.julialang.org/t/failed-to-profile-cuda-jl-with-nsight-systems-2024-1-1/110051 "2024-02-13T11:19:54Z")

</div>

I am following the doc to learn profiling GPU in Julia. When I followed $ nsys launch julia It started a Julia terminal but then failed when I run using CUDA and return errors: Please submit a bug report with steps …

---

## [Profiler doesn't show Threads](https://discourse.julialang.org/t/profiler-doesnt-show-threads/109774)

<div class="topic-metadata">

**Author:** [@dbrohl](https://discourse.julialang.org/u/dbrohl)\
**Replies:** 6\
**Last updated:** [February 6, 2024, 2:45pm UTC](https://discourse.julialang.org/t/profiler-doesnt-show-threads/109774 "2024-02-06T14:45:52Z")

</div>

I want to use multithreading in a project. I use Julia in VS Code and use the build-in profiler of the VSCode extension. The 8 threads appear in the profiler dropdown menu, but all threads except the first only have one …

---

## [Why does profiling suggest that integer comparison dominates broadcasted assignment?](https://discourse.julialang.org/t/why-does-profiling-suggest-that-integer-comparison-dominates-broadcasted-assignment/109606)

<div class="topic-metadata">

**Author:** [@jishnub](https://discourse.julialang.org/u/jishnub)\
**Replies:** 4\
**Last updated:** [February 3, 2024, 2:47am UTC](https://discourse.julialang.org/t/why-does-profiling-suggest-that-integer-comparison-dominates-broadcasted-assignment/109606 "2024-02-03T02:47:53Z")

</div>

julia\> a = rand(40000,4000); b = rand(40000,4000); julia\> Profile.clear() julia\> @bprofile $a\[1:end, 1:end\] .= $b BenchmarkTools.Trial: 9 samples with 1 evaluation. Range (min … max): 571.819 ms … 586.555 ms ┊ GC (m…

---

## [Group profiling flame graph tiles](https://discourse.julialang.org/t/group-profiling-flame-graph-tiles/108384)

<div class="topic-metadata">

**Author:** [@gdalle](https://discourse.julialang.org/u/gdalle)\
**Replies:** 4\
**Last updated:** [January 5, 2024, 9:17pm UTC](https://discourse.julialang.org/t/group-profiling-flame-graph-tiles/108384 "2024-01-05T21:17:01Z")

</div>

An integration + optimization code I’m working on generates flame graphs like this one, which are very hard to parse. Indeed, the same underlying function is called by several different lines of the code, so even if I sp…

---

## [Alternatives to flame graphs for profiler](https://discourse.julialang.org/t/alternatives-to-flame-graphs-for-profiler/103328)

<div class="topic-metadata">

**Author:** [@pjuergens](https://discourse.julialang.org/u/pjuergens)\
**Replies:** 6\
**Last updated:** [November 20, 2023, 12:03am UTC](https://discourse.julialang.org/t/alternatives-to-flame-graphs-for-profiler/103328 "2023-11-20T00:03:59Z")

</div>

Hello there, I am wondering if there is an alternative way to show profiler results (at best in VS Code) than a simple flame graph. What I’m basically looking for is a way to see cumulated time spend in a function/line …

---

## [Type Inference Issues in IterativeSolvers with LinearMaps](https://discourse.julialang.org/t/type-inference-issues-in-iterativesolvers-with-linearmaps/106007)

<div class="topic-metadata">

**Author:** [@leespen1](https://discourse.julialang.org/u/leespen1)\
**Replies:** 2\
**Last updated:** [November 9, 2023, 8:07pm UTC](https://discourse.julialang.org/t/type-inference-issues-in-iterativesolvers-with-linearmaps/106007 "2023-11-09T20:07:53Z")

</div>

I was trying to improve the performance of a program I use that makes heavy use of implicit time stepping, which results in me solving linear systems of equations ‘Ax=b’. Because of things that have to do with my specifi…

---

## [Trouble with PProf: no data?](https://discourse.julialang.org/t/trouble-with-pprof-no-data/105022)

<div class="topic-metadata">

**Author:** [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Replies:** 0\
**Last updated:** [October 16, 2023, 3:45pm UTC](https://discourse.julialang.org/t/trouble-with-pprof-no-data/105022 "2023-10-16T15:45:12Z")

</div>

I do Profile.Allocs.clear() Profile.Allocs.@profile K = conductivity(femm, geom, Temp) PProf.Allocs.pprof() I get but in the browser There is nothing there! When I click on View/Source I get the error m…

---

## [Why the function sum1 is faster than builtin sum](https://discourse.julialang.org/t/why-the-function-sum1-is-faster-than-builtin-sum/104051)

<div class="topic-metadata">

**Author:** [@VinodV](https://discourse.julialang.org/u/VinodV)\
**Replies:** 14\
**Last updated:** [September 21, 2023, 8:17am UTC](https://discourse.julialang.org/t/why-the-function-sum1-is-faster-than-builtin-sum/104051 "2023-09-21T08:17:21Z")

</div>

julia\> using BenchmarkTools julia\> function sum1(num) total = 0 for i in num total += i end return total end sum1 (generic function with 1 method) julia\> a = coll…

---

## [Profiling tests: how to tell for how long did each test set execute?](https://discourse.julialang.org/t/profiling-tests-how-to-tell-for-how-long-did-each-test-set-execute/101938)

<div class="topic-metadata">

**Author:** [@nsajko](https://discourse.julialang.org/u/nsajko)\
**Replies:** 0\
**Last updated:** [July 22, 2023, 6:25pm UTC](https://discourse.julialang.org/t/profiling-tests-how-to-tell-for-how-long-did-each-test-set-execute/101938 "2023-07-22T18:25:55Z")

</div>

Sometimes, while developing tests, the test suite will take too long to run. In such a situation I’m interested in optimizing the test suite by removing test cases from some test sets. How to tell which test sets execute…

---

## [How to preallocate and reuse buffers for oft-repeated computation?](https://discourse.julialang.org/t/how-to-preallocate-and-reuse-buffers-for-oft-repeated-computation/100915)

<div class="topic-metadata">

**Author:** [@philip](https://discourse.julialang.org/u/philip)\
**Replies:** 15\
**Last updated:** [July 12, 2023, 10:15am UTC](https://discourse.julialang.org/t/how-to-preallocate-and-reuse-buffers-for-oft-repeated-computation/100915 "2023-07-12T10:15:48Z")

</div>

In How to optimise Julia code: A practical guide, Jakob Nissen suggests that one way to optimize code + reduce allocations is to Preallocate buffers once and reuse them multiple times I’m wondering if someone has a wa…

---

## [Performance & Profiling Tips for Beginner Code](https://discourse.julialang.org/t/performance-profiling-tips-for-beginner-code/100585)

<div class="topic-metadata">

**Author:** [@physh](https://discourse.julialang.org/u/physh)\
**Replies:** 14\
**Last updated:** [June 26, 2023, 9:18am UTC](https://discourse.julialang.org/t/performance-profiling-tips-for-beginner-code/100585 "2023-06-26T09:18:04Z")

</div>

Dear all, I have been using Julia for a few months now, writing code mostly without worrying too much about performance (profiling very briefly with @time/@btime to make sure nothing too horribly is happening though). I…

---

## [Profiling in VSCode shows blank tab on first run?](https://discourse.julialang.org/t/profiling-in-vscode-shows-blank-tab-on-first-run/100492)

<div class="topic-metadata">

**Author:** [@gdalle](https://discourse.julialang.org/u/gdalle)\
**Replies:** 2\
**Last updated:** [June 17, 2023, 6:10pm UTC](https://discourse.julialang.org/t/profiling-in-vscode-shows-blank-tab-on-first-run/100492 "2023-06-17T18:10:49Z")

</div>

Hi everyone, In the last few weeks, I have found that the @profview macro from the VSCode extension shows a blank tab the first time I run it, and then gives me the flame graph on the second run. Does it happen to anyon…

[Next page](https://discourse.julialang.org/tag/profiling/335.md?match_all_tags=true&page=1&tags%5B%5D=profiling)
