microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
163.6k stars 29.03k forks source link

Very slow UI out of a sudden #215757

Closed crainsaw closed 4 months ago

crainsaw commented 4 months ago

Type: Performance Issue

I just started VSC and the whole UI is super slow out of a sudden. Not sure whether I did an ubuntu update since the last start of VSC. I tried disabling all extensions but it did not help. The process explorer does not show anything interesting.

VS Code version: Code 1.90.1 (611f9bfce64f25108829dd295f54a6894e87339d, 2024-06-11T21:02:43.666Z) OS version: Linux x64 6.5.0-35-generic snap Modes:

System Info |Item|Value| |---|---| |CPUs|AMD Ryzen 5 PRO 4650U with Radeon Graphics (12 x 1356)| |GPU Status|2d_canvas: enabled
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: disabled_software
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: disabled_off| |Load (avg)|3, 3, 3| |Memory (System)|14.84GB (8.27GB free)| |Process Argv|--force-user-env --no-sandbox --use-gl=angle --use-angle=swiftshader --crash-reporter-id ab7fa33e-49bb-4a7d-bebb-acaacb64ac14| |Screen Reader|no| |VM|0%| |DESKTOP_SESSION|ubuntu-xorg| |XDG_CURRENT_DESKTOP|Unity| |XDG_SESSION_DESKTOP|ubuntu-xorg| |XDG_SESSION_TYPE|x11|
Process Info ``` CPU % Mem MB PID Process 0 152 17070 code main 0 46 17072 zygote 0 46 17073 zygote 0 274 17139 window [1] (● browser-communicator.ts - autobrowser - Visual Studio Code) 0 91 19130 window [2] (Issue Reporter) 2 304 17099 gpu-process 0 61 17106 utility-network-service 0 167 17372 extensionHost [1] 0 122 17437 electron-nodejs (tsserver.js ) 0 152 17438 electron-nodejs (tsserver.js ) 0 61 17453 electron-nodejs (typingsInstaller.js typesMap.js ) 0 106 17462 electron-nodejs (server.js ) 0 471 17781 /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/jre/21.0.3-linux-x86_64.tar/bin/java -jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/server/sonarlint-ls.jar -stdio -analyzers /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonargo.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarjava.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarjs.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarphp.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarpython.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarhtml.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarxml.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarcfamily.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonartext.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonariac.jar /home/chris/.vscode/extensions/sonarsource.sonarlint-vscode-4.6.0-linux-x64/analyzers/sonarlintomnisharp.jar 0 410 18065 /home/chris/.nvm/versions/node/v20.10.0/bin/node /home/chris/.sonarlint/.sonarlinttmp_4919557911757372526/bridge-bundle/package/bin/server 42665 127.0.0.1 /home/chris/develop/autobrowser true true false 0 91 17386 shared-process 0 0 19170 /bin/sh -c /usr/bin/ps -ax -o pid=,ppid=,pcpu=,pmem=,command= 0 0 19171 /usr/bin/ps -ax -o pid=,ppid=,pcpu=,pmem=,command= 0 76 17387 fileWatcher [1] 0 76 17420 ptyHost 0 0 17578 /usr/bin/bash --init-file /snap/code/161/usr/share/code/resources/app/out/vs/workbench/contrib/terminal/browser/media/shellIntegration-bash.sh ```
Workspace Info ``` | Window (● browser-communicator.ts - autobrowser - Visual Studio Code) | Folder (autobrowser): 155 files | File types: ts(44) js(18) map(16) json(12) pyc(12) py(9) gitignore(3) | tsbuildinfo(3) html(1) | Conf files: package.json(3) tsconfig.json(3) settings.json(1); ```
Extensions (34) Extension|Author (truncated)|Version ---|---|--- dart-code|Dar|3.90.0 githistory|don|0.6.20 LogFileHighlighter|emi|2.19.0 nunjucks-template|ese|0.5.1 latex-workshop|Jam|9.20.1 intellij-idea-keybindings|k--|1.7.2 ngx-karma-runner|kac|0.0.3 git-graph|mhu|1.30.0 vscode-docker|ms-|1.29.1 debugpy|ms-|2024.6.0 isort|ms-|2023.10.1 python|ms-|2024.8.1 vscode-pylance|ms-|2024.6.1 remote-containers|ms-|0.369.0 debugger-for-edge|msj|1.0.15 angular-console|nrw|18.21.4 java|red|1.31.0 vscode-yaml|red|1.15.0 sonarlint-vscode|Son|4.6.0 svelte-vscode|sve|108.5.0 intellicode-api-usage-examples|Vis|0.2.8 vscodeintellicode|Vis|1.3.1 vscode-boot-dev-pack|vmw|0.2.1 vscode-spring-boot|vmw|1.55.0 vscode-java-debug|vsc|0.57.0 vscode-java-dependency|vsc|0.23.6 vscode-java-pack|vsc|0.27.0 vscode-java-test|vsc|0.41.1 vscode-maven|vsc|0.44.0 vscode-spring-boot-dashboard|vsc|0.14.0 vscode-spring-initializr|vsc|0.11.2 pretty-ts-errors|Yoa|0.5.4 markdown-all-in-one|yzh|3.6.2 vscode-proto3|zxh|0.5.5 (1 theme extensions excluded)
A/B Experiments ``` vsliv368:30146709 vspor879:30202332 vspor708:30202333 vspor363:30204092 vscod805:30301674 binariesv615:30325510 vsaa593cf:30376535 py29gd2263:31024239 c4g48928:30535728 azure-dev_surveyone:30548225 a9j8j154:30646983 962ge761:30959799 pythongtdpath:30769146 welcomedialogc:30910334 pythonidxpt:30866567 pythonnoceb:30805159 asynctok:30898717 pythontestfixt:30902429 pythonregdiag2:30936856 pythonmypyd1:30879173 h48ei257:31000450 pythontbext0:30879054 accentitlementst:30995554 dsvsc016:30899300 dsvsc017:30899301 dsvsc018:30899302 cppperfnew:31000557 dsvsc020:30976470 pythonait:31006305 jchc7451:31067544 chatpanelc:31048052 dsvsc021:30996838 da93g388:31013173 pythoncenvpt:31062603 a69g1124:31058053 dvdeprecation:31068756 pythonprt:31056678 dwnewjupyter:31046869 ```
RomanYarinski commented 4 months ago

Same thing, can anyone advise what to do in such a case?

shelvesdragon commented 4 months ago

This is likely caused by the temporary fix in version 1.90.1 on the snap package that switched the OpenGL backend to software emulation in order to prevent the crashes reported with version 1.90.0 in #212494 . If it is related, your options for now are mentioned in this comment: https://github.com/microsoft/vscode/issues/212494#issuecomment-2168072242 Hope this helps!

RomanYarinski commented 4 months ago

@crainsaw https://github.com/microsoft/vscode/issues/215747#issuecomment-2171271163 For me it worked, the easiest and fastest way is to rollback

crainsaw commented 4 months ago

Awesome. Thank you so much for your quick help @shelvesdragon and @RomanYarinski ! Reverting back to version 159 solved the issue for me as well :)

deepak1556 commented 4 months ago

Merging to https://github.com/microsoft/vscode/issues/212494, please follow the issue for updates.