Understanding PrintAssembly output
Dmitry Samersoff
Dmitry.Samersoff at oracle.com
Wed Dec 7 21:41:01 PST 2011
Manohar,
C2 compiler use various methods of optimization of generated code,
particularity - it unrolls loops when possible.
-Dmitry
On 2011-12-08 03:56, Manohar Jonnalagedda wrote:
> Hello all,
>
> I was just wondering whether you would have some pointers on how to
> understand the x86 assembly code output by the PrintAssembly flag? My
> question is specifically oriented towards understanding of loops and
> branching instructions. In the output that I get, I have many
> instructions as follows:
>
> B14 : # info about B14
>
> cmpl R10, R10
> jg,s B24
>
> I understand that the above will never go to B24, as the test will
> always be equal. However, by doing such an analysis, I find that there
> the CFG for a given method is much smaller than the overall size of the
> compiled method. Also, some of the branches in this "non-reachable"
> portion of the assembler code contains /inner main loops/ whose /pre
> loops/ are in the reachable portion. How do I actually go about
> understanding such output?
>
> Thanks a lot,
> Manohar
--
Dmitry Samersoff
Java Hotspot development team, SPB04
* There will come soft rains ...
More information about the hotspot-dev
mailing list