[PATCH] Fix PR 23525 - Separate header mass propagation in irregular loops.
Diego Novillo
dnovillo at google.com
Tue Jun 9 15:07:02 PDT 2015
Hi dexonsmith,
When propagating mass through irregular loops, the mass flowing through
each loop header may not be equal. This was causing wrong frequencies
to be computed for irregular loop headers.
Fixed by keeping track of masses flowing through each of the headers in
an irregular loop. To do this, we now keep track of per-header backedge
weights. After the loop mass is distributed through the loop, the
backedge weights are used to re-distribute the loop mass to the loop
headers.
Since each backedge will have a mass proportional to the different
branch weights, the loop headers will end up with a more approximate
weight distribution (as opposed to the current distribution that assumes
that every loop header is the same).
http://reviews.llvm.org/D10348
Files:
include/llvm/Analysis/BlockFrequencyInfoImpl.h
lib/Analysis/BlockFrequencyInfoImpl.cpp
test/Analysis/BlockFrequencyInfo/PR23525.ll
test/Analysis/BlockFrequencyInfo/irreducible.ll
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D10348.27407.patch
Type: text/x-patch
Size: 11143 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150609/6b9c32e4/attachment.bin>
More information about the llvm-commits
mailing list