打印
[应用相关]

代码优化等级说明

[复制链接]
182|1
手机看帖
扫描二维码
随时随地手机跟帖
跳转到指定楼层
楼主
232321122|  楼主 | 2023-2-25 10:20 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
  • level 0 : Minimum optimization. Turns off most optimizations.It gives the best possible debug view and the lowest level of optimization.
最小优化。关闭大多数优化。它提供了最佳的调试视图和最低级别的优化。
  • level 1 : Restrictedoptimization. Removes unused inline functions and unused static functions.Turns off optimizations that seriously degrade the debug view. Ifused with --debug, this option gives a satisfactorydebug view with good code density.
限制优化。删除未使用的内联函数和未使用的静态函数。关闭严重降低调试视图的优化。如果与--debug一起使用,该选项提供了一个具有良好代码密度的令人满意的调试视图。
  • level 2 : Highoptimization. If used with--debug, the debug viewmight be less satisfactory because the mapping of object code tosource code is not always clear.
高度优化。如果与--debug一起使用,debug视图可能不太令人满意,因为目标代码到源代码的映射并不总是清晰的。
  • level 3 : Maximumoptimization.-O3 performs the same optimizations as -O2.However the balance between space and timeoptimizations in the generated code is more heavily weighted towardsspace or time compared with-O2.
最大化优化。-O3执行与-O2相同的优化,但是生成代码中的空间和时间优化之间的平衡比S-O2更盛一筹。

使用特权

评论回复
沙发
单片小菜| | 2023-2-27 11:35 | 只看该作者
前些天,设置不了断点,就是因为优化的级别太高了。弄了好久。

使用特权

评论回复
发新帖 我要提问
您需要登录后才可以回帖 登录 | 注册

本版积分规则

3

主题

2416

帖子

1

粉丝