如何在vc ++中获得OS系统位? [英] How to get OS system bit in vc++?
本文介绍了如何在vc ++中获得OS系统位?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何在vc ++中获得OS系统位?是32位还是64位?以及一些系统信息.
How to get OS system bit in vc++? whether it is 32-bit or 64- bit?? and some system informations.
推荐答案
请参见本白皮书 [^ ].
查看此讨论,
http://stackoverflow.com/questions/2140619/正确的方法来检查Windows-is-64位或非运行时c
或这个
Check this discussion,
http://stackoverflow.com/questions/2140619/correct-way-to-check-if-windows-is-64-bit-or-not-on-runtime-c
or this,
http://mark.koli.ch/2009/10/reliably-checking-os-bitness-32-or-64-bit-on-windows-with-a-tiny-c-app.html
查看指针有多长时间.
cout << sizeof(void *);
对于32位是4,对于64位是8.
see how long is the pointer.
cout << sizeof(void *);
4 for 32-bit, 8 for 64-bit.
这篇关于如何在vc ++中获得OS系统位?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文