-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Improve performance - rewrite to run as a separate process #45
Comments
Something changed in 17.8 that either makes this slower or manes that the way the time is calculated makes this seem to the internal clock that this is taking longer. I think the solution is a complete rewrite to move the code out of process. I was hoping that the new extensibility model would help make this easier but that still has no indication of when it will be usable in released extensions. I'm open to alternate suggestions for intermediate solutions such as skipping certain projects or only running on certain solutions. The time taken is searching for and parsing the files. This is done off the UI thread as much as possible but lots of the old VS extension APIs require the UI thread. :( Sadly, it's larger projects where this is more of an issue, but it's also larger projects where this is more valuable.... Note. This also affects ConstVisualizer too :( |
I think that OOP extensions will come as large feature in next major version (maybe VS2024) . I ignore this for now and click the message away. |
it is around 30 projects. I loaded the complete solution to update the nugets after yesterdays patchday, normally I only load a solution with less entries (old desktop UI, UWP, MAUI when I work on a one smaller part) I removed the extension and VS doesn't get frozen any longer and doesn't show a perf warning message any longer. |
I got a message that VS was blocked for 8s, in Output I see this info you've added:
|
@MagicAndre1981 thanks for the update. Because I'm doing things that VS insists happen on the UIThread I think the real solution is a rewrite. I'll continue trying to find any small improvements in the meantime, but as VS has become increasingly persistent in showing the warning you're seeing, you are free to uninstall or tell VS to stop warning about this extension. Far from ideal but the best I can do right now. Of course, if anyone wants to help out by rewriting this extension to work as a separate, process connected to an extension, I'm happy to talk more. :/ |
when I load a smaller part of the great solution (only the Android app part of the Xamarin Forms app, with the ns2.0 shared app code and a few other ns2.0 DLLs with common code) I see 16s delay but in output only short durations:
and the confusing thing is that the rex files from the WinForms client are still processed even if they are not part of the actual loaded sln:
So only load the resx files if they are really part of projects within the sln may improve perf for some solutions. |
There's a separate timer tracking how long it spends parsing the resource files and that only reports duration if it takes longer than a second. The time difference is why I initially started adding my own timers as I couldn't understand why the times it was claiming could ever happen. My current thought is that there's a lock on solution/project load that is delaying the IO as I query the file system.
Sadly, this is a big logic change as knowing which resource files are of interest would mean waiting for the solution/project to finish loading which has other knock-on effects on my current logic. For now, I just search from the root of where the solution file is. - Not perfect but mostly good enough. The journey to improvement continues.... |
but this would be the better approach After loading you can see this icon in statusbar and clicking it shows that at lot of activity happens after load. Do you work here, too and check if the resx files are part of the loaded solution. I think this should fix the perf warnings. MS does it also to improve solution load: |
from marketplace:
There are a few things to investigate:
Improvement would be particularly relevant to files with no resources to adorn as these files gain nothing from a delay. At least if a delay in loading results in additional information being displayed it can be slightly more easily justified
The text was updated successfully, but these errors were encountered: