razor icon indicating copy to clipboard operation
razor copied to clipboard

RemoteTagHelperProviderService.GetTagHelpersDeltaAsync consumes significant resources while editing

Open vsfeedback opened this issue 2 years ago • 4 comments

This issue has been moved from a ticket on Developer Community.


[severity:It bothers me. A fix would be nice] I am kicking the tires to 17.3.0 Preview 2 and while things seem better (no guarantees ) I am noticing a long amount of CPU time with the simplest of key presses. There appears to be a good deal of Garbage Collection, too (25%):

Looks like this is where the grief is occurring:


Original Comments

Feedback Bot on 6/16/2022, 11:28 PM:

(private comment, text removed)

Feedback Bot on 6/22/2022, 00:12 PM:

(private comment, text removed)

Feedback Bot on 6/22/2022, 02:53 PM:

(private comment, text removed)


Original Solutions

(no solutions)

vsfeedback avatar Jul 14 '22 21:07 vsfeedback

@333fred @chsienki looking at traces here it looks like all the TagHelper introspection on the various projects are at fault here. How hard would it be to expose an API that allowed us to "discover" TagHelpers for a specific assembly instead of the entire compilation? That way we'd at least be able to cache a large amount of "impacted" TagHelper resolution assemblies come discovery in the IDE.

OR is this out of scope until we can re-use the SOurceGenerator infra?

NTaylorMullen avatar Jul 25 '22 17:07 NTaylorMullen

I believe this is likely going to be out of scope until we can reuse infra. Part of that is restructuring everything about how tag helpers work in the razor compiler, and I'm hesitant about exposing any new APIs until we finish that (though keeping this use case in mind while we do so will be good).

333fred avatar Jul 25 '22 17:07 333fred

I hate to ask, but... any idea when the new infrstructure bits will be available to unblock this issue? 😇

Mike-E-angelo avatar Aug 04 '22 11:08 Mike-E-angelo

At this point, no. We're working through the technical debt in the razor compiler, but we're still trying to figure out what things need to be invested in first to make sure that we don't create more debt as we go.

333fred avatar Aug 04 '22 18:08 333fred

Moving to compiler. Let us know if that's incorrect.

DustinCampbell avatar Nov 02 '22 23:11 DustinCampbell