<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 - Cannot select: 0xe87fb38: i32,ch = AtomicLoadMax"
   href="https://bugs.llvm.org/show_bug.cgi?id=42415">42415</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Cannot select: 0xe87fb38: i32,ch = AtomicLoadMax
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>libraries
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>8.0
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Other
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </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>Backend: MIPS
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>zhaixiang@loongson.cn
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=22147" name="attach_22147" title="/tmp/Atomics-bafc90.c">attachment 22147</a> <a href="attachment.cgi?id=22147&action=edit" title="/tmp/Atomics-bafc90.c">[details]</a></span>
/tmp/Atomics-bafc90.c

Hi,

$ clang++ -S -c llvm-project/clang/test/CodeGen/Atomics.c -o Atomics.S
clang-8: warning: treating 'c' input as 'c++' when in C++ mode, this behavior
is deprecated [-Wdeprecated]
llvm-project/clang/test/CodeGen/Atomics.c:52:39: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&sc, 1); // CHECK: atomicrmw nand i8
         ~~~~~~~~~~~~~~~~~~~~~        ^
llvm-project/clang/test/CodeGen/Atomics.c:53:39: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&uc, 1); // CHECK: atomicrmw nand i8
         ~~~~~~~~~~~~~~~~~~~~~        ^
llvm-project/clang/test/CodeGen/Atomics.c:54:39: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&ss, 1); // CHECK: atomicrmw nand i16
         ~~~~~~~~~~~~~~~~~~~~~        ^
llvm-project/clang/test/CodeGen/Atomics.c:55:39: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&us, 1); // CHECK: atomicrmw nand i16
         ~~~~~~~~~~~~~~~~~~~~~        ^
llvm-project/clang/test/CodeGen/Atomics.c:56:39: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&si, 1); // CHECK: atomicrmw nand i32
         ~~~~~~~~~~~~~~~~~~~~~        ^
llvm-project/clang/test/CodeGen/Atomics.c:57:39: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&ui, 1); // CHECK: atomicrmw nand i32
         ~~~~~~~~~~~~~~~~~~~~~        ^
llvm-project/clang/test/CodeGen/Atomics.c:58:40: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&sll, 1); // CHECK: atomicrmw nand i64
         ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:59:40: warning: the semantics of this
intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  (void) __sync_fetch_and_nand (&ull, 1); // CHECK: atomicrmw nand i64
         ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:110:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  sc = __sync_fetch_and_nand (&sc, 11); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:111:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  uc = __sync_fetch_and_nand (&uc, 11); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:112:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  ss = __sync_fetch_and_nand (&ss, 11); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:113:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  us = __sync_fetch_and_nand (&us, 11); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:114:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  si = __sync_fetch_and_nand (&si, 11); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:115:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  ui = __sync_fetch_and_nand (&ui, 11); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:116:40: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  sll = __sync_fetch_and_nand (&sll, 11); // CHECK: atomicrmw nand
        ~~~~~~~~~~~~~~~~~~~~~          ^
llvm-project/clang/test/CodeGen/Atomics.c:117:40: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
        ~~~~~~~~~~~~~~~~~~~~~          ^
llvm-project/clang/test/CodeGen/Atomics.c:168:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  sc = __sync_nand_and_fetch (&sc, uc); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:171:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  uc = __sync_nand_and_fetch (&uc, uc); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:174:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  ss = __sync_nand_and_fetch (&ss, uc); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:177:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  us = __sync_nand_and_fetch (&us, uc); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:180:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  si = __sync_nand_and_fetch (&si, uc); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:183:38: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  ui = __sync_nand_and_fetch (&ui, uc); // CHECK: atomicrmw nand
       ~~~~~~~~~~~~~~~~~~~~~         ^
llvm-project/clang/test/CodeGen/Atomics.c:186:40: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  sll = __sync_nand_and_fetch (&sll, uc); // CHECK: atomicrmw nand
        ~~~~~~~~~~~~~~~~~~~~~          ^
llvm-project/clang/test/CodeGen/Atomics.c:189:40: warning: the semantics of
this intrinsic changed with GCC version 4.4 - the
      newer semantics are provided here
[-Wsync-fetch-and-nand-semantics-changed]
  ull = __sync_nand_and_fetch (&ull, uc); // CHECK: atomicrmw nand
        ~~~~~~~~~~~~~~~~~~~~~          ^
fatal error: error in backend: Cannot select: 0xe87fb38: i32,ch =
AtomicLoadMax<(volatile load store monotonic 4 on @si)>
      0xe882f88, 0xe8d3b08, 0xe880970
  0xe8d3b08: i64,ch = load<(load 8 from got)> 0xe820da8, 0xe8a0b58, undef:i64
    0xe8a0b58: i64 = MipsISD::Wrapper Register:i64 %0,
TargetGlobalAddress:i64<i32* @si> 0 [TF=15]
      0xe8805c8: i64 = Register %0
      0xe8d40b8: i64 = TargetGlobalAddress<i32* @si> 0 [TF=15]
    0xe8d0dc0: i64 = undef
  0xe880970: i32,ch = load<(dereferenceable load 4 from %ir.7)> 0xe8d3f18,
FrameIndex:i64<6>, undef:i64
    0xe882eb8: i64 = FrameIndex<6>
    0xe8d0dc0: i64 = undef
In function: _Z11test_atomicv
clang-8: error: clang frontend command failed with exit code 70 (use -v to see
invocation)
clang version 8.0.0 
Target: mips64el-redhat-linux
Thread model: posix
InstalledDir: /usr/bin
clang-8: note: diagnostic msg: PLEASE submit a bug report to
<a href="https://bugs.llvm.org/">https://bugs.llvm.org/</a> and include the crash backtrace, preprocessed source,
and associated run script.
clang-8: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang-8: note: diagnostic msg: /tmp/Atomics-bafc90.c
clang-8: note: diagnostic msg: /tmp/Atomics-bafc90.sh
clang-8: note: diagnostic msg: 

********************


Thanks,
Leslie Zhai</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>