You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Show Running Extension > Start Extension Host Profile button does nothing #194678
bugIssue identified by VS Code Team member as probable bugextension-hostExtension host issuesunder-discussionIssue is under discussion for relevance, priority, approach
Does this issue occur when all extensions are disabled?: Yes
VS Code Version: 1.83.0-insider (Universal)
OS Version: Mac 13.4.1 (22F82)
Steps to Reproduce:
Type Cmd-Shift-P Developer: Show Running Extension
Near the top right there's a circle icon. Hovering over it shows the tooltip "Start Extension Host Profile". Click this button.
Expected:
It starts an extension host profile, turning the icon into a square. Clicking the icon again shows an extension profile, showing which extensions too the most time.
Actual:
Clicking the button does nothing.
Reacted by Marco Sylvestersen, Brian Scholer, Zach Hardesty and Simon Sassi
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.82.3. Please try upgrading to the latest version and checking whether this issue remains.
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.82.3. Please try upgrading to the latest version and checking whether this issue remains.
Happy Coding!
Ok, I reproduced this with the latest insiders build & updated the PR description with my insiders version.
This sends the SIGUSR1 signal which on windows doesn't exist. We have or used to have an alternative for that the utility process might not support that?
Great, the output indicates the process has the inspector agent started on 127.0.0.1:57279. This confirms that utility process is able to start the inspector. Now as a next step, can you help us confirm if a client is able to connect to this agent,
Restart VSCode
Copy the pid of extensionHost from the VSCode process explorer
In system terminal, run kill -s SIGUSR1 <pid-of-extension-host>
In system terminal, run lsof -Pan -p <pid-of-extension-host> -i.
Copy the host:port from the previous output
Open chrome or edge browser and visit chrome://inspect page
Click Open Dedicated developer tools for Node
In the Connection tab enter the host:port that was copied
The developer tools should now connect to this process and in the chrome://inspect/#devices page you should see an entry electron/js2c/utility_init under the Remote Devices section
Great, the output indicates the process has the inspector agent started on 127.0.0.1:57279. This confirms that utility process is able to start the inspector. Now as a next step, can you help us confirm if a client is able to connect to this agent,
Restart VSCode
Copy the pid of extensionHost from the VSCode process explorer
In system terminal, run kill -s SIGUSR1 <pid-of-extension-host>
In system terminal, run lsof -Pan -p <pid-of-extension-host> -i.
Open chrome or edge browser and visit chrome://inspect page
Click Open Dedicated developer tools for Node
In the Connection tab enter the host:port that was copied
The developer tools should now connect to this process and in the chrome://inspect/#devices page you should see an entry electron/js2c/utility_init under the Remote Devices section
Thanks for the instructions. Looks like everything connected OK. I can even use the devtools to capture a performance profile, which can be used as a workaround to find slow extensions.
Thanks for confirming, Johannes Rieken (@jrieken) looks like the inspector agent is working fine for the user, so indicates an issue in the inspector client code path. For this action, the client we use is the profilingservice based on v8-inspect-profler
Robo (@deepak1556)Connor Peet (@connor4312) Hi, just a question, the extension host profile command works well for me, but how should I analyze extension host performance in vscode.dev or code-server? Seems vscode.dev didn't have this command, and Chrome developer tools could record performance, but it records all the information, and not include extension host related information.
bugIssue identified by VS Code Team member as probable bugextension-hostExtension host issuesunder-discussionIssue is under discussion for relevance, priority, approach
Activity
vscodenpa commentedon Oct 3, 2023
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.82.3. Please try upgrading to the latest version and checking whether this issue remains.
Happy Coding!
bmalehorn commentedon Oct 3, 2023
Ok, I reproduced this with the latest insiders build & updated the PR description with my insiders version.
jrieken commentedon Oct 5, 2023
This sends the SIGUSR1 signal which on windows doesn't exist. We have or used to have an alternative for that the utility process might not support that?
deepak1556 commentedon Oct 5, 2023
I am unable to repro with latest insiders, can you try the following steps to narrow down the issue
extensionHostfrom the process explorerkill -s SIGUSR1 <pid-of-extension-host>lsof -Pan -p <pid-of-extension-host> -i.bmalehorn commentedon Oct 9, 2023
Sure.
Copied the pid of

Code - Insiders Helper (Plugin):Ran the above commands:
deepak1556 commentedon Oct 9, 2023
Great, the output indicates the process has the inspector agent started on
127.0.0.1:57279. This confirms that utility process is able to start the inspector. Now as a next step, can you help us confirm if a client is able to connect to this agent,extensionHostfrom the VSCode process explorerkill -s SIGUSR1 <pid-of-extension-host>lsof -Pan -p <pid-of-extension-host> -i.host:portfrom the previous outputchrome://inspectpageOpen Dedicated developer tools for NodeConnectiontab enter thehost:portthat was copiedchrome://inspect/#devicespage you should see an entryelectron/js2c/utility_initunder theRemote Devicessectionbmalehorn commentedon Oct 10, 2023
Thanks for the instructions. Looks like everything connected OK. I can even use the devtools to capture a performance profile, which can be used as a workaround to find slow extensions.

deepak1556 commentedon Oct 17, 2023
Thanks for confirming, Johannes Rieken (@jrieken) looks like the inspector agent is working fine for the user, so indicates an issue in the inspector client code path. For this action, the client we use is the profilingservice based on
v8-inspect-proflervscode/src/vs/workbench/contrib/extensions/electron-sandbox/runtimeExtensionsEditor.ts
Line 144 in f1c3b1d
3 remaining items
connor4312 commentedon Dec 7, 2023
At least for me this seems to be because the profiler interface is trying to connect to
::1where the devtools port is only listening on127.0.0.1. Probably some extra information needs to be passed in this call: https://github.com/jrieken/v8-inspect-profiler/blob/master/index.js#L39The profile module also eats the underyling error which makes it a little harder to troubleshoot https://github.com/jrieken/v8-inspect-profiler/blob/master/index.js#L47-L52
exthost: fix profiling not working
fix: allow specifying the host to connect to
exthost: fix profiling not working (#209142)
chouzz commentedon Jun 3, 2024
Robo (@deepak1556) Connor Peet (@connor4312) Hi, just a question, the extension host profile command works well for me, but how should I analyze extension host performance in
vscode.devorcode-server? Seemsvscode.devdidn't have this command, and Chrome developer tools could record performance, but it records all the information, and not include extension host related information.connor4312 commentedon Jun 3, 2024
Chrome devtools records performance, you need to look in the area for the web worker extension host.
chouzz commentedon Jun 3, 2024
Got it! Thanks!