<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </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 INVALID - Clang frontend command failed with exit code 70 when compiling BearSSL"
   href="https://bugs.llvm.org/show_bug.cgi?id=36060">bug 36060</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;">Resolution</td>
           <td>---
           </td>
           <td>INVALID
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">See Also</td>
           <td>
                
           </td>
           <td>https://bugs.llvm.org/show_bug.cgi?id=24125
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Status</td>
           <td>NEW
           </td>
           <td>RESOLVED
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED INVALID - Clang frontend command failed with exit code 70 when compiling BearSSL"
   href="https://bugs.llvm.org/show_bug.cgi?id=36060#c6">Comment # 6</a>
              on <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED INVALID - Clang frontend command failed with exit code 70 when compiling BearSSL"
   href="https://bugs.llvm.org/show_bug.cgi?id=36060">bug 36060</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>
(In reply to Alexej Harm from <a href="show_bug.cgi?id=36060#c5">comment #5</a>)
<span class="quote">> Adding "-msse3 -mssse3 -msse4.1 -msse4.2" solved the problem. This was 100%
> my fault.

> If it is technically possible to make the error message a bit clearer, I
> would suggest that it's a good idea to do so.</span >

This is a long-standing problem when compiling x86 intrinsics (see <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED FIXED - ICE when calling intrinsic _mm_cvtps_ph causes"
   href="show_bug.cgi?id=24125">bug 24125</a>
and related bugs).

We do get this right in the simple case:

$ cat pshuf.c 
#include <immintrin.h>

__m128i need_ssse3(__m128i x, __m128i idx) {
    return _mm_shuffle_epi8(x, idx);
}

$ clang -O1 pshuf.c -S -o - -mno-ssse3
pshuf.c:4:12: error: always_inline function '_mm_shuffle_epi8' requires target
feature 'ssse3', but would be inlined into function 'need_ssse3' that is
compiled without
      support for 'ssse3'
    return _mm_shuffle_epi8(x, idx);

--------------------------------------------------------------------------

I don't think there's anything more we can do in the example you've used
(overriding the features via defines in your source code), so I'm marking this
as invalid. Feel free to reopen if you disagree.</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>