Fixing VisualStudio performance problems by storing generated sources #359
pziezio
started this conversation in
Show and tell
Replies: 2 comments 2 replies
-
See #355 also. |
Beta Was this translation helpful? Give feedback.
0 replies
-
We made some significant perf improvements a short while back. What version are you using when you experience unacceptable perf degradation, @pziezio? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'd like to share my solution to VisualStudio performance problems when using CsWin32.
I'm using VS2019 Preview but I don't see that generated sources are cached in any way and IntelliSense is just not usable.
I prepared the list of the functions I use in the
NativeMethods.txt
file and I practically never add new ones anymore.So I set
"emitSingleFile": true
in configuration file and stored generated sources in new fileNativeMethods.cs
.My
*.csproj
file looks like this:I can set custom property
UseCsWin32
totrue
if I want to generate new imports or update packages.Of course, it contradicts the idea of automatic code generation but it just works for me.
Idea: maybe it would be possible to add new configuration option like
"cacheSources": true
that would store generated sources on disk. That would solve all of the performance problems once and for all.Beta Was this translation helpful? Give feedback.
All reactions