什么是最佳的行军& gcc for“Pentium4及以上版本”的mtune选项处理器 [英] What's optimal march & mtune options for gcc for "Pentium4 and above" processors

查看:259
本文介绍了什么是最佳的行军& gcc for“Pentium4及以上版本”的mtune选项处理器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的C ++应用程序(使用g ++编译)需要在Pentium-4(32位)及更高版本上运行。但是,它通常用于Core2Duo或更好的处理器。



我目前使用的是: -march = pentium4 -mtune = pentium4 。但有些阅读促使我认为 -march = pentium4 -mtune = generic 可能会更好。



有人可以对此有所了解?三月和三月的最佳值是多少?在这种情况下的mtune选项是什么?



平台:RHEL 5.3(32位)上的GCC 4.1.2。

解决方案

这可能是 -march = pentium4 -mtune = core2 ,可以看到关于GCC手册


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).

解决方案

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

这篇关于什么是最佳的行军& gcc for“Pentium4及以上版本”的mtune选项处理器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