<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 - SEGV in DAGTypeLegalizer::AnalyzeNewNode"
href="https://bugs.llvm.org/show_bug.cgi?id=44546">44546</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>SEGV in DAGTypeLegalizer::AnalyzeNewNode
</td>
</tr>
<tr>
<th>Product</th>
<td>libraries
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Windows NT
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Common Code Generator Code
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>bjorn.a.pettersson@ericsson.com
</td>
</tr>
<tr>
<th>CC</th>
<td>craig.topper@gmail.com, llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=23017" name="attach_23017" title="reduced reproducer">attachment 23017</a> <a href="attachment.cgi?id=23017&action=edit" title="reduced reproducer">[details]</a></span>
reduced reproducer
Got a similar crash as the below for out out-of-tree target.
After reducing the test case a bit I managed to reproduce something that seem
to crash in a similar way (at least the stack trace is the same) for an in-tree
target.
One thing to notice is that there is a
store <4 x i32> %t8, <4 x i32>* null
in the input. But I still think it is unfortunate that we get a crash here.
My debugging session for the out-of-tree target ended up somewhere around the
ReplacedValues map. And it crashed for me if I add a Val.dump in
DAGTypeLegalizer::AnalyzeNewValue after the call to RemapValue.
Here is the stack trace:
<span class="quote">> llc -o - red3.ll -mtriple systemz</span >
.text
.file "red3.ll"
Stack dump:
0. Program arguments: build-all/bin/llc -o - red3.ll -mtriple systemz
1. Running pass 'Function Pass Manager' on module 'red3.ll'.
2. Running pass 'SystemZ DAG->DAG Pattern Instruction Selection' on
function '@foo'
#0 0x00000000023fa194 PrintStackTraceSignalHandler(void*)
(build-all/bin/llc+0x23fa194)
#1 0x00000000023f7d5e llvm::sys::RunSignalHandlers()
(build-all/bin/llc+0x23f7d5e)
#2 0x00000000023fa59c SignalHandler(int) (build-all/bin/llc+0x23fa59c)
#3 0x00007fda6a92d630 __restore_rt (/lib64/libpthread.so.0+0xf630)
#4 0x00000000022bfdc6 llvm::DAGTypeLegalizer::AnalyzeNewNode(llvm::SDNode*)
(build-all/bin/llc+0x22bfdc6)
#5 0x00000000022c23ed llvm::DAGTypeLegalizer::SetSplitVector(llvm::SDValue,
llvm::SDValue, llvm::SDValue) (build-all/bin/llc+0x22c23ed)
#6 0x00000000022d8dea llvm::DAGTypeLegalizer::SplitVectorResult(llvm::SDNode*,
unsigned int) (build-all/bin/llc+0x22d8dea)
#7 0x00000000022bf203 llvm::DAGTypeLegalizer::run()
(build-all/bin/llc+0x22bf203)
#8 0x00000000022c4638 llvm::SelectionDAG::LegalizeTypes()
(build-all/bin/llc+0x22c4638)
#9 0x000000000225c238 llvm::SelectionDAGISel::CodeGenAndEmitDAG()
(build-all/bin/llc+0x225c238)
#10 0x000000000225af91
llvm::SelectionDAGISel::SelectAllBasicBlocks(llvm::Function const&)
(build-all/bin/llc+0x225af91)
#11 0x0000000002257800
llvm::SelectionDAGISel::runOnMachineFunction(llvm::MachineFunction&)
(build-all/bin/llc+0x2257800)
#12 0x0000000001191352 (anonymous
namespace)::SystemZDAGToDAGISel::runOnMachineFunction(llvm::MachineFunction&)
(build-all/bin/llc+0x1191352)
#13 0x00000000019c34a9
llvm::MachineFunctionPass::runOnFunction(llvm::Function&)
(build-all/bin/llc+0x19c34a9)
#14 0x0000000001d57243 llvm::FPPassManager::runOnFunction(llvm::Function&)
(build-all/bin/llc+0x1d57243)
#15 0x0000000001d57528 llvm::FPPassManager::runOnModule(llvm::Module&)
(build-all/bin/llc+0x1d57528)
#16 0x0000000001d57b8d llvm::legacy::PassManagerImpl::run(llvm::Module&)
(build-all/bin/llc+0x1d57b8d)
#17 0x000000000079f4e5 compileModule(char**, llvm::LLVMContext&)
(build-all/bin/llc+0x79f4e5)
#18 0x000000000079cf5d main (build-all/bin/llc+0x79cf5d)
#19 0x00007fda69a24545 __libc_start_main (/lib64/libc.so.6+0x22545)
#20 0x000000000079a8cf _start (build-all/bin/llc+0x79a8cf)
Segmentation fault</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>