Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Can anyone stick a date when VS became a piece of memory crunching s**t?

Can anyone stick a date when VS became a piece of memory crunching s**t?

Scheduled Pinned Locked Moved The Lounge
visual-studioperformancequestion
33 Posts 22 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

    No matter how much memory I threw at my computer VS 2022 will use all of it...

    "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

    J Offline
    J Offline
    jschell
    wrote on last edited by
    #16

    Kornfeld Eliyahu Peter wrote:

    VS 2022 will use all of it...

    That doesn't happen for me. I see it use a lot when it starts up. But it goes down substantially once everything is loaded. The computer has 32 gig. I only have one addin tool loaded which is Resharper. I don't use source control from in VS so that is turned off. I did not turn anything else off (presuming that is even possible.) I am using the Professional version. I also know that Resharper itself can chew up quite a bit of memory when it gets confused.

    1 Reply Last reply
    0
    • H honey the codewitch

      They do that on purpose. The point is to preload pretty much everything, and then the .NET GC likes to aggressively allocate gigs at a time ahead of time for its heap. The upshot is the more RAM you pig out on, the better the performance you can get from an otherwise monstrous application. It's not fair to say it requires all that RAM. If you gave it less inside say, a VM, it would still run fine, just not be quite as snappy.

      Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix

      D Offline
      D Offline
      dandy72
      wrote on last edited by
      #17

      honey the codewitch wrote:

      It's not fair to say it requires all that RAM. If you gave it less inside say, a VM, it would still run fine, just not be quite as snappy.

      I've been running versions of VS in VMs for more than a decade, and I've seen the evolution. Newer versions *do* take more and more memory, these days, I have to give my VS2022 VM 20GB of RAM; any less and things start to get glacially slow. I'd like to give it more, but the host (with 64GB) has everything else allocated to other VMs (none of which are given nearly as much as the dev VM). I'm looking at devenv.exe, and right now it's using 2.8GB all by itself. I often see it going well over 3GB. There's a crapton of other associated processes; I'm looking at ServiceHub.RoslynCodeAnalysisService.exe (another full GB) and ServiceHub.IntellicodeModelService.exe, another half GB. Yesterday I had something like "Microsoft.net.exe" (I forget the exact name) chewing up another full GB. I understand that caching is a good thing, otherwise it's wasted memory. But it acts like it owns the neighborhood.

      H 1 Reply Last reply
      0
      • D dandy72

        honey the codewitch wrote:

        It's not fair to say it requires all that RAM. If you gave it less inside say, a VM, it would still run fine, just not be quite as snappy.

        I've been running versions of VS in VMs for more than a decade, and I've seen the evolution. Newer versions *do* take more and more memory, these days, I have to give my VS2022 VM 20GB of RAM; any less and things start to get glacially slow. I'd like to give it more, but the host (with 64GB) has everything else allocated to other VMs (none of which are given nearly as much as the dev VM). I'm looking at devenv.exe, and right now it's using 2.8GB all by itself. I often see it going well over 3GB. There's a crapton of other associated processes; I'm looking at ServiceHub.RoslynCodeAnalysisService.exe (another full GB) and ServiceHub.IntellicodeModelService.exe, another half GB. Yesterday I had something like "Microsoft.net.exe" (I forget the exact name) chewing up another full GB. I understand that caching is a good thing, otherwise it's wasted memory. But it acts like it owns the neighborhood.

        H Offline
        H Offline
        honey the codewitch
        wrote on last edited by
        #18

        It may have gotten excessive. I don't notice on my machine, but then this is top shelf dev system, so it eats anything I throw at it.

        Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix

        D 1 Reply Last reply
        0
        • H honey the codewitch

          It may have gotten excessive. I don't notice on my machine, but then this is top shelf dev system, so it eats anything I throw at it.

          Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix

          D Offline
          D Offline
          dandy72
          wrote on last edited by
          #19

          I *love* using VMs, but I have to start wondering if there might not come a time where my *development* machine might need to become a dedicated physical box once more. I've been thoroughly spoiled by the idea of doing a full backup of a machine just by copying over a VHD/VHDX file...

          H 1 Reply Last reply
          0
          • D dandy72

            I *love* using VMs, but I have to start wondering if there might not come a time where my *development* machine might need to become a dedicated physical box once more. I've been thoroughly spoiled by the idea of doing a full backup of a machine just by copying over a VHD/VHDX file...

            H Offline
            H Offline
            honey the codewitch
            wrote on last edited by
            #20

            I have a dedicated machine for it because some of my tools don't work in VMs I use VMs when my dev toolchain can't set up its own virtual environment and needs things like path modifications and such. I don't bother running a VM to run VStudio. I backup all my work on github for better or worse (my clients are aware of this) and that includes ancillary work product like notes and documentation, even media - they go under my project folder in a "notes" folder. Even if I was the type of person that could count on myself to run a backup reliably, I still don't like how heavy handed they are. I don't need that huge autogenerated .vs folder for example. I don't need my massive .git folder backed up either.

            Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix

            1 Reply Last reply
            0
            • H honey the codewitch

              That's an essential application for older apps on modern PCs. You can do things like run cranky old games (I'm looking at you, Saints Row franchise) on processors with eleventy billion cores by only giving the game two so as not to confuse it, for example.

              Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix

              N Offline
              N Offline
              Nelek
              wrote on last edited by
              #21

              Cool Recoil [^] here we go :jig:

              M.D.V. ;) If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about? Help me to understand what I'm saying, and I'll explain it better to you Rating helpful answers is nice, but saying thanks can be even nicer.

              1 Reply Last reply
              0
              • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                No matter how much memory I threw at my computer VS 2022 will use all of it...

                "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                P Offline
                P Offline
                Paul Sanders the other one
                wrote on last edited by
                #22

                Don't know if anyone else has posted this, but going 64 bit didn't help. I shut it down and restart it occasionally - that seems to help.

                Paul Sanders. If I had more time, I would have written a shorter letter - Blaise Pascal. Some of my best work is in the undo buffer.

                1 Reply Last reply
                0
                • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                  No matter how much memory I threw at my computer VS 2022 will use all of it...

                  "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                  U Offline
                  U Offline
                  User 13269747
                  wrote on last edited by
                  #23

                  Quote:

                  No matter how much memory I threw at my computer VS 2022 will use all of it...

                  Depends. I was recently surprised to find VS performing snappier, using much fewer resources and generally doing things faster than VSCode on the same machine and same project. The reason? A project in plain C, with no added dependencies. Turns out, trying to decipher C++/C#/Java/etc while you type is an *expensive* process. The time taken just to reload the (template-heavy) headers for a small C++ 1000-line sourcefile is larger, on my machine, than compiling and then linking a single 4000 line C file into a single executable. And since VS has extensive capabilities WRT to C++/C#/Java source code, all that takes up extensive CPU power, while even the most extensive analysis on C is still a very quick process due to how simple the language is.

                  1 Reply Last reply
                  0
                  • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                    No matter how much memory I threw at my computer VS 2022 will use all of it...

                    "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                    L Offline
                    L Offline
                    LordWabbit1
                    wrote on last edited by
                    #24

                    Day -365 when the first release candidate came out. If it makes you feel any better (and why should it) ALL programming IDE's are memory hogs. Right now I am running an instance of VS, VS Code, Android Studio and PHP Storm (I have lots of RAM) and the one chewing up the most RAM is Android Studio, followed by VS, VS Code, and then PHP Storm. If you want to know why, write an addin for Visual Studio and get a look at the API. After that it will still suck up tons of RAM, but you will understand why. The only thing that seems to be as RAM hungry as IDE's are web browsers - ALL of them. But then if the have ever worked with the internal gubbins of Web browsers you will also know why.

                    1 Reply Last reply
                    0
                    • H honey the codewitch

                      Preloading, caching, and garbage collectors. All of which contribute to vary aggressive allocations. The upshot is better performance. Think of it this way - even when your RAM isn't being used, it's still drawing the same power regardless, but it's not doing any useful work. This way, applications put the RAM to good use - application acceleration essentially - rather than it just sitting idle.

                      Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix

                      M Offline
                      M Offline
                      MikeD 2
                      wrote on last edited by
                      #25

                      honey the codewitch wrote:

                      The upshot is better performance

                      for the application doing the work but maybe not for everything else The road to madness starts when every application takes the same route

                      R 1 Reply Last reply
                      0
                      • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                        No matter how much memory I threw at my computer VS 2022 will use all of it...

                        "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                        C Offline
                        C Offline
                        Carl_Sharman
                        wrote on last edited by
                        #26

                        Yesterday I noticed my laptop running very slowly, so I looked at my memory usage, and 'in use' was just under 30GB (there's 32GB available). I realised I hadn't restarted for a few days, probably since the start of the week. I had three instances of VS 2022 running, and they reported using about 4GB between them. So I shut down the three VS instances and it freed up nearly 10GB :wtf: I guess there are a lot of related programms processes running that wouldn't necessarily show up under VS on Task Manager. Anyway, I restarted the machine, then launched every application I previously had running, did a build on all three solutions I previously had open, and 'in use' was in low 20s. Seems like something is a bit leaky to me.

                        1 Reply Last reply
                        0
                        • M MikeD 2

                          honey the codewitch wrote:

                          The upshot is better performance

                          for the application doing the work but maybe not for everything else The road to madness starts when every application takes the same route

                          R Offline
                          R Offline
                          rtischer8277
                          wrote on last edited by
                          #27

                          There is no "everything else" when you are squeezing out the next dev action.

                          1 Reply Last reply
                          0
                          • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                            No matter how much memory I threw at my computer VS 2022 will use all of it...

                            "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                            M Offline
                            M Offline
                            MikeCO10
                            wrote on last edited by
                            #28

                            I don't know if I've noticed. VS uses whatever it has available to it. There's been some performance improvements I've noticed in the past year or so and it seems to me that Win10/11 has better memory allocation as well. My office box that I physically see a handful of times per year, is an I7-6700 with 16GB memory. Aside from GotomyPC, it typically has VS, a PHP ide, Edge and Firefox with multiple windows and a few dozen tabs open, along with both dev windows open. Also, a couple of Excel windows, Word with a few docs, Outlook and Teams. Occasionally with QGIS running too. The VS project is a large desktop App and I bounce around a lot using the other open apps. It keeps plugging along without any errors, sometimes with no reboots between MS updates. The only issue is when it sits in "update hell", with a pending system update where it loses pieces of its mind. I have learned the hard way to never, ever, run VS with a pending system update. :( The results can be, let's say, ugly.

                            1 Reply Last reply
                            0
                            • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                              No matter how much memory I threw at my computer VS 2022 will use all of it...

                              "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                              D Offline
                              D Offline
                              David On Life
                              wrote on last edited by
                              #29

                              Can you provide any details? How much memory does your system have? How much is VS using? [Sysinternals](https://learn.microsoft.com/en-us/sysinternals/) VMMap is a good tool for looking at how memory inside a process is used, although I suspect the issue is more around how your system memory is being used, for which RAMMAP would be the better tool (although even Task Manager can provide some basic info). On my system DevEnv.exe (VS) is currently the 3rd largest process with a private working set of 750MB and a commit size of 1.5GB. That seems reasonable on my 32GB system (which is running slow right now, but DevEnv isn't the culprit, and I'm way overdue for a reboot...). I spent 8 years on the VS performance team, a good chunk of which was keeping it within the 4GB limit for a 32 bit process, so I used to have a pretty good handle on the problem (that was 9 years ago, and now that it's 64 bit that's less of an issue, although good memory hygiene is still important).

                              1 Reply Last reply
                              0
                              • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                                No matter how much memory I threw at my computer VS 2022 will use all of it...

                                "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                                C Offline
                                C Offline
                                cosmogon
                                wrote on last edited by
                                #30

                                I first noticed it when upgrading to 2019. Now, with 2022, it's even worse. But I'm also using ReSharper, and their upgrades over the years probably have become more demanding also. The worst thing (with my old 8 GB RAM and HDD only PC) is that if I leave the machine for a few minutes, Windows memory management instantly throws everything into virtual memory, and then when I get back I have to wait for it to be pulled back into RAM again before I can do anything. Drives me nuts. I presume that if you have plenty of RAM you're at least being spared from that.

                                1 Reply Last reply
                                0
                                • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                                  No matter how much memory I threw at my computer VS 2022 will use all of it...

                                  "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                                  B Offline
                                  B Offline
                                  BernardIE5317
                                  wrote on last edited by
                                  #31

                                  Task Manager reports 2.2G maximum editing/building/debugging .

                                  1 Reply Last reply
                                  0
                                  • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                                    No matter how much memory I threw at my computer VS 2022 will use all of it...

                                    "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                                    U Offline
                                    U Offline
                                    User 11907673
                                    wrote on last edited by
                                    #32

                                    Since forever? Or at least VS 6.0 anecdotally speaking. And with no end in sight. But so what? For the facilities it gives me which translates directly to speed of accomplishing things buying the bigger machine is well worth it compared to how much get paid. And this is my long term view after 30 or so years or using VS.

                                    1 Reply Last reply
                                    0
                                    • Kornfeld Eliyahu PeterK Kornfeld Eliyahu Peter

                                      No matter how much memory I threw at my computer VS 2022 will use all of it...

                                      "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization." ― Gerald Weinberg

                                      E Offline
                                      E Offline
                                      ezbncs
                                      wrote on last edited by
                                      #33

                                      That is easy to answer man any rlses after win 10 pro 1903 version lol. VS is a a pos but then again windows wasnt cool since what win xp maybe windows 7 lol. Debian 11 I run and love it windows is just for the special thing lazy days lol.

                                      1 Reply Last reply
                                      0
                                      Reply
                                      • Reply as topic
                                      Log in to reply
                                      • Oldest to Newest
                                      • Newest to Oldest
                                      • Most Votes


                                      • Login

                                      • Don't have an account? Register

                                      • Login or register to search.
                                      • First post
                                        Last post
                                      0
                                      • Categories
                                      • Recent
                                      • Tags
                                      • Popular
                                      • World
                                      • Users
                                      • Groups