core icon indicating copy to clipboard operation
core copied to clipboard

CPU spike on macOS after installing .net 5.0!

Open kulashaker30 opened this issue 5 years ago • 8 comments

CPU is spiking after installing .net 5.0

.net 5.0 on macOs Catalina 10.15.17

After installing .Net 5.0 on macOS Catalina 10.15.17, my CPU% is spiking already just when I started running VS Code. I checked Activity Monitor and I have found that "dotnet" process is already 100% that is without running a .net app yet. So what I did is I forced quit the "dotnet" process on Activity Monitor; the CPU% started to go down(with VS Code still open). I tried running an blazor app(dotnet run) without browsing the app then the CPU% spiked to 100% again; I forced quit my blazor app CPU goes down. This issue was not happening on previous versions of .net on my mac.

Screen Shot 2020-12-25 at 11 51 54 AM

Screen Shot 2020-12-25 at 11 52 05 AM

kulashaker30 avatar Dec 25 '20 03:12 kulashaker30

@filipw can you help us determine if this is a .NET 5 or Omnisharp related issue?

scalablecory avatar Jan 13 '21 23:01 scalablecory

It honestly doesn't look like it to me because OmniSharp is not a dotnet process but a mono process. It does temporarily spin up dotnet occasionally to e.g. determine dotnet version or run tests but these processes are then immediately killed.

Based on the description it sounds like it's either some other extension or something in the runtime. Especially this statement doesn't indicate anything editor specific: I tried running an blazor app(dotnet run) without browsing the app then the CPU% spiked to 100% again;

filipw avatar Jan 14 '21 08:01 filipw

@filipw My editor is VS Code and it is not a mono process that causes this because if it is a mono it will be shown in the Activity Monitor.

kulashaker30 avatar Jan 14 '21 08:01 kulashaker30

@filipw I also stated my editor.

Screen Shot 2021-01-14 at 4 34 01 PM

kulashaker30 avatar Jan 14 '21 08:01 kulashaker30

Hey @Pilchie do you know who the best contact for Blazor is?

carlossanlop avatar Feb 03 '21 23:02 carlossanlop

I'd ping @danroth27 for Blazor issues

mairaw avatar Feb 04 '21 00:02 mairaw

Adding @mkArtakMSFT to take a look from the engineering side for Blazor.

danroth27 avatar Feb 04 '21 00:02 danroth27

@kulashaker30 any chance you can get what the commandline of the dotnet process is?

Also tagging @sebastienros for advice on getting a trace so we can see where time is being spent.

Pilchie avatar Feb 04 '21 00:02 Pilchie