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

VSCODE is slow even with no extension while scrolling to compare code #106939

Closed
Perh0rd opened this issue Sep 17, 2020 · 15 comments
Closed

VSCODE is slow even with no extension while scrolling to compare code #106939

Perh0rd opened this issue Sep 17, 2020 · 15 comments
Assignees
Labels
info-needed Issue requires more information from poster perf windows VS Code on Windows issues

Comments

@Perh0rd
Copy link

Perh0rd commented Sep 17, 2020

We have written the needed data into yo
Issue Type: Performance Issue

Using VSCODE insider, running without any extension, compare code , and scrolling is very slow.

We are on WVD environnement.

This is working well on physical computer.

WVD environnement is stable, user can view 4K vidéo on youtube and use photoshop, they also use VSCODE online (codespace), it works smoothly, it's really on the desktop version of VSCODE.

VS Code version: Code 1.49.0 (e790b93, 2020-09-10T13:22:08.892Z)
OS version: Windows_NT x64 10.0.18363
Remote OS version: Linux x64 4.15.0-106-generic

System Info
Item Value
CPUs Intel(R) Xeon(R) Platinum 8168 CPU @ 2.70GHz (16 x 2694)
GPU Status 2d_canvas: unavailable_software
flash_3d: disabled_software
flash_stage3d: disabled_software
flash_stage3d_baseline: disabled_software
gpu_compositing: disabled_software
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
opengl: disabled_off
protected_video_decode: disabled_off
rasterization: disabled_software
skia_renderer: disabled_off_ok
video_decode: disabled_software
vulkan: disabled_off
webgl: unavailable_software
webgl2: unavailable_software
Load (avg) undefined
Memory (System) 32.00GB (25.69GB free)
Process Argv --crash-reporter-id c2ba6ccf-ae4c-45cd-aac6-3c82274e9539
Screen Reader no
VM 0%
Item Value
Remote SSH: paul.xpedigo.dev
OS Linux x64 4.15.0-106-generic
CPUs Intel(R) Xeon(R) CPU E5-2650 v4 @ 2.20GHz (6 x 2199)
Memory (System) 15.66GB (2.38GB free)
VM 0%
Process Info
CPU %	Mem MB	   PID	Process
    0	    89	 13344	code main
    0	    85	  9372	   gpu-process
    0	   278	 11876	   window (app/Repositories/Helpers/Shipments/ShipmentRepositoryHelper.php - xpedigo-api [SSH: paul.xpedigo.dev] - Visual Studio Code)
    0	     4	  4976	     C:\windows\System32\cmd.exe /c (type "C:\Users\local_paul\Temp\vscode-linux-multi-line-command-paul.xpedigo.dev-497457804.sh" | ssh -T -D 52214 [email protected] bash) & exit /b 0
    0	    11	 12036	       ssh  -T -D 52214 [email protected] bash
    0	     6	 10912	     console-window-host (Windows internal process)
    0	    69	 11520	     extensionHost
    0	    15	 12276	   crashpad-handler
    0	    27	 13076	   utility
    0	    68	 15888	   window (Issue Reporter)
    0	    70	 15956	   shared-process

Remote: SSH: paul.xpedigo.dev
CPU %	Mem MB	   PID	Process
    5	     0	 23491	remote agent
    0	     0	 23859	   extensionHost
    0	     0	 23913	     CodeStream
    0	     0	 24069	     /home/xpedigo/.vscode-server/bin/e790b931385d72cf5669fcefc51cdf65990efa5d/node /home/xpedigo/.vscode-server/extensions/bmewburn.vscode-intelephense-client-1.5.4/node_modules/intelephense/lib/intelephense.js --node-ipc --clientProcessId=23859
    0	     0	 24159	     /bin/bash
    0	     0	 23870	   watcherService
    0	     0	 24235	   /bin/sh -c /bin/ps -ax -o pid=,ppid=,pcpu=,pmem=,command=
    0	     0	 24236	     /bin/ps -ax -o pid=,ppid=,pcpu=,pmem=,command=
Workspace Info

