<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 - Tiny program crashes "X86 DAG->DAG Instruction Selection", likely related to AVX512"
   href="https://bugs.llvm.org/show_bug.cgi?id=49113">49113</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Tiny program crashes "X86 DAG->DAG Instruction Selection", likely related to AVX512
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>10.0
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </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>Backend: X86
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>wenzel.jakob@epfl.ch
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>craig.topper@gmail.com, llvm-bugs@lists.llvm.org, llvm-dev@redking.me.uk, pengfei.wang@intel.com, spatel+llvm@rotateright.com
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Dear all,

I've run into a persistent LLVM crash during instruction selection that
bugpoint was able to narrow down to the following few lines. FWIW this is with
LLVM 10.0.0. Interestingly, the problem disappears when changing the target
from "skylake-avx512" to just "skylake".

-----------------------------

; ModuleID = 'bugpoint-reduced-simplified.bc'
source_filename = "test.ll"
target triple = "x86_64-pc-linux-gnu"

define void @func() #0 {
entry:
  %p1_0 = load <8 x i8>, <8 x i8>* undef, align 8
  %p1 = trunc <8 x i8> %p1_0 to <8 x i1>
  %p3 = select <8 x i1> %p1, <8 x i1> zeroinitializer, <8 x i1> %p1
  %p3_e = zext <8 x i1> %p3 to <8 x i8>
  store <8 x i8> %p3_e, <8 x i8>* undef, align 8
  unreachable
}

attributes #0 = { "target-cpu"="skylake-avx512" }

-----------------------------

Stack dump:                                                                     
0.      Program arguments: llc-10 bugpoint-reduced-simplified.ll                
1.      Running pass 'Function Pass Manager' on module
'bugpoint-reduced-simplified.ll'.                                               
2.      Running pass 'X86 DAG->DAG Instruction Selection' on function '@func'   
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm3sys15PrintStackTraceERNS_11raw_ostreamE+0x1f)[0x7fd0356c54ff] 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm3sys17RunSignalHandlersEv+0x50)[0x7fd0356c37b0] 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(+0x981ac5)[0x7fd0356c5ac5]                
/lib/x86_64-linux-gnu/libpthread.so.0(+0x153c0)[0x7fd034d363c0]                 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZNK4llvm3EVT23isExtendedScalarIntegerEv+0x4)[0x7fd035af6514] 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(+0x275550c)[0x7fd03749950c]               
/lib/x86_64-linux-gnu/libLLVM-10.so.1(+0xdc4125)[0x7fd035b08125]                
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm12SelectionDAG7CombineENS_12CombineLevelEPNS_9AAResultsENS_10CodeGenOpt5LevelE+0x939)[0x7fd035b069f9] 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm16SelectionDAGISel17CodeGenAndEmitDAGEv+0xe2)[0x7fd035ca9ea2] 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm16SelectionDAGISel20SelectAllBasicBlocksERKNS_8FunctionE+0x1957)[0x7fd035ca9a07] 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm16SelectionDAGISel20runOnMachineFunctionERNS_15MachineFunctionE+0x796)[0x7fd035ca7396] 
/lib/x86_64-linux-gnu/libLLVM-10.so.1(+0x26b4e18)[0x7fd0373f8e18]               
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE+0x118)[0x7fd0359605e8]
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x466)[0x7fd0357cad76]
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE+0x33)[0x7fd0357caff3]
/lib/x86_64-linux-gnu/libLLVM-10.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x3c0)[0x7fd0357cb4a0]
llc-10[0x4196e7]
llc-10(main+0x3fd)[0x416acd]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3)[0x7fd03480b0b3]
llc-10(_start+0x2e)[0x415a7e]</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>