<html>
    <head>
      <base href="https://llvm.org/bugs/" />
    </head>
    <body><span class="vcard"><a class="email" href="mailto:spatel+llvm@rotateright.com" title="Sanjay Patel <spatel+llvm@rotateright.com>"> <span class="fn">Sanjay Patel</span></a>
</span> changed
              <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED FIXED - constant function parameter is set to existing value"
   href="https://llvm.org/bugs/show_bug.cgi?id=28957">bug 28957</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>NEW
           </td>
           <td>RESOLVED
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">CC</td>
           <td>
                
           </td>
           <td>james.molloy@arm.com
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Resolution</td>
           <td>---
           </td>
           <td>FIXED
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED FIXED - constant function parameter is set to existing value"
   href="https://llvm.org/bugs/show_bug.cgi?id=28957#c3">Comment # 3</a>
              on <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED FIXED - constant function parameter is set to existing value"
   href="https://llvm.org/bugs/show_bug.cgi?id=28957">bug 28957</a>
              from <span class="vcard"><a class="email" href="mailto:spatel+llvm@rotateright.com" title="Sanjay Patel <spatel+llvm@rotateright.com>"> <span class="fn">Sanjay Patel</span></a>
</span></b>
        <pre>Thanks, Zvi! This is now optimized differently in IR:

define i32 @foo(i32 %x) local_unnamed_addr #0 {
entry:
  %cmp = icmp eq i32 %x, 1
  %.sink = select i1 %cmp, i32 1, i32 -1
  %call1 = tail call i32 @bar(i32 %.sink) #2
  ret i32 %call1
}

declare i32 @bar(i32) local_unnamed_addr #1
-------------------------------------------------------------------------

This is likely due to one of James Molloy's (cc'ing) improvements to
SimplifyCFG. <a href="https://reviews.llvm.org/D22143">https://reviews.llvm.org/D22143</a> ?

Resolving as fixed.</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>