What's optimal march & mtune options for gcc for “Pentium4 and above” processors

女生的网名这么多〃 提交于 2019-12-06 06:39:29

问题


My C++ application (compiled using g++) needs to work on Pentium-4 (32-bit) and above. However, it's typically used with Core2Duo or better processors.

I'm currently using: -march=pentium4 -mtune=pentium4. But some reading has prompted me to think that -march=pentium4 -mtune=generic might be better.

Can anybody shed some light on this? What are the optimal values for march & mtune options in this case?

Platform: GCC 4.1.2 on RHEL 5.3 (32-bit).


回答1:


That would be -march=pentium4 -mtune=core2, as can be seen on the GCC manual.



来源:https://stackoverflow.com/questions/6779375/whats-optimal-march-mtune-options-for-gcc-for-pentium4-and-above-processors

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!