This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
loop unrolling, flags and passes
- From: Abdul Wahid Memon <engrwahidmemon at gmail dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Mon, 13 Dec 2010 01:08:36 +0100
- Subject: loop unrolling, flags and passes
Hello everyone
I have few questions regarding loop unrolling and the effect of flags
(provided at command line) on the execution of passes.
Is it possible to do loop unrolling without using -O3, -O2 and -O1?
The -Q -O3 --help=optimizers options provides us the list of enabled
and disabled optimizations at -O3 level. If I specify -O3 to compile
any file then the total number of passes executed are around 182. And
If I manually specify all the optimization which are enabled at -O3
(without specifying -O3 actually), we get the total number of passes
as 64. So, my question is that why is there a difference of passes
between these two cases?
And while specifying all enabled optimizations (at -O3) along with
-funroll-all-loops, I am unable to do the unrolling, while the same
program is unrolled if we specify -O3 along with -funroll-all-loops.
Best regards
Memon