Skip to content

High CPU Load and bad editor responsiveness in blazor server project #23095

@vsfeedback

Description

@vsfeedback

This issue has been moved from a ticket on Developer Community.


Working with a solution containing razor components (Blazor server app) shows increasing memory usage of VS2019 processes (devenv.exe and ServiceHub.RoslynCodeAnalysisService32.exe) and correlated bad VS editing performance (typing, intellisense, parameter suggestions, etc).

The bad performance starts after some minutes (!) working with the solution and worsens to a state that is not usable anymore. Often, VS eventually auto-closes and -restarts (crash). I see RAM usages of several GB of both aforementioned processes in such situations.

Working with solutions not containing razor components on the same machine with the same VS2019 does NOT show these symptoms.

This problem makes work with VS2019 very unproductive, as it becomes unbearably slow after mere minutes of usage, and needs (or enforces) VS restarts several times a workday.


Original Comments

Visual Studio Feedback System on 6/9/2020, 00:59 AM:

We have directed your feedback to the appropriate engineering team for further evaluation. The team will review the feedback and notify you about the next steps.

Riccardo Zucchetto on 6/10/2020, 01:39 AM:

Hi,
I experience the same problem. The only difference is that one of the two processes using tons of memory is ServiceHub.Host.CLR.x86 (32 bit).
I can confirm everything that Dr. Tim dos Santos stated, I have experienced every kind of behavior he highlighted.

Just an addition: when I kill ServiceHub.Host.CLR.x86 (32 bit) process, Visual Studio becomes a bit more responsive. Sometimes I can use it for hours, but sometimes it becomes unusable since Intellisense and other features are gone. When killed, a yellow strip appears, with the indication that a fatal error happened and it should be better to close and reopen visual studio. The call stack is the following:

StreamJsonRpc.ConnectionLostException : La connessione JSON-RPC con la parte remota è andata persa prima del completamento della richiesta.
at async StreamJsonRpc.JsonRpc.InvokeCoreAsync(<Parametri sconosciuti>)
at async StreamJsonRpc.JsonRpc.InvokeCoreAsync[TResult](<Parametri sconosciuti>)
at async Microsoft.CodeAnalysis.Remote.RemoteEndPoint.InvokeAsync(<Parametri sconosciuti>)
at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)

I hope it may be helpful to identify and fix the issue.
Riccardo

Visual Studio Feedback System on 6/10/2020, 11:14 PM:

Thank you for sharing your feedback! Our teams prioritize action on product issues with broad customer impact. See details at: https://docs.microsoft.com/en-us/visualstudio/ide/report-a-problem?view=vs-2019#faq. In case you need answers to common questions or need assisted support, be sure to use https://visualstudio.microsoft.com/vs/support/. We’ll keep you posted on any updates to this feedback.

Dr. Tim dos Santos on 6/17/2020, 10:19 PM:

Short update to this: I found out that the slowdown is NOT dependent on whether I actually OPEN / EDIT the .razor files. Every solution containing .razor files shows the performance problems, even when only editing .cs files; solutions without .razor files don't.


Original Solutions

(no solutions)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions