When developing a software product for a Windows-family operating system, you must keep in mind the restrictions imposed on sizes of data a program can declare and use.
Windows imposes the following 3 types of restrictions on applications:
For a 32-bit application launched in a 32-bit Windows, the total size of all the mentioned data types must not exceed 2 Gbytes. (Actually it is 1.75 Gbytes due to memory requirements of the operating system itself). A 32-bit program compiled with the switch /LARGEADDRESSAWARE:YES can allocate up to 3 Gbytes of memory if the 32-bit Windows is launched with the /3gb switch. The same 32-bit program launched in a 64-bit system can allocate about 4 Gbytes (actually about 3.5 Gbytes).
Note that the restrictions for maximum sizes of statically allocated memory and stack memory are the same for 32-bit and 64-bit Windows-applications. This is determined by the format of file type Portable Executable (PE), which is used in Windows to describe exe and dll files. You should keep in mind that these restrictions are imposed by the operating system itself, and do not depend on the compiler you are using.