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

Merge main into features/PartialEventsCtors #76946

Merged

Conversation

jjonescz
Copy link
Member

Test plan: #76859

I want to bring in #76871 before the next PR of the feature.

davidwengier and others added 30 commits January 14, 2025 08:36
Without this, Microsoft.CodeAnalysis.Workspaces.MSBuild.dll itself is
deployed, but will fail to work since it can't find any build hosts
deployed alongside the DLL.

Fixes dotnet#73854
The number of users this could help is very, very tiny, and the number
of ways it could cause further problems is much, much higher.
CyrusNajmabadi and others added 16 commits January 24, 2025 10:56
Options services are added to the LanguageServer project so that the
extract refactorings will run. The options use defaults and do not
require user interaction. This is part of the O# parity work and the
defaults match those used by O#.

Once inserted, this will resolve
dotnet/vscode-csharp#6430
In VS 17.13, the editor's `IGlyphService` implementation was improved to
return images from `IVsImageService2` based on the appropriate moniker.
This fixes several instances of blurry 16px icons throughout the IDE.

Unfortunately, some WPF components failed to specify explicit `Image`
dimensions, leading to larger than expected glyphs in the UI.

Additionally, these proper VS icons require theming, or else you can get
black-on-black or other poor contrast scenarios.

These changes add explicit dimensions to `Image`s that display glyphs
from `IGlyphService`. It also uses `ThemedImageSourceConverter` to theme
the images correctly. Sometimes this requires setting
`ImageThemingUtilities.ImageBackgroundColor`.

NOTE: `MoveStaticMembersDialog` is not themed, so I did not apply the
changes necessary to theme the icon correctly.
enables publishing a package for the vscode net9 branch
…ce (dotnet#76935)

In VS 17.14 (and previews of 17.13, but we are reverting for P5), the
editor's `IGlyphService` implementation was improved to return images
from `IVsImageService2` based on the appropriate moniker. This fixes
several instances of blurry 16px icons throughout the IDE.

Unfortunately, some WPF components failed to specify explicit `Image`
dimensions, leading to larger than expected glyphs in the UI.


![image](https://github.com/user-attachments/assets/11b53717-4d7b-41ef-a69d-d25850829bde)


Additionally, these proper VS icons require theming, or else you can get
black-on-black or other poor contrast scenarios.

These changes add explicit dimensions to `Image`s that display glyphs
from `IGlyphService`. It also uses `ThemedImageSourceConverter` to theme
the images correctly. Sometimes this requires setting
`ImageThemingUtilities.ImageBackgroundColor`.

NOTE: `MoveStaticMembersDialog` is not themed, so I did not apply the
changes necessary to theme the icon correctly.
…net#76894)

* WIP: Reduce CPU costs under AnalyzerExecutor.ExecuteSyntaxNodeActions

In the scrolling speedometer test, the Roslyn CodeAnalysis process shows about 25% of CPU spent in this method. Of that, a surprising amount of it (11.2%) is spent in ImmutableSegmentedDictionary.TryGetValue. Debugging through this code, it appears this is because that is called O(m x n) times where m is the number of nodes to analyze and n is the number of items in groupedActions.GroupedActionsByAnalyzer.

Instead, add a hook into GroupedAnalyzerActions to allow a mapping of kind -> analyzers. This can be used by executeNodeActionsByKind to get a much quicker way to determine whether the analyzer can contribute for the node in question.

Only publishing this early so Cyrus can take a peek, as I still need to do a bit of debugging around these changes. Once Cyrus and I think the changes have merit, I will create a test insertion and publish the speedometer results once those are available. Only if all that goes well will I promote this PR out of draft mode.

* Use some existing helpers to create a dictionary with ImmutableArray values.

* Early return to avoid the added array walk when not necessary

* Pull in Cyrus's suggested tweaks around ToImmutableSegmentedDictionaryAndFree

* ;

---------

Co-authored-by: Cyrus Najmabadi <[email protected]>
@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged Issues and PRs which have not yet been triaged by a lead label Jan 28, 2025
@jjonescz jjonescz marked this pull request as ready for review January 28, 2025 17:02
@jjonescz jjonescz requested review from a team as code owners January 28, 2025 17:02
@jjonescz jjonescz enabled auto-merge January 28, 2025 17:15
@jjonescz jjonescz merged commit f0833b8 into dotnet:features/PartialEventsCtors Jan 28, 2025
45 checks passed
@jjonescz jjonescz deleted the PartialEventsCtors-02-Main branch January 28, 2025 22:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.