vscode
vscode copied to clipboard
Mcafee slowing down the application
Update from @isidorn: McAfee team acknowledged this issue and are working on a fix. More details in this article with a workaround to exclude VS Code from being scanned: https://www.mcafee.com/support/?locale=en-US&articleId=TS103439&page=shell&shell=article-view
Type: Performance Issue
a week ago this issue started to happen. I don't know why the vs does't open fast like before. my pc performance is perfect and I have a very good specifications. corei7 16GB RAM 4G vega nevidia
and everytime I get a small window which has three options reopen, close, and wait program
VS Code version: Code 1.77.0 (7f329fe6c66b0f86ae1574c2911b681ad5a45d63, 2023-03-29T10:02:16.981Z) OS version: Windows_NT x64 10.0.22621 Modes: Sandboxed: No
System Info
Item | Value |
---|---|
CPUs | Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz (12 x 2208) |
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_renderer: enabled_on video_decode: enabled video_encode: enabled vulkan: disabled_off webgl: enabled webgl2: enabled webgpu: disabled_off |
Load (avg) | undefined |
Memory (System) | 15.81GB (7.78GB free) |
Process Argv | --crash-reporter-id 8fd832f6-9de4-416f-89ae-88b2c3b75006 |
Screen Reader | no |
VM | 0% |
Process Info
CPU % Mem MB PID Process
0 99 43800 code main
0 28 9816 crashpad-handler
0 81 27452 fileWatcher [1]
0 227 43324 extensionHost [1]
0 114 17044 electron-nodejs ("C:\Users\obada\AppData\Local\Programs\Microsoft VS Code\Code.exe" --ms-enable-electron-run-as-node --max-old-space-size=3072 "c:\Users\obada\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js" --serverMode partialSemantic --useInferredProjectPerProjectRoot --disableAutomaticTypingAcquisition --cancellationPipeName C:\Users\obada\AppData\Local\Temp\vscode-typescript\439eb021dc574ea9b4a7\tscancellation-97ea4191a10871dac99e.tmp* --locale en --noGetErrOnBackgroundUpdate --validateDefaultNpmLocation --useNodeIpc)
0 81 37036 electron-nodejs ("C:\Users\obada\AppData\Local\Programs\Microsoft VS Code\Code.exe" --ms-enable-electron-run-as-node "c:\Users\obada\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\json-language-features\server\dist\node\jsonServerMain" --node-ipc --clientProcessId=43324)
0 168 40276 electron-nodejs ("C:\Users\obada\AppData\Local\Programs\Microsoft VS Code\Code.exe" --ms-enable-electron-run-as-node c:\Users\obada\.vscode\extensions\streetsidesoftware.code-spell-checker-2.20.3\packages\_server\dist\main.js --node-ipc --clientProcessId=43324)
0 79 49752 electron-nodejs ("C:\Users\obada\AppData\Local\Programs\Microsoft VS Code\Code.exe" --ms-enable-electron-run-as-node c:\Users\obada\.vscode\extensions\kisstkondoros.vscode-gutter-preview-0.30.0\dist\server.js --node-ipc --clientProcessId=43324)
0 124 50104 electron-nodejs ("C:\Users\obada\AppData\Local\Programs\Microsoft VS Code\Code.exe" --ms-enable-electron-run-as-node --max-old-space-size=3072 "c:\Users\obada\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js" --useInferredProjectPerProjectRoot --enableTelemetry --cancellationPipeName C:\Users\obada\AppData\Local\Temp\vscode-typescript\439eb021dc574ea9b4a7\tscancellation-c1b3d0dc3cb7c5eb634d.tmp* --locale en --noGetErrOnBackgroundUpdate --validateDefaultNpmLocation --useNodeIpc)
0 83 13592 electron-nodejs ("C:\Users\obada\AppData\Local\Programs\Microsoft VS Code\Code.exe" --ms-enable-electron-run-as-node "c:/Users/obada/AppData/Local/Programs/Microsoft VS Code/resources/app/extensions/node_modules/typescript/lib/typingsInstaller.js" --globalTypingsCacheLocation C:/Users/obada/AppData/Local/Microsoft/TypeScript/5.0 --enableTelemetry --typesMapLocation "c:/Users/obada/AppData/Local/Programs/Microsoft VS Code/resources/app/extensions/node_modules/typescript/lib/typesMap.json" --validateDefaultNpmLocation)
0 77 51608 electron-nodejs ("C:\Users\obada\AppData\Local\Programs\Microsoft VS Code\Code.exe" --ms-enable-electron-run-as-node c:\Users\obada\.vscode\extensions\formulahendry.auto-rename-tag-0.1.10\packages\server\dist\serverMain.js --node-ipc --clientProcessId=43324)
0 88 44932 window [5] (Issue Reporter)
0 149 49156 gpu-process
0 198 49644 window [1] (getNumber.js - data-structure-algorethmes-udemy - Visual Studio Code)
0 48 49652 utility-network-service
0 104 51852 shared-process
0 79 11556 ptyHost
Workspace Info
| Window (getNumber.js - data-structure-algorethmes-udemy - Visual Studio Code)
| Folder (data-structure-algorethmes-udemy): 48 files
| File types: js(35)
| Conf files:;
Extensions (23)
Extension | Author (truncated) | Version |
---|---|---|
vscode-color-picker | Ant | 0.0.4 |
github-markdown-preview | bie | 0.3.0 |
markdown-checkbox | bie | 0.4.0 |
markdown-emoji | bie | 0.3.0 |
markdown-footnotes | bie | 0.1.1 |
markdown-mermaid | bie | 1.18.0 |
markdown-preview-github-styles | bie | 1.0.1 |
markdown-yaml-preamble | bie | 0.1.0 |
path-intellisense | chr | 2.8.4 |
vscode-markdownlint | Dav | 0.49.0 |
gitlens | eam | 13.4.0 |
vscode-html-css | ecm | 1.13.1 |
prettier-vscode | esb | 9.10.4 |
auto-rename-tag | for | 0.1.10 |
code-runner | for | 0.12.0 |
vscode-pull-request-github | Git | 0.62.0 |
vscode-gutter-preview | kis | 0.30.0 |
emoji-icons | mig | 1.5.2 |
colorful-comments | Par | 1.0.0 |
material-icon-theme | PKi | 4.25.0 |
LiveServer | rit | 5.7.9 |
code-spell-checker | str | 2.20.3 |
material-theme | zhu | 3.15.8 |
A/B Experiments
vsliv368cf:30146710
vsreu685:30147344
python383:30185418
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
vserr242cf:30382550
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vshan820:30294714
vstes263cf:30335440
pythondataviewer:30285071
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
cmake_vspar411:30581797
vsaa593cf:30376535
pythonvs932:30410667
cppdebug:30492333
vscaat:30438848
vsclangdc:30486549
c4g48928:30535728
dsvsc012cf:30540253
pynewext54:30695312
azure-dev_surveyone:30548225
nodejswelcome1cf:30587006
282f8724:30602487
pyind779:30671433
f6dab269:30613381
pythonsymbol12:30671437
2i9eh265:30646982
vsccsb:30677849
vscodedisable:30660115
pythonb192:30669360
functionswalk:30687959
pythonms35:30701012
/needsMoreInfo
Please use this guide to provide more information: https://github.com/Microsoft/vscode/wiki/Performance-Issues. Thanks.
Thanks for creating this issue! We figured it's missing some basic information or in some other way doesn't follow our issue reporting guidelines. Please take the time to review these and update the issue.
Happy Coding!
of course. Okay I tried multiple things, I disabled all extensions, uninstalled the newest extensions and uninstalled vs code and reinstalled it again but still the same so I will follow the steps of Visual Studio Code starts up slowly
Two files of the startup CPU profile
prof-3Sj321Ml.main.cpuprofile.txt
prof-3Sj321Ml.renderer.cpuprofile.txt
System Info
- Code: 1.77.0 (7f329fe6c66b0f86ae1574c2911b681ad5a45d63)
- OS: win32(10.0.22621)
- CPUs: Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz(12 x 2208)
- Memory(System): 15.81 GB(8.84GB free)
- Memory(Process): 191.26 MB working set(128.03MB private, 2.82MB shared)
- VM(likelihood): 0%
- Initial Startup: true
- Has 0 other windows
- Screen Reader Active: false
- Empty Workspace: false
Performance Marks
What | Duration | Process | Info |
---|---|---|---|
start => app.isReady | 7018 | [main] | initial startup: true |
nls:start => nls:end | 0 | [main] | initial startup: true |
require(main.bundle.js) | 73 | [main] | initial startup: true |
start crash reporter | 6966 | [main] | initial startup: true |
serve main IPC handle | 2 | [main] | initial startup: true |
create window | 24 | [main] | initial startup: true, state: 0ms, widget: 12ms, show: 11ms |
app.isReady => window.loadUrl() | 135 | [main] | initial startup: true |
window.loadUrl() => begin to require(workbench.desktop.main.js) | 20696 | [main->renderer] | NewWindow |
require(workbench.desktop.main.js) | 286 | [renderer] | cached data: YES, node_modules took 0ms |
wait for window config | 0 | [renderer] | - |
init storage (global & workspace) | 14 | [renderer] | - |
init workspace service | 26 | [renderer] | - |
register extensions & spawn extension host | 190 | [renderer] | - |
restore viewlet | 11 | [renderer] | workbench.view.explorer |
restore panel | 0 | [renderer] | - |
restore & resolve visible editors | 70 | [renderer] | 1: workbench.editors.gettingStartedInput |
overall workbench load | 375 | [renderer] | - |
workbench ready | 28545 | [main->renderer] | - |
renderer ready | 704 | [renderer] | - |
shared process connection ready | 0 | [renderer->sharedprocess] | - |
extensions registered | 28787 | [renderer] | - |
Every time I start vs code
this message in the screenshot is showing every time I start vsCode (of course after taking sometime to see vs code itself).
@deepak1556 Another case of slow app ready events
Do you have McAfee antivirus installed, we had reports https://github.com/microsoft/vscode/issues/178733 , https://github.com/microsoft/vscode/issues/177570 with the AV slowing down startup with recent update.
@deepak1556 Thanks it works fine now after putting the code.exe
file in the excluded files
list in McAfee.
Thanks for confirming, I will keep this open to track duplicates.
Just wanted to mention here that adding code.exe to be excluded from McAfee corrected my slow start up times as well.
OK, so I'd venture and dare to say: don't use McAfee. There are better AV solutions out there. I know it's not what some people want to hear, though :-)
Can users impacted provide the trace following the steps below to help us understand why the process launches are slow on your device, thanks!
- Open
Windows Performance Recorder
from system start menu - Have the following settings
- Start the recorder
- Open the application
- Once the editor has completely loaded, stop the recorder and save the profile
- Send the profile to [email protected] instead of attaching to this issue, since it will contain sensitive information.
Slow and unresponsive startup is temporarily solved by excluding the code.exe file from mcafee realtime scanning. This has to be done daily though. I just bought mcafee for another year, what to do?
I just bought mcafee for another year, what to do?
Honestly, I would uninstall it and install Avast Free from the offline installer https://forum.avast.com/index.php?topic=323618.0 But YMMV.
@Johng117 this didn't happened with me. Once I excluded the code.exe file I didn't need to do it again. but I remember that I only need to do that when I update vscode then I need to exclude it again. it's not a big deal for me and I am okay with it.
@Johng117 this didn't happened with me. Once I excluded the code.exe file I didn't need to do it again. but I remember that I only need to do that when I update vscode then I need to exclude it again. it's not a big deal for me and I am okay with it.
Yeah, its not that big a deal. VsCode seems to update daily for me though. I might try and see if I can limit the uploads to once a week?
I haven't received any profiles yet, asked in https://github.com/microsoft/vscode/issues/178962#issuecomment-1543836137, it would be great if the affected users can provide one to help us move this issue forward, thanks!
Hello Everyone,
Thanks for the guidance. I have included code.exe
file in the excluded files
list in McAfee but i feel its not a good practice to do so. The purpose of antivirus is to scan the system for viruses etc.
Is there is a more feasible solution for this ?
I tested with extensions settings and starting up VS Code via code --disable-extensions
is actually lot more faster even without including code.exe
file in the excluded files
list in McAfee. The above command temporarily disables extensions and clicking on reload and enable extensions
as shown in screenshot below is loading all extensions as before.
Please see the screenshot below:
I also tried with Help: Start Extension Bisect
from Command Palette and opened this issue cmake related to cmake plugin
Thanks everyone
@deepak1556 Thanks it works fine now after putting the
code.exe
file in theexcluded files
list in McAfee.
Thanks it worked.
Thanks for the guidance. I have included
code.exe
file in theexcluded files
list in McAfee but i feel its not a good practice to do so. The purpose of antivirus is to scan the system for viruses etc.Is there is a more feasible solution for this ?
@venkatrahul-software-development please see https://github.com/microsoft/vscode/issues/178962#issuecomment-1547360886
Indeed anyone with the problem could help by responding to that call for information by @deepak1556
Are there still people using that so-called antivirus? https://www.reddit.com/r/pcmasterrace/comments/umwr1i/mcafee_giving_chrome_a_run_for_its_money/
@deepak1556 Thanks it works fine now after putting the
code.exe
file in theexcluded files
list in McAfee.
can you tell me where can i find the 'code.exe' file???
@elvislobo472 of course you can find it here I guess
C:\Users\your_user_name\AppData\Local\Programs\Microsoft VS Code
@elvislobo472 of course you can find it here I guess
C:\Users\your_user_name\AppData\Local\Programs\Microsoft VS Code
Thank you so much, the issue is resolved. Turns out it was McAfee that was slowing the application.
Hello I'm facing the same issue of extremely high loading time. I don't use McAfee. Does this issue also reproduce for Windows Defender.
Same issue here. It was really painful to start vs code. And I'm working on a Next.js project, and it was taking ages to refresh it on the page after saving a file. I tried different things to solve this problem here, but nothing worked (I have McAfee installed on my machine, but didn't realize this could be the problem) ... but then, two or three days ago, after an vs code update was launched (not sure) the problem was gone. It's staring real fast and everything works fine now! Thanks a lot! 😁👍
TREND security agent also has this problem
Disable TREND security agent can solve
TREND security agent also has this problem
Disable TREND security agent can solve
same there
Thanks @Neil-140301 for providing the ETW traces, we are now able to move the issue forward with Mcafee. Can any of the affected users check if launching the application using the following flags code.cmd --no-sandbox --disable-gpu-sandbox --disable-hang-monitor
makes a difference after including the executable back into Mcafee scanning.
Thanks @Neil-140301 for providing the ETW traces, we are now able to move the issue forward with Mcafee. Can any of the affected users check if launching the application using the following flags
code.cmd --no-sandbox --disable-gpu-sandbox --disable-hang-monitor
makes a difference after including the executable back into Mcafee scanning.
Hi...happy to help 😁.
Regarding the flags, I added code.exe back to Mcafee scanning and ran the above command. The launch was still laggy and made no difference.
Thanks for confirming, in your traces the processes were all sandboxed. The flags were to confirm if disabling the sandbox made any difference, but seems like it doesn't which is good to know. Apart from the launch delay, do you see any The window is not responding
messages and is the application responsive as when excluding the binary from Mcafee ?