Omnisharp-vscode: Slow Debugging on VS Code on Mac

Created on 7 Dec 2018  路  4Comments  路  Source: OmniSharp/omnisharp-vscode

I was ask to file this issue here by the VS Code team as it appears to be an issue with c# extension.

Original Issue #64625

Detail of original issue is https://github.com/Microsoft/vscode/issues/64625

Debugger Question

Most helpful comment

@gregg-miskelly So, I spun up a Windows 10 VM in Azure (2 vCPUs, 4GB RAM) and pulled down my code and gave it a go. When I hit F5 it takes about 7-10 secs to build. After that I start a timer and monitor how long before a browser launches with my app. It took about 15 secs on the Windows 10 box.

By comparison on my Mac, the build still takes 8-12 secs, however after that to the time the browser launches seems to be taking 80-90 seconds.

All 4 comments

Copying the details from your original issue:

I recently upgraded my asp.net core project to .net core 2.2 and ever since when I click F5 to debug it takes a long time to launch. Like 30 seconds+.

VS Code version: Code 1.29.1 (bc24f98, 2018-11-15T19:06:21.742Z)
OS version: Darwin x64 18.2.0

@dotnetron There isn't much information in your bug to go on. A few questions:

  1. One can divide 'F5' into a few parts. Do you know which part(s) now feel slow? Parts:

    • The time between F5 and the start of the build.

    • Time for the build to run

    • Time between the build and when the debugger first starts and you can start seeing output in the debug console

    • Time for the debugger to launch your ASP.NET application

    • Time for the browser to start and hit the initial page

  2. If you bring up task manager during the slow part(s), what, if anything, is using CPU?

@gregg-miskelly Sorry, here is some additional information:

Once I hit F5, the build process itself appears to run quick. Subsequently I start seeing output in the Debug Console and the Call Stack slowly starts showing multiple threads spinning up. It spins up Threads #1-#5 and then just stalls for a while. Like 10-15 seconds plus. Then continues with threads #6-#12 and then it launches my app in the browser. While this is occurring, I had Activity Monitor open and CPU utilization seems fine < 15%. As far as memory usage goes the highest consumers are mono-sgen64 & kernel_task both at approx. 450MB.

I will also try running the same project on a Windows 10 machine for comparison sake and post the results shortly.

@gregg-miskelly So, I spun up a Windows 10 VM in Azure (2 vCPUs, 4GB RAM) and pulled down my code and gave it a go. When I hit F5 it takes about 7-10 secs to build. After that I start a timer and monitor how long before a browser launches with my app. It took about 15 secs on the Windows 10 box.

By comparison on my Mac, the build still takes 8-12 secs, however after that to the time the browser launches seems to be taking 80-90 seconds.

Was this page helpful?
0 / 5 - 0 ratings