Skip to content

perf - simplify codicon type - #170861

Merged
Benjamin Pasero (bpasero) merged 1 commit into
mainfrom
ben/selective-kangaroo
Jan 10, 2023
Merged

perf - simplify codicon type#170861
Benjamin Pasero (bpasero) merged 1 commit into
mainfrom
ben/selective-kangaroo

Conversation

@bpasero

@bpasero Benjamin Pasero (bpasero) commented Jan 9, 2023

Copy link
Copy Markdown
Contributor

Noticed a GC kicking in for codicons given the sheer amount of instances created on startup:

Screenshot 2023-01-09 at 15 19 40

Using simple string removes the GC for me:

Screenshot 2023-01-09 at 15 13 11

Besides, I find the code in codiconStyles.ts very questionable where we have an instance of check?

@bpasero

Copy link
Copy Markdown
Contributor Author

If you have an idea how we could make codicons.ts not instantiate Codicon unless really needed, I am open. I noticed that even electron-main drags this in even though no-body is using the type, just via imports.

auto-merge was automatically disabled January 10, 2023 15:04

Pull request was closed

@aeschli

Copy link
Copy Markdown
Contributor

Thanks Benjamin Pasero (@bpasero) !

Yes, the Codicon class is not really needed. I will follow up with a PR.

@bpasero
Benjamin Pasero (bpasero) deleted the ben/selective-kangaroo branch January 10, 2023 15:21
@bpasero

Copy link
Copy Markdown
Contributor Author

Martin Aeschlimann (@aeschli) did that in #171234

@github-actions github-actions Bot locked and limited conversation to collaborators Feb 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants