Performance Profiling in Rider 2018.3. What’s New?
If you’re an active Rider 2018.3 user or just follow our blog, you probably know that Rider just got an integrated performance profiler based on JetBrains dotTrace. Though we’ve already reviewed the profiler features on the EAP stage, the release version brings some important changes, especially concerning profiling session configuration. Read this post to learn more about the changes.
Supported OSs and frameworks
Just to reiterate: in Rider 2018.3, the profiler supports only Windows + .NET Framework / .NET Core. We’re on the finish line with adding support for Mono and Mono Unity (as well as support for Linux and MacOS), but the feature still requires some polishing. It is highly likely that you will see it in early 2019.1 EAP builds.
What can you profile in Rider?
A quick reminder of what can be a profiling target:
- NET / .NET Core standalone applications
- ASP.NET / ASP.NET Core web applications (IIS Express only)
- Arbitrary .NET / .NET Core processes
- NUnit / xUnit / MSTest unit tests
In this post, we’ll take a quick look at how you can profile apps in Rider. For details on how to profile tests or arbitrary .NET processes, please refer to the Rider documentation. So, what has changed exactly in the release version of Rider 2018.3?
Configuring and starting a profiling session
Session configuration has been affected the most as it is no longer part of run configuration:
- Profiling session configuration is a separate entity that is selected/edited right from the toolbar.
- Profiling target is always an executable specified in the currently selected run configuration. For example, if you profile a web app on IIS Express, the profiling target is
iisexpress.exe
that runs this web app. Currently, you can profile the following run configuration types: - To start a session, simply select a profiling configuration and click the same control on the toolbar.
Getting snapshots
This part hasn’t changed much since the EAP stage. It’s quite straightforward: after the profiling session starts, do what you need to do in your application, and then click Get Snapshot.
Analyzing snapshots
Once you have a performance snapshot, use the Top Methods view and the Call Tree view to determine the cause of a performance bottleneck. The analysis workflow has changed somewhat after the EAP.
Combined Call Tree and Top Methods
First of all, the Top Methods and Call Tree views are now connected with each other. If Follow the selection is turned on, Top Methods shows methods only for the subtree that is currently selected in Call Tree.
Filters for Timeline snapshots
The second improvement is related to Timeline profiling. We’ve added more filters comparing to the EAP. Now, you can use four basic filters:
- by thread,
- by thread state,
- by method, and
- by subsystem.
Improved navigation
The navigation capabilities are also improved. You can navigate:
- from a snapshot to code,
- from code to a snapshot,
- from Search Everywhere to a snapshot.
As always, we invite you to download the latest Rider to try its new profiling features in practice.
Dew Drop - January 17, 2019 (#2880) - Morning Dew says:
January 17, 2019[…] Performance Profiling in Rider 2018.3. What’s New? (Alexey Totin) […]
Joseph Woodward says:
January 17, 2019Any estimates on when we can expect to see this feature on Mac and Linux?
Alexey Totin says:
January 17, 2019Hi Joseph,
it is highly likely that you will see it in 2019.1.
Joseph Woodward says:
January 17, 2019Thanks, so excited for this. I check the nightly releases daily 😀
Vasily Kirichenko says:
January 17, 2019Line-by-line mode should result with call number on the gutter next to every line.
Alexey Totin says:
January 17, 2019Hi Vasily,
yes, showing performance data right in the editor is one of the features we’re currently working on, so, stay tuned 😉
Sealin says:
January 17, 2019Is there a plan to implement the winform designer? C# is really needs this feature.
Alexey Totin says:
January 17, 2019Hi,
WinForms designer for Rider is in development. Here is the corresponding task in our tracker: https://youtrack.jetbrains.com/issue/RIDER-1034. Feel free to upvote.
Sealin says:
January 18, 2019Thank you, it’s great!
Dew Drop - January 18, 2019 (#2881) - Morning Dew says:
January 18, 2019[…] Performance Profiling in Rider 2018.3. What’s New? (Alexey Totin) […]
Abrari says:
January 21, 2019I cannot find the profiling toolbar on my installation (Rider 2018.3.1 on Windows 10).
How can I show the toolbar? Or does the profiling action accessible from the main menu?
Vasily Kirichenko says:
January 21, 2019The commands are under “Run” main menu.
Alexey Totin says:
January 21, 2019Hi,
using the profiler requires a license for either the Rider + ReSharper Ultimate or the All Products Pack. Once you have it, the bundled dotTrace plugin is installed by default, otherwise, not. Maybe this is the problem?
abrari says:
January 22, 2019Thanks for clarifying. I only have Rider license, so that is the problem (this article didn’t mention about license requirement for the profiler).
Felipe says:
June 14, 2019Any updates on macOS ?
Maarten Balliauw says:
June 17, 2019That’s still being worked on, nothing to report for now.
Robert Knox says:
August 30, 2019~2.5 months later; is there any new update on this feature for macOS and Rider please?
Alexey Totin says:
August 30, 2019HI Robert,
you can profile Mono and Unity apps in Rider 2019.1+ on Linux and macOS. Support for .NET Core is still a work in progress.
Harsimran says:
May 22, 2020Any update on profiling .Net Core?
Alexey Totin says:
May 25, 2020Hi! Yes, it’s available on all OSs: https://www.jetbrains.com/help/rider/2020.1/Performance_Profiling.html?utm_campaign=RD&utm_content=2020.1&utm_medium=link&utm_source=product#supported_os_frameworks