-
Notifications
You must be signed in to change notification settings - Fork 29.7k
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 startup / crashes - unusable #335
Comments
Duplicate of #160 |
@tominon I already went through that issue, but it's not that much of a duplicate. Everyone is having issues related to php and stuff, while I just try to open up the Editor via the code.exe / desktop icon. |
@Morgy93 can you run code.exe from the program files directory with the "--verbose" flag and attach the output you are seeing? |
@bpasero I hope I didn't get it wrong. This is what I put into the "Target:" property of the icon, but there is no extra output on startup. |
@Morgy93 sry, I meant to say that you try from the windows command prompt. |
@bpasero Alright, here we go:
Here it just takes forever for Code to start .. then the "crash" happens:
And Code is ready for use now it seems .. after like two to three minutes of waiting. For the easiness, full log:
|
@Morgy93 can you try starting code.exe -n (will open an empty workbench without folder) to see if it changes anything? |
@bpasero Well, it still took minutes to show up while using around 30% of my CPU, but at least I didn't get the "crash" message and were able to use it right away. |
@Morgy93 any extensions installed? Otherwise I am totally clueless... |
@bpasero Nope, I just made the automatic update from my previous version to the v0.10.1 which immediately caused this issue. Like I said I already reinstalled it, but nothing changed. I also don't know what else to do. Anything else I could provide to resolve this issue? |
@Morgy93 maybe use process explorer to analyze which process within code.exe actually causes the slowness, we start with more then one process and it would be interesting if one of them is spiking and consuming most startup time. |
Also can you try running "code.exe --disable-gpu" from a command prompt from the installation folder of code to see if it makes any difference? |
@bpasero Sadly --disable-gpu doesn't help. I'll have a look at this process explorer thing in the meanwhile.. |
@Morgy93 yes please, there are processes within the one that is selected in your screen shot that could cause that one to take so long. |
@bpasero I took this one: https://technet.microsoft.com/de-de/sysinternals/processexplorer.aspx
Don't really know what's important for you within this tool, so please be a bit more precise. :) |
@Morgy93 I am using process explorer and it allows to group processes hierarchically and then I can expand the renderer process of code.exe to see spawned children within: Can you use the same tool and then see if any of the processes within the renderer is busy or actually really the renderer? |
@bpasero Actually that's just what I did, but there is no other process before the editor is fully loaded. I am starting VS Code and wait for the UI to load a bit (nothing changed till here): Then suddenly I get the no response error message and still nothing changed: Just after waiting for a little longer, the editor is fully loaded and two new processes spawned within the one which was consuming the cpu power. That's pretty much everything that happens. |
Just to let you know: |
@Morgy93 good insights, thanks. Especially good to know that 0.9.2 loads fast for you. There are two things that changed for the 0.10.x release: Lots of code changes on our end but also an update to the cross platform framework (Electron). First of all we need to understand if this is caused by code changes or by Electron. The easiest to start with is to set you up to run Code from its sources so that we can tweak changes and rapidly see if it helps. Can you follow https://github.com/Microsoft/vscode/wiki/How-to-Contribute#build-and-run-from-source and when you launch code see if you see the same issue of slow startup? |
@Morgy93 another thought I had was if - once VS Code is up and running - you could see if reloading the application is also slow. For that you can just trigger View | Command Palette | Reload Window. If that action turns out to be as slow, we have a chance to run a profiler to see where the time is spent. For that - before reloading - run Help | Toggle Developer Tools, click Profiles, then press the Start button and run the reload action. After that, press the Stop button. You should get a list of function calls and their timings. You can export this report from the little "Save" button next to "Profile 1" on the left. |
By the way I just updated to version 0.10.2 but the issue remains. But from now on I will most likely rely on that version, if no other instructions are given. @bpasero I'll try the build and run from source at the weekend. (If needed) |
@Morgy93 thanks a lot for the profile, this helped identify the issue and in fact many more users are hit. This likely qualifies for an update that we will push out to all users but we need some verification first. So I have a couple of asks for you: 1.) can you download the following build of VS Code (standalone zip, no installer) and open Code.exe to see if performance is better. I uploaded the zip to my onedrive: http://1drv.ms/1NQvCOu 2.) if performance is better: close the instance and open process.env['VSCODE_SHARED_IPC_HOOK'] = configuration.sharedIPCHandle;
console.log('URL length: ' + window.document.URL.length);
console.log(JSON.stringify(configuration, null, '\t')); Then save the file and run Code again from the zip and hit Help | Toggle Developer Tools. You should then see potentially lots of output from the log statements. I would need the entire log, since it may contain user data it should probably be not attached to this issue but you can send it via mail ([email protected]). |
@bpasero Performance is good again - log sent via mail. |
To people hitting this issue: We might not be able to release a new version until next week. But there is a workaround: If you can start Code eventually:
If you cannot start Code:
Sorry for the trouble ❤️ |
Hi, I can still reproduce the issue in version 0.10.3. |
@slayerxj that seems like a different issue that should get filed, please do that! |
@bpasero Sorry, I thought they were same because the first time I met this issue, that JSON file was supposed to be shown at startup. So I did experience slow startup / crashes :) And now after reading the discussions I realized they're different. |
Hello,
since the release of VS Code v0.10.1 I cannot use it anymore - yes, I already tried to reinstall it.
It takes minutes to start and all I'm getting is the following:
I am using Windows 10 Pro on my Microsoft Surface Pro 3.
The text was updated successfully, but these errors were encountered: