2004-11-01 10:21:32 +01:00
|
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
|
2004-02-27 07:28:34 +01:00
|
|
|
<html>
|
|
|
|
<head>
|
2004-11-01 00:00:25 +01:00
|
|
|
<title>Using The LLVM Libraries</title>
|
2004-02-27 07:28:34 +01:00
|
|
|
<link rel="stylesheet" href="llvm.css" type="text/css">
|
|
|
|
</head>
|
|
|
|
<body>
|
2004-11-01 00:00:25 +01:00
|
|
|
<div class="doc_title">Using The LLVM Libraries</div>
|
2004-02-27 07:28:34 +01:00
|
|
|
<ol>
|
|
|
|
<li><a href="#abstract">Abstract</a></li>
|
|
|
|
<li><a href="#introduction">Introduction</a></li>
|
2004-11-01 00:00:25 +01:00
|
|
|
<li><a href="#descriptions">Library Descriptions</a></li>
|
2004-12-31 00:12:04 +01:00
|
|
|
<li><a href="#dependencies">Library Dependencies</a></li>
|
2004-02-27 07:28:34 +01:00
|
|
|
<li><a href="#rot">Linkage Rules Of Thumb</a>
|
|
|
|
<ol>
|
2004-11-01 00:24:31 +01:00
|
|
|
<li><a href="#always">Always link LLVMCore, LLVMSupport, LLVMSystem</a>
|
|
|
|
<li><a href="#onlyone">Never link both archive and re-linked</a>
|
2004-02-27 07:28:34 +01:00
|
|
|
</ol>
|
|
|
|
</li>
|
|
|
|
</ol>
|
2004-05-23 23:07:27 +02:00
|
|
|
|
|
|
|
<div class="doc_author">
|
|
|
|
<p>Written by <a href="mailto:rspencer@x10sys.com">Reid Spencer</a></p>
|
2004-02-27 07:28:34 +01:00
|
|
|
</div>
|
2004-05-23 23:07:27 +02:00
|
|
|
|
2004-02-27 07:28:34 +01:00
|
|
|
<!-- ======================================================================= -->
|
|
|
|
<div class="doc_section"><a name="abstract">Abstract</a></div>
|
|
|
|
<div class="doc_text">
|
2004-11-01 00:00:25 +01:00
|
|
|
<p>Amongst other things, LLVM is a toolkit for building compilers, linkers,
|
|
|
|
runtime executives, virtual machines, and other program execution related
|
|
|
|
tools. In addition to the LLVM tool set, the functionality of LLVM is
|
|
|
|
available through a set of libraries. To use LLVM as a toolkit for
|
|
|
|
constructing tools, a developer needs to understand what is contained in the
|
|
|
|
various libraries, what they depend on, and how to use them. This document
|
|
|
|
describes the contents of the libraries and how and when to use them.
|
2004-02-27 07:28:34 +01:00
|
|
|
</p>
|
|
|
|
</div>
|
2004-11-01 00:00:25 +01:00
|
|
|
|
2004-02-27 07:28:34 +01:00
|
|
|
<!-- ======================================================================= -->
|
|
|
|
<div class="doc_section"> <a name="introduction">Introduction</a></div>
|
|
|
|
<div class="doc_text">
|
2004-11-01 00:00:25 +01:00
|
|
|
<p>If you're writing a compiler, virtual machine, or any other utility based
|
|
|
|
on LLVM, you'll need to figure out which of the many libraries files you will
|
|
|
|
need to link with to be successful. An understanding of the contents of these
|
|
|
|
files and their inter-relationships will be useful in coming up with an optimal
|
|
|
|
specification for the libraries to link with. The purpose of this document is
|
|
|
|
to reduce some of the trial and error that the author experienced in using
|
|
|
|
LLVM.</p>
|
|
|
|
<p>LLVM produces two types of libraries: archives (ending in <tt>.a</tt>) and
|
|
|
|
objects (ending in <tt>.o</tt>). However, both are libraries. Libraries ending
|
|
|
|
in <tt>.o</tt> are known as re-linked libraries because they contain all the
|
|
|
|
compilation units of the library linked together as a single <tt>.o</tt> file.
|
|
|
|
Furthermore, many of the libraries have <em>both</em> forms of library. The
|
|
|
|
re-linked libraries are used whenever you want to include all symbols from the
|
|
|
|
library. The archive libraries are used whenever you want to only resolve
|
|
|
|
outstanding symbols at that point in the link without including everything in
|
|
|
|
the library. </p>
|
|
|
|
<p>When linking your tools, you will use the <tt>LLVMLIBS</tt> make variable.
|
|
|
|
(see the <a href="MakefileGuide.html#LLVMLIBS">Makefile Guide</a> for
|
|
|
|
details). This variable specifies which LLVM libraries to link into your tool
|
|
|
|
and the order in which they will be linked. You specify re-linked libraries by
|
|
|
|
naming the library without a suffix. You specify archive libraries by naming
|
|
|
|
the library with a <tt>.a</tt> suffix but without the <tt>lib</tt> prefix. The
|
|
|
|
order in which the libraries appear in the <tt>LLVMLIBS</tt> variable
|
|
|
|
definition is the order in which they will be linked. Getting this order
|
|
|
|
correct for your tool can sometimes be challenging.
|
2004-02-27 07:28:34 +01:00
|
|
|
</div>
|
|
|
|
<!-- ======================================================================= -->
|
2004-11-01 00:00:25 +01:00
|
|
|
<div class="doc_section"><a name="descriptions"></a>Library Descriptions</div>
|
2004-02-27 07:28:34 +01:00
|
|
|
<div class="doc_text">
|
2004-11-01 00:00:25 +01:00
|
|
|
<p>The table below categorizes each library
|
|
|
|
<table style="text-align:left">
|
|
|
|
<tr><th>Library</th><th>Forms</th><th>Description</th></tr>
|
2004-11-01 10:22:49 +01:00
|
|
|
<tr><th colspan="3">Core Libraries</th></tr>
|
2004-12-31 01:13:14 +01:00
|
|
|
<tr><td>LLVMArchive</td><td><tt>.a</tt></td>
|
|
|
|
<td>LLVM archive reading and writing</td></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMAsmParser</td><td><tt>.o</tt></td>
|
2004-12-31 01:13:14 +01:00
|
|
|
<td>LLVM assembly parsing</td></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMBCReader</td><td><tt>.o</tt></td>
|
2004-12-31 01:13:14 +01:00
|
|
|
<td>LLVM bytecode reading</td></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMBCWriter</td><td><tt>.o</tt></td>
|
2004-12-31 01:13:14 +01:00
|
|
|
<td>LLVM bytecode writing</td></tr>
|
|
|
|
<tr><td>LLVMCore</td><td><tt>.o</tt></td>
|
|
|
|
<td>LLVM core intermediate representation</td></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMDebugger</td><td><tt>.o</tt></td>
|
2004-12-31 01:13:14 +01:00
|
|
|
<td>Source level debugging support</td></tr>
|
|
|
|
<tr><td>LLVMLinker</td><td><tt>.a</tt></td>
|
|
|
|
<td>Bytecode and archive linking interface</td></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMSupport</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>General support utilities</td></tr>
|
|
|
|
<tr><td>LLVMSystem</td><td><tt>.a .o</tt></td>
|
2004-12-31 01:13:14 +01:00
|
|
|
<td>Operating system abstraction layer</td></tr>
|
2004-11-01 00:00:25 +01:00
|
|
|
|
2004-11-01 10:22:49 +01:00
|
|
|
<tr><th colspan="3">Analysis Libraries</th></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMAnalysis</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Various analysis passes.</td></tr>
|
|
|
|
<tr><td>LLVMDataStructure</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Data structure analysis passes.</td></tr>
|
|
|
|
<tr><td>LLVMipa</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Inter-procedural analysis passes.</td></tr>
|
2004-11-01 00:00:25 +01:00
|
|
|
|
2004-11-01 10:22:49 +01:00
|
|
|
<tr><th colspan="3">Transformation Libraries</th></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMInstrumentation</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Instrumentation passes.</td></tr>
|
|
|
|
<tr><td>LLVMipo</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>All inter-procedural optimization passes.</td></tr>
|
|
|
|
<tr><td>LLVMScalarOpts</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>All scalar optimization passes.</td></tr>
|
|
|
|
<tr><td>LLVMTransforms</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Uncategorized transformation passes.</td></tr>
|
|
|
|
<tr><td>LLVMTransformUtils</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Transformation utilities.</td></tr>
|
|
|
|
<tr><td>LLVMProfilePaths</td><td><tt>.o</tt></td>
|
|
|
|
<td>Profile paths for instrumentation.</td></tr>
|
2004-11-01 00:00:25 +01:00
|
|
|
|
2004-11-01 10:22:49 +01:00
|
|
|
<tr><th colspan="3">Code Generation Libraries </th></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMCodeGen</td><td><tt>.o</tt></td>
|
|
|
|
<td>Native code generation infrastructure</td></tr>
|
2004-11-01 00:00:25 +01:00
|
|
|
|
2004-11-01 10:22:49 +01:00
|
|
|
<tr><th colspan="3">Target Libraries</th></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMCBackend</td><td><tt>.o</tt></td>
|
|
|
|
<td>'C' language code generator.</td></tr>
|
|
|
|
<tr><td>LLVMPowerPC</td><td><tt>.o</tt></td>
|
|
|
|
<td>PowerPC code generation backend</td></tr>
|
|
|
|
<tr><td>LLVMSelectionDAG</td><td><tt>.o</tt></td>
|
2004-12-31 01:13:14 +01:00
|
|
|
<td>Aggressive instruction selector for directed acyclic graphs.</td></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMSkeleton</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Skeleton for a code generation backend.</td></tr>
|
2004-12-31 01:13:14 +01:00
|
|
|
<tr><td>LLVMSparcV8</td><td><tt>.o</tt></td>
|
|
|
|
<td>Code generation for SparcV8.</td></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMSparcV9</td><td><tt>.o</tt></td>
|
|
|
|
<td>Code generation for SparcV9.</td></tr>
|
|
|
|
<tr><td>LLVMSparcV9RegAlloc</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Graph-coloring register allocator for SparcV9.</td></tr>
|
|
|
|
<tr><td>LLVMSparcV9InstrSched</td><td><tt>.o</tt></td>
|
|
|
|
<td>Instruction scheduling for SparcV9.</td></tr>
|
|
|
|
<tr><td>LLVMSparcV9LiveVar</td><td><tt>.o</tt></td>
|
|
|
|
<td>Live variable analysis SparcV9.</td></tr>
|
|
|
|
<tr><td>LLVMSparcV9ModuloSched</td><td><tt>.o</tt></td>
|
|
|
|
<td>Modulo scheduling for SparcV9.</td></tr>
|
|
|
|
<tr><td>LLVMTarget</td><td><tt>.a .o</tt></td>
|
|
|
|
<td>Generic code generation utilities.</td></tr>
|
|
|
|
<tr><td>LLVMX86</td><td><tt>.o</tt></td>
|
|
|
|
<td>Intel x86 code generation backend</td></tr>
|
2004-11-01 00:00:25 +01:00
|
|
|
|
2004-11-01 10:22:49 +01:00
|
|
|
<tr><th colspan="3">Runtime Libraries</th></tr>
|
2004-11-01 00:24:31 +01:00
|
|
|
<tr><td>LLVMInterpreter</td><td><tt>.o</tt></td>
|
|
|
|
<td>Bytecode Interpreter</td></tr>
|
|
|
|
<tr><td>LLVMJIT</td><td><tt>.o</tt></td>
|
|
|
|
<td>Bytecode JIT Compiler</td></tr>
|
|
|
|
<tr><td>LLVMExecutionEngine</td><td><tt>.o</tt></td>
|
|
|
|
<td>Virtual machine engine</td></tr>
|
|
|
|
<tr><td>LLVMexecve</td><td><tt>.o</tt></td>
|
|
|
|
<td>execve(2) replacement for llee</td></tr>
|
2004-02-27 07:28:34 +01:00
|
|
|
</table>
|
|
|
|
</div>
|
2004-11-01 00:00:25 +01:00
|
|
|
|
2004-12-31 00:12:04 +01:00
|
|
|
<!-- ======================================================================= -->
|
|
|
|
<div class="doc_section"><a name="dependencies"></a>Library Dependencies</div>
|
|
|
|
<div class="doc_text">
|
|
|
|
<p>The following list shows the dependency relationships between libraries.
|
|
|
|
This information can be automatically generated with the
|
|
|
|
<tt>GenLibDeps.pl</tt> utility in the <tt>llvm/utils</tt> directory.</p>
|
|
|
|
<!-- =======NOTE: =========================================================-->
|
|
|
|
<!-- === The following <dl> list is generated automatically by the util ===-->
|
|
|
|
<!-- === named GenLibDeps.pl in the llvm/utils directory. This should ===-->
|
|
|
|
<!-- === updated whenever new libraries are added, removed, or changed ===-->
|
|
|
|
<!-- =======NOTE: =========================================================-->
|
|
|
|
<dl>
|
|
|
|
<dt><b>libLLVMAnalysis.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMArchive.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>LLVMBCReader.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMDataStructure.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMInstrumentation.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMLinker.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMArchive.a</li>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>LLVMBCReader.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMScalarOpts.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMSparcV9RegAlloc.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMSparcV9LiveVar.o</li>
|
|
|
|
<li>LLVMSparcV9.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMSupport.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>LLVMbzip2.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMSystem.a</b</dt><dd><ul>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMTarget.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMTransformUtils.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMTransforms.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMipa.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>libLLVMipo.a</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMipa.a</li>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMAnalysis.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMAsmParser.o</b</dt><dd><ul>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMBCReader.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMBCWriter.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMCBackend.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMipa.a</li>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMCodeGen.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMCore.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMDataStructure.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMDebugger.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>LLVMBCReader.o</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMExecutionEngine.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMExecutionEngine.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMInterpreter.o</li>
|
|
|
|
<li>LLVMJIT.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMInstrumentation.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMInterpreter.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMExecutionEngine.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMJIT.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMExecutionEngine.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMPowerPC.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMProfilePaths.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMInstrumentation.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMScalarOpts.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSelectionDAG.o</b</dt><dd><ul>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSkeleton.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSparcV8.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSparcV9.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSparcV9RegAlloc.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMBCWriter.o</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMSparcV9InstrSched.o</li>
|
|
|
|
<li>LLVMSparcV9ModuloSched.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSparcV9InstrSched.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMSparcV9LiveVar.o</li>
|
|
|
|
<li>LLVMSparcV9.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSparcV9LiveVar.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSparcV9ModuloSched.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMSparcV9.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSparcV9RegAlloc.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
<li>LLVMSparcV9LiveVar.o</li>
|
|
|
|
<li>LLVMSparcV9.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSupport.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSystem.a</li>
|
|
|
|
<li>LLVMbzip2.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMSystem.o</b</dt><dd><ul>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMTarget.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMTransformUtils.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMTransforms.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMX86.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>LLVMCodeGen.o</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMbzip2.o</b</dt><dd><ul>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMipa.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
<dt><b>LLVMipo.o</b</dt><dd><ul>
|
|
|
|
<li>libLLVMAnalysis.a</li>
|
|
|
|
<li>libLLVMipa.a</li>
|
|
|
|
<li>libLLVMScalarOpts.a</li>
|
|
|
|
<li>libLLVMSupport.a</li>
|
|
|
|
<li>libLLVMTarget.a</li>
|
|
|
|
<li>libLLVMTransformUtils.a</li>
|
|
|
|
<li>LLVMCore.o</li>
|
|
|
|
</ul></dd>
|
|
|
|
</dl>
|
|
|
|
</div>
|
|
|
|
|
2004-02-27 07:28:34 +01:00
|
|
|
<!-- ======================================================================= -->
|
|
|
|
<div class="doc_section"><a name="rot">Linkage Rules Of Thumb</a></div>
|
|
|
|
<div class="doc_text">
|
|
|
|
<p>This section contains various "rules of thumb" about what files you
|
|
|
|
should link into your programs.</p>
|
|
|
|
</div>
|
|
|
|
<!-- ======================================================================= -->
|
2004-11-08 01:22:22 +01:00
|
|
|
<div class="doc_subsection"><a name="always">Always Link LLVMCore, LLVMSupport,
|
|
|
|
and LLVMSystem</a></div>
|
2004-02-27 07:28:34 +01:00
|
|
|
<div class="doc_text">
|
2004-11-08 01:26:32 +01:00
|
|
|
<p>No matter what you do with LLVM, the last three entries in the value of
|
|
|
|
your LLVMLIBS make variable should always be:
|
|
|
|
<tt>LLVMCore LLVMSupport.a LLVMSystem.a</tt>. There are no <tt>LLVM</tt>
|
|
|
|
programs that don't depend on these three.</p>
|
2004-02-27 07:28:34 +01:00
|
|
|
</div>
|
|
|
|
<!-- ======================================================================= -->
|
2004-11-01 00:00:25 +01:00
|
|
|
<div class="doc_subsection"><a name="onlyone">Never link both archive and
|
|
|
|
re-linked library</a></div>
|
2004-02-27 07:28:34 +01:00
|
|
|
<div class="doc_text">
|
2004-11-01 00:00:25 +01:00
|
|
|
<p>There is never any point to linking both the re-linked (<tt>.o</tt>) and
|
|
|
|
the archive (<tt>.a</tt>) versions of a library. Since the re-linked version
|
|
|
|
includes the entire library, the archive version will not resolve any symbols.
|
2004-11-08 01:24:43 +01:00
|
|
|
You could even end up with link error if you place the archive version before
|
2004-11-01 00:00:25 +01:00
|
|
|
the re-linked version on the linker's command line.</p>
|
2004-02-27 07:28:34 +01:00
|
|
|
</div>
|
|
|
|
<!-- ======================================================================= -->
|
|
|
|
<hr>
|
|
|
|
<div class="doc_footer">
|
2004-11-01 10:19:53 +01:00
|
|
|
<address>
|
|
|
|
<a href="http://jigsaw.w3.org/css-validator/check/referer"><img
|
|
|
|
src="http://jigsaw.w3.org/css-validator/images/vcss" alt="Valid CSS!"/></a>
|
|
|
|
<a href="http://validator.w3.org/check/referer"><img
|
|
|
|
src="http://www.w3.org/Icons/valid-html401" alt="Valid HTML 4.01!" /></a>
|
|
|
|
<a href="mailto:rspencer@x10sys.com">Reid Spencer</a>
|
|
|
|
</address>
|
2004-02-27 07:28:34 +01:00
|
|
|
<a href="http://llvm.cs.uiuc.edu">The LLVM Compiler Infrastructure</a>
|
|
|
|
<br>Last modified: $Date$ </div>
|
|
|
|
</body>
|
|
|
|
</html>
|
|
|
|
<!-- vim: sw=2 ts=2 ai
|
|
|
|
-->
|