Tech Off Thread

13 posts

Forum Read Only

This forum has been made read only by the site admins. No new threads or comments can be added.

VS2012 Speed - Unintended feature?

Back to Forum: Tech Off
  • User profile image
    GreyLensman

    I suspect that I may have run across a feature of VS 2012 of which I am unaware.  I am using VS 2012 Premium along with VS 2012 Team Foundation Server environment. 

    My development box does not host TFS but is a client without any server components. 

    The problem I am observing is that some process is magically compiling each and every project I have in my work space even though I have not touched them for months.  I can't figure out what is pre-compling everything and find it somewhat annoying.  I suspect that this pre-compile action is why I observe a slowdown in operation after reboots.

    What do I mean by "pre-compile"?  If I go through and remove each and every "bin/obj/debug/release" folder from each of the dozens of projects today.  At this point if you examined each project from Explorer there would be no bin/obj/debug/release folders nor their contents.  I then shut off the machine and go home.  The next day I turn on the system and launch VS 2012.  I compile a given project and would expect to see a debug/release/obj/bin folder for the project I am working within along with any related projects in the same solution.  I however observe debug/release/obj/bin folders in all projects having "todays" date/time stamps.

    What is performing this magic pre-compile?  How do turn it off?  Is this why VS 2012 gets the bad rap of being slow?

     

  • User profile image
    Sven Groot

    VS2012 will create the folders simply by opening the project (actually all versions of VS in recent history have done that). Is there anything in them? I don't think you'd find real object and exe files until you actually build.

  • User profile image
    GreyLensman

    No, the folders are fully populated.  I.E., they contain the equivalent of my having recompiled each and every project.  I am talking about dozens of projects here, not one or two.  All the expected content, dll's and such are present.    Even projects/solutions for which I have had zero active development for 3-4 months get recompiled.  Projects which are 100% self contained (not reliant on outside libraries) are also recompiled without my having opened them.

     

     

     

  • User profile image
    spivonious

    @GreyLensman: That's really strange. I'm not seeing that behavior on my PC. Do you have any add-ons installed that might be doing it for you?

    edit: Actually, I do see it. It fully populates the bin/obj folders when I open the project. Interesting. The folders showed up right away, but their contents weren't there until the preview scrollbar loaded. This would explain why our huge web app takes forever to open from a fresh workspace.

  • User profile image
    GreyLensman

    I have the Team Found Data suite of tools and the Telerik suite of software.  I suspect, but have not proven, that problem is some unknown aspect of Team Foundation Server 2012.  It appears to be refreshing each and every workspace upon power up.  Project I do not directly open are getting rebuilt.

     

     

  • User profile image
    fabian

    Do you have resharper installed?

  • User profile image
    Ion Todirel

    @GreyLensman: Do you have any dependencies between your projects? Dependencies are also built, even if you build just one of the projects, P2P references also add dependencies. But you don't need a P2P to add a dependency. Look using the Project Dependencies dialog.

    Also look at the build log, and see how many of the projects are built. Do rebuild that one project, just to read the output more cleanly.

  • User profile image
    GreyLensman

    What do you mean by "build log".  I know of the output window log but not a specific build log.  The output window log shows the building of items expected, not the two dozen or so non-related projects which are getting rebuilt daily.

  • User profile image
    Ion Todirel

    What triggers it? Is it Visual Studio or an external process?

  • User profile image
    GreyLensman

    That is the reason for my question.  I have not been able to determine what is the source.  Purely based upon the symptoms it seems that each project in my workspace is getting recompiled after every reboot no matter if I am using it or not.  I could understand if I compile project "A" which has shared code with "B" and "C" if projects "B" and "C" get recompiled.  I can't understand why project "z" (a unrelated project) gets recompiled

    I suspect it is tied to TFS and the usage of local workspaces by VS 2012.  GIven I have no formal training on TFS I suspect it but cannot prove it.

  • User profile image
    Ion Todirel

    , GreyLensman wrote

    That is the reason for my question.  I have not been able to determine what is the source.  Purely based upon the symptoms it seems that each project in my workspace is getting recompiled after every reboot no matter if I am using it or not.  I could understand if I compile project "A" which has shared code with "B" and "C" if projects "B" and "C" get recompiled.  I can't understand why project "z" (a unrelated project) gets recompiled

    I suspect it is tied to TFS and the usage of local workspaces by VS 2012.  GIven I have no formal training on TFS I suspect it but cannot prove it.

    Does this happen just by opening Visual Studio? What if you don't open VS at all? Does it happen only if you open Visual Studio and build one of the projects? What if you just open Visual Studio and do no invoke any builds at all?

  • User profile image
    spivonious

    @Ion Todirel: It happened with me (at least with the currently open project) when I just opened it in VS - no build triggered.

  • User profile image
    Ion Todirel

    , spivonious wrote

    @Ion Todirel: It happened with me (at least with the currently open project) when I just opened it in VS - no build triggered.

    Does it repro consistently? If yes, I suggest opening a connect bug and attaching the repro project to it.

Conversation locked

This conversation has been locked by the site admins. No new comments can be made.