|  Remote: SSH: paul.xpedigo.dev|    Folder (xpedigo-api): 14505 files|      File types: php(9244) txt(698) json(396) md(283) css(134) xml(90)
|                  yml(76) stub(58) rst(55) gitignore(46)
|      Conf files: makefile(6) package.json(3) launch.json(1) settings.json(1)
|                  tsconfig.json(1) webpack.config.js(1)
|      Launch Configs: php;
Extensions (24)
Extension Author (truncated) Version
project-manager ale 11.3.0
auto-close-tag for 0.5.8
dotenv mik 1.0.1
vscode-apache mrm 1.2.0
remote-containers ms- 0.140.1
remote-ssh ms- 0.55.0
remote-ssh-edit ms- 0.55.0
remote-wsl ms- 0.44.5
vscode-remote-extensionpack ms- 0.20.0
code-settings-sync Sha 3.4.3
Bookmarks ale 11.3.1
vscode-intelephense-client bme 1.5.4
codestream Cod 8.3.7
xml Dot 2.5.1
gitlens eam 10.2.2
vscode-html-css ecm 0.2.3
php-debug fel 1.13.0
vscode-pull-request-github Git 0.20.0
beautify Hoo 1.5.0
git-graph mhu 1.26.0
vetur oct 0.27.3
vscode-zipexplorer sle 0.3.1
html-preview-vscode tht 0.2.5
vscodeintellicode Vis 1.2.10

(1 theme extensions excluded)

ur clipboard because it was too large to send. Please paste.
@olegKusov
Copy link

Web based code editors has some limits in terms of performance. See my issue #106962

@alexdima
Copy link
Member

@Perh0rd What is the exact setup? Remote Desktop to another Windows machine which runs VS Code Desktop? Then scrolling while using Remote Desktop is slow?

@alexdima alexdima added the info-needed Issue requires more information from poster label Sep 18, 2020
@Perh0rd
Copy link
Author

Perh0rd commented Sep 18, 2020

