Insanely long compile times

Hey everyone,

So recently my Visual Studio 2015 has been taking a really long time to compile my game code, even just small incremental changes. And the thing is, I don’t remember if I did anything that drastic to my game code.

To my recollection, I’ve only tinkered with some assets for my game and set up a Git repo for some version control.

My compile times went from being 7 seconds on average to 3 minutes. 3. Minutes. It’s absolutely ridiculous.

Does anyone know a possible solution to this? Thanks!

To speed up compilation of the engine itself, in 4.15 Epic stopped including Engine.h and UnreadEd.h and included just the headers they actually needed.

My guess would be either you included one of those monolithic headers yourself, or (more likely) you included an engine header that itself includes those monolithic headers. If the latter is true, then your compilation times should speed up when you update to 4.15 (wait until it’s stable before migrating a production project, though!)

I’ll check to see if any of my code has those includes. Thanks!

Aside from that, do you know if Git has anything to do with the issue? I did some testing where I removed my project files from my Git repo and then after I commited and tried building, my times went back to normal. My guess As to why is maybe git was tracking all the changes that occurred to lots of files and that slowed down the compile.

Git really shouldn’t affect compilation…unless you are somehow integrating your git usage into Visual Studio itself – at which case all bets are off.

Don’t know about that lol. Like I said in my previous post right when I commited the removal of my project from the repo, compilation times went back to normal. They’re actually still a little slow but maybe that’s just me…

So I checked and it seems the headers that you mentioned weren’t included. So I’m honestly not sure what happened. I’ll keep close eye on it though. Thanks for the advice!