<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - __builtin_rotateright64 signature dropped 'unsigned' on last parameter in Clang 9"
   href="https://bugs.llvm.org/show_bug.cgi?id=43309">43309</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>__builtin_rotateright64 signature dropped 'unsigned' on last parameter in Clang 9
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>9.0
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Frontend
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>mprice@synopsys.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org, neeilans@live.com, richard-llvm@metafoo.co.uk
          </td>
        </tr></table>
      <p>
        <div>
        <pre>The signature for __builtin_rotateright64 changed in a way that looks
suspicious.

BUILTIN(__builtin_rotateleft8, "UcUcUc", "nc")
BUILTIN(__builtin_rotateleft16, "UsUsUs", "nc")
BUILTIN(__builtin_rotateleft32, "UZiUZiUZi", "nc")
BUILTIN(__builtin_rotateleft64, "UWiUWiUWi", "nc")
BUILTIN(__builtin_rotateright8, "UcUcUc", "nc")
BUILTIN(__builtin_rotateright16, "UsUsUs", "nc")
BUILTIN(__builtin_rotateright32, "UZiUZiUZi", "nc")
BUILTIN(__builtin_rotateright64, "UWiUWiWi", "nc")   // All the other rotate
builtins have a last parameter that is unsigned, and it did before this most
recent change to this line.


It appears to have happened in this commit:

commit c0478341937c33b16056e9ce28d6134afbd91693
Author: Karl-Johan Karlsson <<a href="mailto:karl-johan.karlsson@ericsson.com">karl-johan.karlsson@ericsson.com</a>>
Date:   2019-05-16 07:18:02 +0000

    [builtin] Fixed definitions of builtins that rely on the int/long long type
is 32/64 bits

    Summary:
    The definition of the builtins __builtin_bswap32, __builtin_bitreverse32,
__builtin_rotateleft32 and __builtin_rotateright32 rely on that the int type is
32 bits wide on the target.
    The defintions of the builtins __builtin_bswap64, __builtin_bitreverse64,
__builtin_rotateleft64, and __builtin_rotateright64 rely on that the long long
type is 64 bits wide.

    On targets where this is not the case (e.g. AVR) clang will generate faulty
code (wrong llvm assembler intrinsics).

    This patch add support for using 'Z' (the int32_t type) in Bultins.def. The
builtins above are changed to be based on the int32_t type instead of the int
type, and the int64_t type instead of the long long type.

    The AVR backend (experimental) have a native int type that is only 16 bits
wide. The supplied testcase will therefore fail if running the testcase on
trunk as clang will convert e.g. __builtin_bitreverse32 into
llvm.bitreverse.i16 on AVR.

    Reviewers: dylanmckay, spatel, rsmith, efriedma

    Reviewed By: efriedma

    Differential Revision: <a href="https://reviews.llvm.org/D61845">https://reviews.llvm.org/D61845</a>

    git-svn-id: <a href="https://llvm.org/svn/llvm-project/cfe/trunk@360863">https://llvm.org/svn/llvm-project/cfe/trunk@360863</a>
91177308-0d34-0410-b5e6-96231b3b80d8</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>