怎么在程序里手动开O2

P2396 yyy loves Maths VII

g++ 的程序杂注好像可以 #pragma
by Apache553 @ 2017-07-05 18:47:38


可以看这个http://blog.csdn.net/xsckernel/article/details/47343201 如: ```cpp OPT inline ll fpow(ll a,ll p,ll mod){ ll res=1; for(;p;p>>=1,a=a*a%mod) if(p&1) res=res*a%mod; return res; } OPT int main(){...} 我也不太清楚,从学长代码里看见的 ```
by SovietPower✨ @ 2017-07-05 21:47:56


补前面的: #define OPT \_\_attribute\_\_((optimize("O2")))
by SovietPower✨ @ 2017-07-05 21:48:28


#pragma GCC optimize(2) 应该可以
by 一只小兔子 @ 2018-11-06 21:07:42


|