Windows XP 32-bit supports 4GB of RAM but the amount that Windows will be able to address when you have 4GB of RAM is around the 3GB mark. The physical memory addresses are sub-divided to manage both the PCI memory address range also known as Memory Mapped I/O Device (MMIO) as well as the physical memory that you have installed in your system and this is the reason why windows always reports less than 4GB even though you have 4GB of physical RAM installed in your system.
The PCI memory addresses, which are assigned from a top to bottom manner, are used for things like the BIOS, network cards, PCI-Express and graphics cards. The largest chunk of addresses is used up by the graphics card which needs addresses for at least the amount of memory that is on the graphics card.
The result of this is that the system may allocate 512MB to as much as 1 GB maybe even more depending on your hardware configuration purely for the PCI memory addresses before any RAM (Physical Memory) addresses have even been allocated.