<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Not sure who owns this bit of code, so sending this to the general
    list.<br>
    <br>
    It looks like there may be an unintentional fall through happening
    in the X86RegisterInfo::getCallPreservedMask function.  <br>
    <br>
    <a class="moz-txt-link-freetext" href="http://llvm.org/docs/doxygen/html/X86RegisterInfo_8cpp_source.html">http://llvm.org/docs/doxygen/html/X86RegisterInfo_8cpp_source.html</a><br>
    <br>
    <pre class="fragment"><span class="keywordflow">case</span> <a class="code" href="http://llvm.org/docs/doxygen/html/namespacellvm_1_1CallingConv.html#a4f861731fc6dbfdccc05af5968d98974ad47327c131a0990283111588b89587cb" title="Intel_OCL_BI - Calling conventions for Intel OpenCL built-ins.">CallingConv::Intel_OCL_BI</a>: {
     <span class="keywordflow">if</span> (IsWin64 && HasAVX512)
       <span class="keywordflow">return</span> CSR_Win64_Intel_OCL_BI_AVX512_RegMask;
     <span class="keywordflow">if</span> (Is64Bit && HasAVX512)
       <span class="keywordflow">return</span> CSR_64_Intel_OCL_BI_AVX512_RegMask;
     <span class="keywordflow">if</span> (IsWin64 && HasAVX)
       <span class="keywordflow">return</span> CSR_Win64_Intel_OCL_BI_AVX_RegMask;
     <span class="keywordflow">if</span> (Is64Bit && HasAVX)
       <span class="keywordflow">return</span> CSR_64_Intel_OCL_BI_AVX_RegMask;
     <span class="keywordflow">if</span> (!HasAVX && !IsWin64 && Is64Bit)
       <span class="keywordflow">return</span> CSR_64_Intel_OCL_BI_RegMask;
     // Missing break/return?
 }</pre>
    It _may_ be intentional - it falls through to the Cold calling
    convention and then general C convention, but it really looks
    suspicious.  <br>
    <br>
    If it is intentional, please add an explicit note about the desired
    fall through behaviour.  I found this by inserting a new case in the
    switch and having tests fail.  The two tests that seem to hit the
    fallthrough behavor are: CodeGen/X86/avx-intel-ocl.ll and
    CodeGen/X86/sse-intel-ocl.ll<br>
    <br>
    Philip<br>
  </body>
</html>