- #36
Filip Larsen
Gold Member
- 1,889
- 799
yungman said:how the hell the programs in 4 chapters can be 5GB is size from VS? Those are all example short programs
Visual Studio maintains a
.vs
subfolder (in same folder as the solution file) with a lot of temporary information generated for code insight and similar which over time eats up a lot of space, so if you have included that in your size measurement I'm not surprised you see 5 GB used. I haven't investigated why, but it sure seems like VS is not really good at reclaiming unused files in that folder so I often end up just deleting that folder from time to time.Another thing that may influence the size of the executable (not that I think this is what you see with your 5 GB usage) is whether it uses static or dynamic (shared) linking. Default should be dynamic linking which means the executable size is small but then requires the proper DLL's to be present on the path when running the executable, whereas full static linking means big executable but no extra DLL's required at runtime. Real world VS solutions is often a mix of these with standard libraries being dynamically linked and internal project libraries statically linked.