<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </head>
    <body><span class="vcard"><a class="email" href="mailto:sohachak@mpi-sws.org" title="soham <sohachak@mpi-sws.org>"> <span class="fn">soham</span></a>
</span> changed
              <a class="bz_bug_link 
          bz_status_REOPENED "
   title="REOPENED --- - Wrong transformation due to semantic gap between C11 and LLVM semantics"
   href="http://llvm.org/bugs/show_bug.cgi?id=22514">bug 22514</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>INVALID
           </td>
           <td>---
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_REOPENED "
   title="REOPENED --- - Wrong transformation due to semantic gap between C11 and LLVM semantics"
   href="http://llvm.org/bugs/show_bug.cgi?id=22514#c2">Comment # 2</a>
              on <a class="bz_bug_link 
          bz_status_REOPENED "
   title="REOPENED --- - Wrong transformation due to semantic gap between C11 and LLVM semantics"
   href="http://llvm.org/bugs/show_bug.cgi?id=22514">bug 22514</a>
              from <span class="vcard"><a class="email" href="mailto:sohachak@mpi-sws.org" title="soham <sohachak@mpi-sws.org>"> <span class="fn">soham</span></a>
</span></b>
        <pre>In the source program 

x = 1 => x.store(1,std::memory_order_seq_cst) and
x == 1 => x.load(std::memory_order_seq_cst) == 1

The R_sc(X,1) in readA() reads-from W_sc(X,1) in writeA() which results in
synchronization and W_na(a,42) happens-before R_na(a,42) and thus synchronized. 
If (x==1) test fails then W(x) and R(x) is not synchronized and in that case
R_na(a) does not take place.

Thus the source program is race free.</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>