@alexdima Our dev team uses WVD with remote Azure. The problem is on every WVD. Once connected the scrolling is slow. For example if we use code comparaison with git, we have a delay of few second by clicking the green/red zone on the right (https://paul-xpedigo.tinytake.com/tt/NDY0Mzk2N18xNDcxNDcyNw) , it just take time to scroll up or down. Same When we are scrolling into the code itself. We can scroll we the mouse wheel, but we won't see the the code scrolling, it will just jump directly to the number of mouse wheels gesture we have done, creating a feeling of lag.

We do not notice such a problem with codespace, using vs code insider with no activated extension won't fix the problem also.

@alexdima
Copy link
Member

alexdima commented Sep 18, 2020

@Perh0rd So If I understand correctly, you are running VS Code Desktop inside a Windows VM that runs on Azure and are using Remote Desktop to connect to it. If that is the case, I would expect that scrolling is driven by the latency to the VM.

  • What is the ping time to the remote machine?

  • What about other software on the remote machine? How smooth is scrolling by dragging the scrollbar slider in a MS Word document? Can you by any chance install a full screen game in the remote machine? What is the smoothness experience? [I am trying to determine if this is a problem limited to VS Code or all software on the remote machine]

  • What about opening https://vscode-web-test-playground.azurewebsites.net/ in Edge or Chrome in the remote machine? How smooth is scrolling by dragging the scrollbar slider when using VS Code Web remotely?

  • Do these VMs have GPUs? Could you try launching code --disable-gpu in the remote machine?

Could you perhaps attach a gif to clarify the extent of the slowness?

@Perh0rd
Copy link
Author

Perh0rd commented Sep 18, 2020

Hi,

Every other software are smooth, even watching 4k videos on Youtube.

Here are more informations, I just run those tests on the WVD.

This is how CodeSpace behaves using chrome to compare code :

https://ttprivatenew.s3.amazonaws.com/pulse/paul-xpedigo/attachments/14714803/TinyTake18-09-2020-05-46-29.mp4

As you can see this is very smooth and once I click on the green/red block on the right it scroll instantly, and scrolling in the document is pretty fast too.

In the others side if you take a look at this :

https://ttprivatenew.s3.amazonaws.com/pulse/paul-xpedigo/attachments/14714821/TinyTake18-09-2020-05-49-49.mp4

I compare the exact same code with VSCODE installed on the machine (insider version, but its the same with stable version , no extension installed), and it's laggy....

This is a 4k video on the WVD : https://ttprivatenew.s3.amazonaws.com/pulse/paul-xpedigo/attachments/14714823/TinyTake18-09-2020-05-51-29.mp4

Using Chrome for https://vscode-web-test-playground.azurewebsites.net/ is very while scrolling.

VMs have no GPU, but I tested in a Pool of WVD with Nvidia GPU, and the problem is the same...

Try with code --disable-gpu , does not change anything.

Photoshop is smooth also for information.

This is very strange

Thank you a lot for your help.

@Perh0rd
Copy link
Author

Perh0rd commented Sep 18, 2020

And for sure, trying on my local computer and this is working well, but well, our setup is remote...

@Perh0rd
Copy link
Author

Perh0rd commented Sep 18, 2020

It seems to be global with WVD on Azure, if you can have a chance to test on your own with the same Windows Version we use (it's the standard version available on Azure library), you will be able to reproduce this behavior.

@alexdima
Copy link
Member

Thanks for the extra info. Here's some more info from my side:

When using Codespaces, the UI of VS Code runs natively on the local machine. Only the extension host which spawns language servers or terminals or file watchers, etc runs on the remote machine, where the files are. So scrolling with a local installed VS Code connected via Codespaces should have the exact same speed as scrolling with a local installed VS Code browsing a local file, since scrolling itself never leaves your local machine.

I saw the delay, it looks like there is a very large lag between you doing an input (like a mouse down) and seeing the reaction. At this point I have no idea why that would be. But please be aware that the 4K video demonstrates that there is high throughput, it does not demonstrate low latency. So comparing with youtube playback is not entirely comparing apples to apples.

Using Chrome for https://vscode-web-test-playground.azurewebsites.net/ is very while scrolling.

You missed a word here. What did you mean? So Chrome is not acting in the same way? If you open Chrome on the remote machine and open a website, is scrolling smooth?

@deepak1556 Do you have any troubleshooting tricks up your sleeve to try to find out what is causing the lag?

@Perh0rd
Copy link
Author

Perh0rd commented Sep 19, 2020

@alexdima Missing word was ''very smooth''. There is no low latency I can assure you that all the others softwares run smoothly, and vscode in codespace or in chrome does not rum slowly, the scroll is always smooth using CodeSpace. As far as I remembered, I did not notice such a problem, in June or July.

@deepak1556
Copy link
Collaborator

Pretty sure this might be a duplicate of #106456, just to confirm can you share the wpr profile following

  • Download and install latest insiders https://code.visualstudio.com/insiders/
  • Open Windows Performance Recorder from windows start menu
  • Ensure CPU usage is checked under Resource Analysis
  • Ensure Performance Scenario is General and Detail Level is verbose
  • Click record
  • Open the insiders and perform some scrolling that shows the slowdown
  • Stop recording and save the profile
  • Send the profile to [email protected]

And we also need a chrome tracing profile which can be obtained by

  • Create trace.json somewhere on your disk with the following content:
{
 "result_file": "C:\Users\<name>\AppData\Local\chrometrace.log",
 "trace_config": {
 "record_mode": "record-until-full",
 "included_categories": [
     "blink",
     "benchmark",
     "gpu",
     "cc",
     "toplevel",
     "viz",
     "v8",
     "disabled-by-default-v8.ic_stats"
 ],
 "excluded_categories": ["*"]
 }
}
  • Start code-insiders --trace-config-file="C:\Program Files\Microsoft VS Code\trace.json"
  • Use the editor as normal and ensure the slowdown is seen
  • Quit the editor
  • Attach the generated chrometrace.log

@deepak1556 deepak1556 added perf windows VS Code on Windows issues labels Sep 21, 2020
@Perh0rd
Copy link
Author

Perh0rd commented Sep 21, 2020

Hi @deepak1556 thank you for your help.

I have just sent the email to you.

@deepak1556
Copy link
Collaborator

Ack, thanks!

@Perh0rd
Copy link
Author

Perh0rd commented Sep 21, 2020

@deepak1556 @alexdima I also confirm that regarding ticket comment #106456 (comment) , the slowness does not exist on previous version of VSCODE 1.48.2

Screencast here : https://ttprivatenew.s3.amazonaws.com/pulse/paul-xpedigo/attachments/14736024/TinyTake21-09-2020-04-22-45.mp4

@Perh0rd
Copy link
Author

Perh0rd commented Sep 21, 2020

If there is any workaround , else than using v1.48, I'll take it if you know one, if not, well I guess we should wait to next update ? Thank you for your feedback.

@deepak1556
Copy link
Collaborator

@Perh0rd lets continue the conversation in #107016 since it has more audience, will be easier for me to track.

@github-actions github-actions bot locked and limited conversation to collaborators Dec 4, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
info-needed Issue requires more information from poster perf windows VS Code on Windows issues
Projects
None yet
Development

No branches or pull requests

4 participants