[llvm] r200219 - [vectorize] Initial version of respecting PGO in	the vectorizer: treat
    Chandler Carruth 
    chandlerc at gmail.com
       
    Mon Jan 27 13:41:39 PST 2014
    
    
  
On Mon, Jan 27, 2014 at 1:06 PM, Arnold Schwaighofer <
aschwaighofer at apple.com> wrote:
> Hi Chandler,
>
> This change makes the unroller/vectorizer more conservative when used with
> static BFI. We will not unroll (after handling conditional stores) the
> hottest loop “quantum_toffoli” in libquantum (50% or so) using the static
> heuristic:
>
Well... That's really surprising... That was not the intent here at all
(clearly).
>
>
> http://sourcecodebrowser.com/libquantum/0.2.4/gates_8c_source.html#l00082
>
> Best,
> Arnold
>
>
>
>
> ---- Block Freqs ----
>  entry = 1.0
>   entry -> if.else = 0.375
>   entry -> if.then = 0.625
>  if.then = 0.625
>   if.then -> if.end22 = 0.625
>  if.else = 0.375
>   if.else -> for.cond.preheader = 0.1406
>   if.else -> if.end22 = 0.23437
>  for.cond.preheader = 0.1406
>   for.cond.preheader -> for.body.lr.ph = 0.08789
>   for.cond.preheader -> for.end = 0.05273
>  for.body.lr.ph = 0.08789                   ### Preheader in question
>   for.body.lr.ph -> for.body = 0.08789
>  for.body = 2.8125                          ### Loop in question
>
Oh goodness. These static frequencies don't really make any sense at all.
But they're also not wrong at all. ARRRRG!
Looks like we can't use a simple heuristics here even for cold regions. Do
you have any better suggestions for what constitutes a cold region? Perhaps
our static heuristics are also more deeply flawed than previously believed?
I'll try to think of something significantly more conservative or turn this
off shortly.... this is not the intended behavior here clearly.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140127/090a27ee/attachment.html>
    
    
More information about the llvm-commits
mailing list