[llvm-bugs] [Bug 52276] New: wrong code at -O1, -Os and -O2 (but not -O3) on x86_64-linux-gnu (generated code hangs)

via llvm-bugs llvm-bugs at lists.llvm.org
Sat Oct 23 13:42:30 PDT 2021


https://bugs.llvm.org/show_bug.cgi?id=52276

            Bug ID: 52276
           Summary: wrong code at -O1, -Os and -O2 (but not -O3) on
                    x86_64-linux-gnu (generated code hangs)
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: zhendong.su at inf.ethz.ch
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org

This appears to be a recent regression.

[679] % clangtk -v
clang version 14.0.0 (https://github.com/llvm/llvm-project.git
2410fb4616b2c08bbaddd44e6c11da8285fbd1d3)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /local/suz-local/opfuzz/bin
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/8
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6.5.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/7
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/7.5.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/8
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/7.5.0
Candidate multilib: .;@m64
Selected multilib: .;@m64
[680] % 
[680] % clangtk -O0 small.c; ./a.out
[681] % 
[681] % clangtk -O1 small.c
[682] % timeout -s 9 10 ./a.out
Killed
[683] % 
[683] % cat small.c
int a, b;
int main() {
  while ((a > 0) < ~a)
    b++;
  return 0;
}

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20211023/c28343a6/attachment.html>


More information about the llvm-bugs mailing list