Performance Issues
ReSharper embedded profiler
In order to get a performance snapshot for ReSharper using an embedded profiler, follow these steps: How to collect a performance snapshot and send it to JetBrains Team.
Standalone dotTrace profiler
In order to get a performance snapshot for ReSharper using dotTrace follow these steps:
-
Download and install dotTrace Performance profiler from https://www.jetbrains.com/ | Select 64-bit version
-
Start dotTrace. The dotTrace Home window will open.
-
Select General preset.
-
Under Choose what you want to profile, New Process Run, click Add.
-
In the New Run Configuration wizard, choose Standalone and click Next.
-
Specify a path to the Visual Studio executable (devenv.exe).
-
Click Save.
-
Make sure the following options are set in Profiler Options:
- Profiling type: Timeline (or Tracing or Sampling if you have been asked to collect exactly Tracing/Timeline snapshot).
- Collect profiling data from start: on (if you're experiencing performance problems on Visual Studio startup or during solution loading) or off otherwise.
-
Click Start.
-
If there's a performance problem during startup:
- Wait while Visual Studio starts, open your solution;
- Wait until the solution is loaded and ReSharper finishes loading caches;
- Click Get Snapshot button in the profiling controller window.
-
Otherwise:
- Wait while Visual Studio starts, open your solution;
- Click Start button in the profiling controller window;
- Perform actions which are slow with ReSharper (typing, switching between documents, building etc);
- Click Get Snapshot button in the profiling controller window.
-
In JetBrains dotTrace Viewer that will open automatically, save the resulting snapshot using the the hamburger icon and then select Save Snapshot... menu.
-
Compress the snapshot file using Zip.
-
Upload the file to the JetBrains server.
-
Create a new issue in ReSharper issue tracker. In the issue, provide a short description of the performance problems you're experiencing and specify the name of your snapshot.
Use dotTrace Command-Line Profiler
-
Download the tool from here.
-
Steps that describe what steps you need to take to collect a snapshot are here.
-
Upload the file to the JetBrains server.
-
Create a new issue in ReSharper issue tracker. In the issue, provide a short description of the performance problems you're experiencing and specify the name of your snapshot.
Memory Issues
ReSharper embedded memory profiler
In order to get a memory snapshot for ReSharper using embedded profiler, follow these steps: Collect a ReSharper memory snapshot in Visual Studio.
Standalone dotMemory profiler
In case of memory issues with ReSharper, please follow the instructions below.
-
Download and install the trial version of dotMemory.
-
Run dotMemory. The dotMemory Home window will open.
-
Under Choose what you want to profile, New Process Run, click Add.
-
In the New Run Configuration wizard, choose Standalone and click Next.
-
Specify a path to the Visual Studio executable (devenv.exe). For example: C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE\devenv.exe
-
Click Save.
-
Click Start. This will run Visual Studio.
-
Open your solution and wait until it is completely loaded.
-
Collect a memory snapshot by clicking Get Snapshot in dotMemory.
-
In Visual Studio, perform actions that are suspected to cause memory issues (high memory traffic, exceptions, etc.).
-
Collect a snapshot one more time by clicking Get Snapshot in dotMemory.
-
Close Visual Studio.
-
In dotMemory on the Home page, on the left panel, choose Workspaces.
-
In the list of workspaces, right-click the desired workspace and, in the context menu, select Export.
-
Select a folder where you want a workspace file to be saved and click OK.
-
Upload the file to the JetBrains server.
-
Create a new issue in our issue tracker. In the issue, please provide:
- A short description of the issue.
- Steps required to reproduce the issue.
- The name of the uploaded file.
Use dotMemory Command-Line Profiler
-
Download the tool from here.
-
Steps that describe what steps you need to take to collect a snapshot are here.
-
Upload the file to the JetBrains server.
-
Create a new issue in ReSharper issue tracker. In the issue, provide a short description of the performance problems you're experiencing and specify the name of your snapshot.
.Net Memory Profiler
Prepare environment:
-
Before starting Visual Studio:
- Open devenv.exe.config in "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE"
- In the <runtime> section add <gcConcurrent enabled="false"/>
-
Download NmpCore.exe (or you can try newer version from the vendor site)
-
Enable Managed Memory Indicator in ReSharper | Options | Environment | General
Get snapshot:
-
Get process ID for devenv.exe process in question
-
Double-click managed memory indicator in Visual Studio status bar (to the right) to perform Garbage Collection
-
Execute the following command, substituting <pid> and path to snapshot:
NmpCore.exe /a <pid> /cs1 /sf "full-path-to-snapshot-file.prfsession"
Advanced snapshots:
- Download evaluation version of .Net Memory Profiler
- Install and start it
- Open Tools / Options, select "Call Stacks" page and uncheck "Enable stack reducer" on General tab
- Click "Profle application" on the main screen
- Enter path to Visual Studio executable "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe" and click Next
- Select "Custom" profiling level, and click Next
- Select "Full" on instance tracking page, and click Next
- Select "Yes" for the collect allocation call stacks choice, and click Next
- Select "No" for dispose tracker, real-time data collection, heap utilization, AppDomain tracker, unmanaged resources tracker and instance data trackers.
- Click Start to start process and begin profiling
- Open your solution and after everything settles down, click Collect Snapshot in profiler to create base-line snapshot
- Perform actions that are producing memory traffic, or cause excess memory allocations
- Collect snapshot
- Hit "Stop profiling" button and save snapshots in a .prfsession file
Upload snapshot and create an issue:
- Compress the resulting snapshot using Zip
- Upload it to the JetBrains server.
- Create a new issue in ReSharper issue tracker. In the issue, provide a short description of the memory consumption problems you're experiencing, and specify the name of your snapshot.
ReSharper out-of-process
The following steps can be used to profile ReSharper backend process: How to profile ReSharper backend process.
Comments
0 comments
Please sign in to leave a comment.