Dictated by the motherboard, so 32GB.
There are two limiting factors :
1. the mobo designed support
2. the operating system
32-bit O/Ss are limited to 4GB. 64-bit systems are limited by the two factors above
Win 7-8 have DRAM limitations based on what version you are using. The link below shows the Win 7-8 Memory limitations based on what version you are using: