How can I determine programmatically whether my machine is an x86, x64 or an IA64?
On Windows Systems you can get the environment variable PROCESSOR_ARCHITECTURE. Here is an MSDN article explaining the values that can be returned.
PROCESSOR_ARCHITECTURE=AMD64 PROCESSOR_ARCHITECTURE=IA64 PROCESSOR_ARCHITECTURE=x86