aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorEd Schouten <ed@FreeBSD.org>2009-06-03 21:10:15 +0000
committerEd Schouten <ed@FreeBSD.org>2009-06-03 21:10:15 +0000
commit68eb509bdc5c7007520d5231cd92de28106236df (patch)
treedb103e2a0755ab86f18c181a2d208a6a63284c97 /docs
parent33a8e4360f5050416130517e5c7a1007d06aa90f (diff)
downloadsrc-68eb509bdc5c7007520d5231cd92de28106236df.tar.gz
src-68eb509bdc5c7007520d5231cd92de28106236df.zip
Import LLVM, at r72805, which fixes PR4315 and PR4316.vendor/llvm/llvm-r72805
Normally I'm not updating sources this often, but I want to get rid of this breakage, because right now I can't offer a proper source snapshot yet.
Notes
Notes: svn path=/vendor/llvm/dist/; revision=193399 svn path=/vendor/llvm/llvm-r72805/; revision=193400; tag=vendor/llvm/llvm-r72805
Diffstat (limited to 'docs')
-rw-r--r--docs/CMake.html4
-rw-r--r--docs/GoldPlugin.html30
2 files changed, 34 insertions, 0 deletions
diff --git a/docs/CMake.html b/docs/CMake.html
index 27ec88ec9478..b329ca46d62e 100644
--- a/docs/CMake.html
+++ b/docs/CMake.html
@@ -248,6 +248,10 @@
<dt><b>LLVM_ENABLE_THREADS</b>:BOOL</dt>
<dd>Build with threads support, if available. Defaults to ON.</dd>
+ <dt><b>LLVM_ENABLE_ASSERTS</b>:BOOL</dt>
+ <dd>Enables code asserts. Defaults to ON if and only if
+ CMAKE_BUILD_TYPE is <i>Release</i>.</dd>
+
<dt><b>LLVM_ENABLE_PIC</b>:BOOL</dt>
<dd>Add the <i>-fPIC</i> flag to the compiler command-line, if the
compiler supports this flag. Some systems, like Windows, does not
diff --git a/docs/GoldPlugin.html b/docs/GoldPlugin.html
index ee014101bc24..6be5277efd16 100644
--- a/docs/GoldPlugin.html
+++ b/docs/GoldPlugin.html
@@ -14,6 +14,7 @@
<li><a href="#usage">Usage</a>
<ul>
<li><a href="#example1">Example of link time optimization</a></li>
+ <li><a href="#lto_autotools">Quickstart for using LTO with autotooled projects</a></li>
</ul></li>
<li><a href="#licensing">Licensing</a></li>
</ol>
@@ -136,6 +137,35 @@ $ llvm-gcc -use-gold-plugin a.o b.o -o main # &lt;-- link with LLVMgold plugin
</div>
<!--=========================================================================-->
+<div class="doc_section"><a name="lto_autotools">Quickstart for using LTO with autotooled projects</a></div>
+<!--=========================================================================-->
+<div class="doc_text">
+ <p><tt>gold</tt>, <tt>ar</tt> and <tt>nm</tt> all support plugins now, so everything should be
+ in place for an easy to use LTO build of autotooled projects:</p>
+ <ul>
+ <li>Follow the instructions <a href="#build">on how to build libLLVMgold.so</a>.</li>
+ <li>Install the newly built binutils to <tt>$PREFIX</tt></li>
+ <li>Copy <tt>Release/lib/libLLVMgold.so</tt> to
+ <tt>$PREFIX/libexec/gcc/x86_64-unknown-linux-gnu/4.2.1/</tt> and
+ <tt>$PREFIX/lib/bfd-plugins/</tt></li>
+ <li>Set environment variables (<tt>$PREFIX</tt> is where you installed llvm-gcc and
+ binutils):
+ <pre class="doc_code">
+export CC="$PREFIX/bin/llvm-gcc -use-gold-plugin"
+export CXX="$PREFIX/bin/llvm-g++ -use-gold-plugin"
+export AR="$PREFIX/bin/ar --plugin libLLVMgold.so"
+export NM="$PREFIX/bin/nm --plugin libLLVMgold.so"
+export RANLIB=/bin/true #ranlib is not needed, and doesn't support .bc files in .a
+export CFLAGS="-O4"
+ </pre>
+ </li>
+ <li>Configure &amp; build the project as usual: <tt>./configure &amp;&amp; make &amp;&amp; make check</tt> </li>
+ </ul>
+ <p> The environment variable settings may work for non-autotooled projects
+ too, but you may need to set the <tt>LD</tt> environment variable as well.</p>
+</div>
+
+<!--=========================================================================-->
<div class="doc_section"><a name="licensing">Licensing</a></div>
<!--=========================================================================-->
<div class="doc_text">