What happend to @profview

I used to use @profview (defiend in VSCodeServer) in vscode to analyze the cpu time of functions, which provide sth like this


The time costs are very clear.

But now I get different result like the following using the same macro @profview


where has no information about time.
The question is that how could I do profile like the old way? Appreciate if anyone could help~

You can’t, at least not easily.

In my experience the times reported by @profview were wildly inaccurate and mostly useless; in general, they are proportional to the sample count also shown in the new UI, so there shouldn’t be less info here (just less pretending to give you accurate timings).

Thanks, it seems I should get used to the new one.

If you really want the table though you can always profile manually

1 Like

I strongly prefer the old way. Why would you just remove a feature? It would also display the self and total times above each function. I know it wasn’t super accurate but it was extremely useful to me.

Not only you. The old way is a kind of ‘matlab’ style(what i hate…), but very easy to see although as pfitzseb said it’s inaccurate. I guess the inaccuracy is most big problem, and we should lean that ‘flame graph’ or anything…

I did a little research and here’s what I found. The “old way” was just generating a .cpuprofile file and opening it with vscode’s built-in .cpuprofile viewer, vscode-js-profile-visualizer, originally designed for js profiling. This is still possible to do manually by using ChromeProfileFormat.jl to generate a .cpuprofile file.

The “new way” is to use a Julia-specific package to display profile results: ProfileCanvas.jl. It’s probably a good idea in the long run to stop relying on vscode-js-profile-visualizer, and the new package also gives us control over how profile results are displayed. Unfortunately ProfileCanvas.jl is not being actively developed, so we’re stuck with the current format until somebody decides to take it on.

@pfitzseb might have something to say about ProfileCanvas not being “actively developed” :wink: I seem to recall quite a bit of activity a few months back

You’re right, sorry. @pfitzeb has indeed been doing great work on this package, indeed he’s carried it solo up till now. It’s a good package to have, and it looks great! But he is after all just one person who by his own admission doesn’t have time to work on this feature. There is an issue open for it, though, and I think it would great for new contributors to help share the load. I’m currently trying to finish my degree so time is at a bit of a premium, but I’ll lend a hand if I can find the time.

I seem to recall there being some mechanism for tagging issues as good entry points for new contributors. Would that be appropriate/possible in this case?

As always, things like these are a matter of prioritization – we haven’t had many people telling us they’re missing the old UI, for example (roughly four, including this thread, if I remember correctly). Also note that the switch to our own UI did fix a actual issues with the previous solution, I didn’t just decide to implement that for fun :slight_smile:

2 Likes