Problem
Every time I use Eclipse on my personal laptop, it constantly freezes (e.i. the process stops responding) for seemingly everything I do except for regular typing (without content assist). Any other action will cause it to freeze 7 out of 10 times, for roughly 10-20 seconds, mainly:
Any automatic proposal menus (e.g. when you type . after a variable name and a list of options appears) or manual ones (e.i. Ctrl + Space).
Any auto-import (Ctrl + Shift + O) or auto-format (Ctrl + Shift + Space)
Any context menu
Viewing JavaDoc comments
Any interaction with the project/package explorer
Any load/save operations
Any run/debug operation
Exiting the program
Every once in a while, it will not freeze, but the content assist will take a very long time to give me proposals, or the JavaDoc info will take a long time to load.
I use Eclipse on my work laptop and I do not experience any of these issues.
Things I've tried
Increase the RAM
Monitor the heap (I did not observe any correlation between heap size and freezing)
Move my workspace from my external drive to my internal drive
Run eclipse -clean
Perform a clean installation:
Delete the installation directory (%userprofile%\eclipse\java-XXXX-XX\eclipse)
Delete the .p2 directory (%userprofile%\.p2)
Download and install the latest version of Eclipse
Create a new workspace (and test it by creating a new project instead of importing old ones)
Disable the "Override high DPI scaling behavior" option (see this)
Environment
I am sure that someone is going to ask if I have a computer capable of running Eclipse. These are my laptop's specifications:
GPU : NVIDIA GeForce RTX 3070 Laptop GPU
CPU : AMD Ryzen 9 5900HS with Radeon Graphics
Memory: 16 GB RAM (15.41 GB RAM usable)
It's a ROG Zephyrus G15 (Model: GA503QR_GA503QR). I previously owned a G14 and had the same issue.
Observations
I notice that often when this happens explorer.exe also stops responding. I can still use other applications like Google Chrome, but I have to wait for Eclipse to respond before Windows Explorer starts responding.
Question
What are the potential causes of the described behaviors, and remedies thereof?
Related
Since recently, VSCode started to eat 90% CPU per window even in idle mode. I suspect, some of plugins could be responsible for it.
Is there a way to somehow profile VSCode, so I could find the offending plugin?
I had a clean installation on another machine with minimal amount of plugins, and the problem is not there.
Check if you have settings-sync extension. Its known for high CPU utilization. Disable it, restart VSCode, kill Code helper (all) and start again. it will use again 100% for few seconds and it will drop to normal 8-10%
https://marketplace.visualstudio.com/items?itemName=Shan.code-settings-sync&ssr=false#review-details
On just one of my two Linux systems, Visual Studio Code always starts in a maximized window. It doesn't do it on the other one. Both systems are Pop!_OS 20.10, upgraded along the way from each Pop!_OS release from 18.04. VSCode is 1.51.1, and has been doing this since I started using it about 1.36 or so. I'm using the default Gnome Shell on each system. On the system where it doesn't start maximized, it remembers its previous size and placement. If I double-click on the window header on the failing system, it returns to its prior placement and size, but if I close it in that state, when I reopen it it's maximized again.
I'm guessing there's a settings file or something that's set to force it to be maximized, but I didn't explicitly set anything like that, and I wasn't able to find anything when searching that would have that effect.
The failing system is one I built up with a Ryzen 9 3900X, 64 GB RAM, 1 TB M.2 PCIe 4 SSD, and an RTX 2060. The working system is a System76 Oryx Pro v4 with 64 GB and an 8th gen Core i7. VSCode has done this on the failing system ever since I was running it on a dual-hex Mac Pro, and on a 1080p monitor; I'm now using a 3840x2160 monitor - but that's what the Oryx Pro has on it, too.
What am I missing?
Following works on ubuntu 20.10. Position VSCode window where you would like it to open next time. Then, hit <Ctrl><CloseXButton>
This will close your current session. Next time you open this project via code ., you should get VSCode to open in that last state you <Ctrl>-closed it in.
I don't know where this status is stored in the settings file.
I'm trying to move from Netbeans IDE to VS Code. I have a fresh instalation (newest version 1.29.0) without any extensions on Windows 8.1.
When I try to search a file by CTRL+E immedietly Antimalware Service Executable process (Windows Defender) spikes CPU usage for a second and my CPU fan goes nuts. Even before I type to search anything. It's very annoying.
I have excluded code.exe from Windows Defender and the entire folder within I'm trying to search. It helped a little - 98% CPU usage lowered to like 40%. Still not the result I was hoping for.
CPU is Intel Core i7-2600.
What am I doing wrong?
I believe that this is a bug in VS code. A couple of issues have been raised about it on GitHub in the last few days:
https://github.com/Microsoft/vscode/issues/63070
I've run into a very strange issue with my Eclipse installation. In fact, I've tried installing three different instances and the problem persists, so something must be seriously messed up with my machine.
The best way I can describe it is this. When I open a file in Eclipse (regardless of file type - I've tried .java, .js, .xml, etc.), the file appears to open and the filename is shown at the top of the editor panel as normal. But the file itself appears to be empty or blank.
Upon clicking in the editor window to attempt typing, it gets even more strange. The normal blinking black cursor is the full height of the window. Typing doesn't actually do anything. No text shows up, but it appears as if the file is being edited because the (*) symbol displays next to the filename as if it hasn't been saved since it was last changed.
I would provide a screenshot, but it's simply a blank window with a giant typing cursor. My current environment information is below, but like I said, I've had the issue with three different versions of Eclipse. Also, it's peculiar that this started happening seemingly randomly. Everything was fine but my machine was overdue for a restart. After restarting I opened up my workspace and this just sort of happened. I haven't been able to find any suggestions that aren't "reinstall" or "run Eclipse with the -clean tag" (neither of which worked).
Windows 7 Enterprise
Service Pack 1
Processor: Intel(R) Xeon(R) CPU E5-2695 v2 # 2.40GHz
RAM: 8GB
System type: 64-bit
Eclipse Mars 4.5.2
I use Windows 8 x64 and last eclipse: eclipse-java-juno-SR1.
At second monitor I move console and some android tools (logcat, devices). All worked ok. But I do not need see second monitor all time. And I switch off this monitor (by win + P). On next start I see windows from second monitor at primary monitor. Close. Open. And now see default perspective. Own perspectives, that I saved disappeared. And this repeat all time, if I disable second monitor.
Before I use eclipse-java-indigo-SR1 and do not have any problem.
Don't find solution. Now back to indigo (3.7.1).