-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Consider caching toolset information in memory #6667
Comments
Caching the data would also affect reading machine.config which is read before the .exe.config.
|
@nohwnd isn't |
Under devenv.exe I saw it loaded when the .exe.config was loaded by System.Configuration. So reducing the number of times the .exe.config gets loaded by ProjectCollection, will reduce the number of times machine.config gets loaded. |
Ah, interesting! We could probably avoid that by reading the configuration directly as XML rather than using |
Fixes #6667 Context Tools configuration is read from MSBuild.exe.config multiple time. We can simply cache related configuration section to optimize config file access. Changes are under opt-out escape hatch. Changes Made Cached in static variable. Caching is not applied in unit tests cases. Testing Rebuilds and incremental build of orchard core. ETL has been captured to verify reading from MSBuild.exe.config was optimized. Notes When measured the real perf difference in both CPU and wall-clock time was negligible/non-verifiable.
Issue Description
From @rainersigwald:
MSBuild stores “toolset” information in the .exe.config, which is used to populate default properties and do some other configuration. Today we will read that once per
ProjectCollection
— we can consider caching it for process lifetime since “manually editing msbuild.exe.config” is not a common/supported scenario and VS upgrades would always kill processes.Steps to Reproduce
Create
ProjectCollection
and notice that several config files are read (machine.config, msbuild.exe.config).Data
The text was updated successfully, but these errors were encountered: