<html>
<head>
<base href="http://llvm.org/bugs/" />
</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 --- - Sefault on (corrupted ?) input from the ocaml binding"
href="http://llvm.org/bugs/show_bug.cgi?id=17042">17042</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Sefault on (corrupted ?) input from the ocaml binding
</td>
</tr>
<tr>
<th>Product</th>
<td>tools
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</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>llc
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>jp.deplaix@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>I'm using the Llvm_bitwriter functions to generate the LLVM bitcode and then to
compile it into native assembler using llc.
The thing is: llc segfault with the following backtrace:
0 libLLVM-3.2svn.so 0x00007fb7fbf9862f
1 libLLVM-3.2svn.so 0x00007fb7fbf98989
2 libpthread.so.0 0x00007fb7fafe6210
3 libLLVM-3.2svn.so 0x00007fb7fb79d976
llvm::BitcodeReader::ParseFunctionBody(llvm::Function*) + 10742
4 libLLVM-3.2svn.so 0x00007fb7fb7a28bc
llvm::BitcodeReader::Materialize(llvm::GlobalValue*, std::string*) + 316
5 libLLVM-3.2svn.so 0x00007fb7fb7a29bd
llvm::BitcodeReader::MaterializeModule(llvm::Module*, std::string*) + 77
6 libLLVM-3.2svn.so 0x00007fb7fba2c389
llvm::Module::MaterializeAllPermanently(std::string*) + 9
7 libLLVM-3.2svn.so 0x00007fb7fb7a232c
llvm::ParseBitcodeFile(llvm::MemoryBuffer*, llvm::LLVMContext&, std::string*) +
44
8 llc 0x0000000000412597 llvm::ParseIRFile(std::string const&,
llvm::SMDiagnostic&, llvm::LLVMContext&) + 727
9 llc 0x000000000040e948 main + 2904
10 libc.so.6 0x00007fb7fa231995 __libc_start_main + 245
11 llc 0x000000000040f3cf
Stack dump:
0. Program arguments: llc -
Segmentation fault
The original source is here:
<a href="https://github.com/jpdeplaix/cervoise/tree/051c39797972102d17a5f0deee4f89b3f60ed902">https://github.com/jpdeplaix/cervoise/tree/051c39797972102d17a5f0deee4f89b3f60ed902</a>
If someone wants to test it, this is the command line (after having compiled
the project): ./main.native examples/test.sfw</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>