<html>
<head>
<base href="https://llvm.org/bugs/" />
</head>
<body><span class="vcard"><a class="email" href="mailto:danielcdh@gmail.com" title="Dehao Chen <danielcdh@gmail.com>"> <span class="fn">Dehao Chen</span></a>
</span> changed
<a class="bz_bug_link
bz_status_REOPENED "
title="REOPENED --- - Debug info not maintained in AutoFDO"
href="https://llvm.org/bugs/show_bug.cgi?id=25482">bug 25482</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">Status</td>
<td>RESOLVED
</td>
<td>REOPENED
</td>
</tr>
<tr>
<td style="text-align:right;">Resolution</td>
<td>FIXED
</td>
<td>---
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_REOPENED "
title="REOPENED --- - Debug info not maintained in AutoFDO"
href="https://llvm.org/bugs/show_bug.cgi?id=25482#c6">Comment # 6</a>
on <a class="bz_bug_link
bz_status_REOPENED "
title="REOPENED --- - Debug info not maintained in AutoFDO"
href="https://llvm.org/bugs/show_bug.cgi?id=25482">bug 25482</a>
from <span class="vcard"><a class="email" href="mailto:danielcdh@gmail.com" title="Dehao Chen <danielcdh@gmail.com>"> <span class="fn">Dehao Chen</span></a>
</span></b>
<pre>The inline stack is still not maintained correctly in this bug. Here is how to
reproduce:
#bin/clang++ -c -fprofile-sample-use=c.txt -O2 -save-temps -v c.cc
#bin/opt -sample-profile -sample-profile-file=c.txt c.bc -S|bin/opt -analyze
-branch-prob
Printing analysis 'Branch Probability Analysis' for function '_Z3foov':
---- Branch Probabilities ----
edge entry -> if.then.i probability is 0x50000000 / 0x80000000 = 62.50%
edge entry -> if.else.i probability is 0x30000000 / 0x80000000 = 37.50%
edge if.then.i -> _ZL3barv.exit probability is 0x80000000 / 0x80000000 =
100.00% [HOT edge]
edge if.else.i -> _ZL3barv.exit probability is 0x80000000 / 0x80000000 =
100.00% [HOT edge]
Printing analysis 'Branch Probability Analysis' for function '_ZL3barv':
---- Branch Probabilities ----
edge entry -> if.then probability is 0x50000000 / 0x80000000 = 62.50%
edge entry -> if.else probability is 0x30000000 / 0x80000000 = 37.50%
edge if.then -> if.end probability is 0x80000000 / 0x80000000 = 100.00% [HOT
edge]
edge if.else -> if.end probability is 0x80000000 / 0x80000000 = 100.00% [HOT
edge]
#bin/clang++ -c -fprofile-sample-use=c.txt -O2 -save-temps -v c.cc -g
#bin/opt -sample-profile -sample-profile-file=c.txt c.bc -S|bin/opt -analyze
-branch-prob
Printing analysis 'Branch Probability Analysis' for function '_Z3foov':
---- Branch Probabilities ----
edge entry -> if.then.i probability is 0x00000000 / 0x80000000 = 0.00%
edge entry -> if.else.i probability is 0x80000000 / 0x80000000 = 100.00% [HOT
edge]
edge if.then.i -> _ZL3barv.exit probability is 0x80000000 / 0x80000000 =
100.00% [HOT edge]
edge if.else.i -> _ZL3barv.exit probability is 0x80000000 / 0x80000000 =
100.00% [HOT edge]
Printing analysis 'Branch Probability Analysis' for function '_ZL3barv':
---- Branch Probabilities ----
edge entry -> if.then probability is 0x50000000 / 0x80000000 = 62.50%
edge entry -> if.else probability is 0x30000000 / 0x80000000 = 37.50%
edge if.then -> if.end probability is 0x80000000 / 0x80000000 = 100.00% [HOT
edge]
edge if.else -> if.end probability is 0x80000000 / 0x80000000 = 100.00% [HOT
edge]
With and without "-g", branch-probability gives different branch probability
estimation for _Z3foov.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>