0

I've been working on a 3D game using C++/OpenGL alongside GLFW/GLEW/boost. I started the project using the CodeBlocks IDE using the GNU GCC compiler, and I've recently attempted to migrate the project over to Visual Studio 2010. I managed to get the project to compile and run properly, but ran into a problem.

When compared to the CodeBlocks GCC build (100 FPS), the Visual Studio build (30 FPS) dropped a solid 70 FPS with no changes made to the code. Has anyone else experienced this issue with Visual Studio, or does anyone have any idea as to why the frame rate might be so slow using Visual Studio?

I can't think of any specifics that would help narrow down the problem, but I'll answer any questions regarding the project or my settings.

nprof50
  • 21
  • 2
  • 1
    are you running it in debug or release? If you are making use of the STL this has been known to be slow on Visual Studio with debug builds due to the iterator debugging support. If you are running in debug and using the STL then try running in release build and see if that improves things. – const_ref Oct 01 '14 at 14:25
  • I've tried both. The release build runs a bit faster than the debug build, but both are nowhere close to as fast as when built with GCC. I also have the flag/value _ITERATOR_DEBUG_LEVEL=0 in my settings. – nprof50 Oct 01 '14 at 14:28
  • Have you tried any code profiling to see if there are any bottlenecks? Also I assume you are using the same hardware and have only changed the compiler? – const_ref Oct 01 '14 at 14:29
  • Yes same hardware. I'll try code profiling and let you know if I find anything that sticks out. – nprof50 Oct 01 '14 at 14:31
  • I just profiled, but couldn't find anything that sticks out. I feel like this could be caused by additional debug information that may be either added in by the Visual Studio compiler, or the external libraries I'm using in the app. Could this be a potential issue? – nprof50 Oct 01 '14 at 14:44
  • Additional debug information should not exist in a release build. That is unless you are using the RelWithDebugInfo configuration or wrongly using Debug dlls in a release application. – drescherjm Oct 01 '14 at 15:18
  • I assume you are not using .NET/CLR in your Visual Studio application. – drescherjm Oct 01 '14 at 15:20
  • Purely an OpenGL/GLFW-based application. No .NET/CLR involved. – nprof50 Oct 01 '14 at 15:44

0 Answers0