[llvm-bugs] [Bug 32284] New: Assertion `Num < NumOperands && "Invalid child # of SDNode!"' failed with -O0 -march=skx.

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Mar 15 10:59:16 PDT 2017


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

            Bug ID: 32284
           Summary: Assertion `Num < NumOperands && "Invalid child # of
                    SDNode!"' failed with -O0 -march=skx.
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: Vsevolod.Livinskij at frtk.ru
                CC: llvm-bugs at lists.llvm.org

Created attachment 18097
  --> https://bugs.llvm.org/attachment.cgi?id=18097&action=edit
Reproducer.

Clang fails assertion during pass 'X86 DAG->DAG Instruction Selection' with -O0
-march=skx.

Reproducer:
extern const unsigned char c;

void foo() {
  bool a = char(-long(-c));
  int b = !!c <= c;
}

Error:
>$ clang++ -O0 -march=skx -c repr.cpp
llvm-trunk/include/llvm/CodeGen/SelectionDAGNodes.h:746: const llvm::SDValue&
llvm::SDNode::getOperand(unsigned int) const: Assertion `Num < NumOperands &&
"Invalid child # of SDNode!"' failed.
(......)
1.      <eof> parser at end of file
2.      Code generation
3.      Running pass 'Function Pass Manager' on module 'repr.cpp'.
4.      Running pass 'X86 DAG->DAG Instruction Selection' on function
'@_Z3foov'
clang-5.0: error: unable to execute command: Aborted (core dumped)


LLVM version:
clang version 5.0.0 (trunk 297835)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /home/vsevolod/workspace/llvm/bin-trunk/bin
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/5.4.0
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/6.0.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.4.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/6.0.0
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/5.4.0
Candidate multilib: .;@m64
Candidate multilib: 32;@m32
Candidate multilib: x32;@mx32
Selected multilib: .;@m64

There are exist several bugs with same assertion, but they all were fixed:
https://bugs.llvm.org//show_bug.cgi?id=10527
https://bugs.llvm.org//show_bug.cgi?id=10068
https://bugs.llvm.org//show_bug.cgi?id=10689

And one more, marked as new:
https://bugs.llvm.org//show_bug.cgi?id=25330

-- 
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/20170315/fda3b0a2/attachment.html>


More information about the llvm-bugs mailing list