Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slow Debugging on VS Code on Mac #2736

Open
dotnetron opened this issue Dec 7, 2018 · 4 comments
Open

Slow Debugging on VS Code on Mac #2736

dotnetron opened this issue Dec 7, 2018 · 4 comments

Comments

@dotnetron
Copy link

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 microsoft/vscode#64625

@gregg-miskelly
Copy link
Contributor

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

@gregg-miskelly
Copy link
Contributor

gregg-miskelly commented Dec 7, 2018

@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
  1. If you bring up task manager during the slow part(s), what, if anything, is using CPU?

@dotnetron
Copy link
Author

@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.

@dotnetron
Copy link
Author

@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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants