I use Visual Studio 2017. In a project (that I target as x64), I get error : C1060, compiler is out of heap space, and sadly learned there happen to exist a memory limitatio
By default Visual Studio uses the 32-bit toolchain (i.e. the compiler is 32-bit and cross-compiles 64-bit executables). Visual Studio 2015 and 2017 include both 32-bit and 64-bit versions of all the compilers (x86, x64, arm, arm64).
You can opt-in to using the 64-bit toolchain on a 64-bit system by two methods:
For example:
set PreferredToolArchitecture=x64
devenv
vcxproj files to do this as well with the x64 element:For example:
Application
true
v141
x64
Unicode
I use the second method in the UWP (C++/WinRT) versions of my Direct3D Game VS Templates, and I just noticed that I should add it to my UWP (C++/CX) and Win32 versions. The Xbox One XDK automatically does this in it's platform build rules as well.
Note this question has been answered in the past: How to make Visual Studio use the native amd64 toolchain