standard C++ library.</li>
<li><a href="http://www.tempest-sw.com/cpp/">C++ In a Nutshell</a> - This is an
-O'Reilly book in the making. It has a decent <a
-href="http://www.tempest-sw.com/cpp/ch13-libref.html">Standard Library
-Reference</a> that rivals Dinkumware's, and is actually free until the book is
+O'Reilly book in the making. It has a decent
+Standard Library
+Reference that rivals Dinkumware's, and is unfortunately no longer free since the book has been
published.</li>
<li><a href="http://www.parashift.com/c++-faq-lite/">C++ Frequently Asked
<div class="doc_text">
-<p>LLVM is currently using CVS as its source versioning system. You may find
-this reference handy:</p>
-
<ol>
<li><a href="http://www.psc.edu/%7Esemke/cvs_branches.html">CVS
Branch and Tag Primer</a></li>
+<li><a href="http://www.fortran-2000.com/ArnaudRecipes/sharedlib.html">Using
+static and shared libraries across platforms</a></li>
</ol>
</div>
most-specific common base class is <tt>Instruction</tt>, which includes lots of
less closely-related things. For these cases, LLVM provides a handy wrapper
class called <a
-href="http://llvm.cs.uiuc.edu/doxygen/classCallSite.html"><tt>CallSite</tt></a>.
+href="http://llvm.cs.uiuc.edu/doxygen/classllvm_1_1CallSite.html"><tt>CallSite</tt></a>.
It is essentially a wrapper around an <tt>Instruction</tt> pointer, with some
methods that provide functionality common to <tt>CallInst</tt>s and
<tt>InvokeInst</tt>s.</p>
<div class="doc_text">
<p>Frequently, we might have an instance of the <a
-href="/doxygen/classValue.html">Value Class</a> and we want to determine which
-<tt>User</tt>s use the <tt>Value</tt>. The list of all <tt>User</tt>s of a
-particular <tt>Value</tt> is called a <i>def-use</i> chain. For example, let's
-say we have a <tt>Function*</tt> named <tt>F</tt> to a particular function
-<tt>foo</tt>. Finding all of the instructions that <i>use</i> <tt>foo</tt> is as
-simple as iterating over the <i>def-use</i> chain of <tt>F</tt>:</p>
+href="/doxygen/structllvm_1_1Value.html">Value Class</a> and we want to
+determine which <tt>User</tt>s use the <tt>Value</tt>. The list of all
+<tt>User</tt>s of a particular <tt>Value</tt> is called a <i>def-use</i> chain.
+For example, let's say we have a <tt>Function*</tt> named <tt>F</tt> to a
+particular function <tt>foo</tt>. Finding all of the instructions that
+<i>use</i> <tt>foo</tt> is as simple as iterating over the <i>def-use</i> chain
+of <tt>F</tt>:</p>
<pre>Function* F = ...;<br><br>for (Value::use_iterator i = F->use_begin(), e = F->use_end(); i != e; ++i) {<br> if (Instruction *Inst = dyn_cast<Instruction>(*i)) {<br> cerr << "F is used in instruction:\n";<br> cerr << *Inst << "\n";<br> }<br>}<br></pre>
<p>Alternately, it's common to have an instance of the <a
-href="/doxygen/classUser.html">User Class</a> and need to know what
+href="/doxygen/classllvm_1_1User.html">User Class</a> and need to know what
<tt>Value</tt>s are used by it. The list of all <tt>Value</tt>s used by a
<tt>User</tt> is known as a <i>use-def</i> chain. Instances of class
<tt>Instruction</tt> are common <tt>User</tt>s, so we might want to iterate over
one integer in the current stack frame, at runtime. Each <tt>Instruction</tt>
subclass is likely to have varying default parameters which change the semantics
of the instruction, so refer to the <a
-href="/doxygen/classInstruction.html">doxygen documentation for the subclass of
+href="/doxygen/classllvm_1_1Instruction.html">doxygen documentation for the subclass of
Instruction</a> that you're interested in instantiating.</p>
<p><i>Naming values</i></p>
<tt>BasicBlock</tt>, and a newly-created instruction we wish to insert
before <tt>*pi</tt>, we do the following: </p>
- <pre> BasicBlock *pb = ...;<br> Instruction *pi = ...;<br> Instruction *newInst = new Instruction(...);<br> pb->getInstList().insert(pi, newInst); // inserts newInst before pi in pb<br></pre></li>
+ <pre> BasicBlock *pb = ...;<br> Instruction *pi = ...;<br> Instruction *newInst = new Instruction(...);<br> pb->getInstList().insert(pi, newInst); // inserts newInst before pi in pb<br></pre>
+
+ <p>Appending to the end of a <tt>BasicBlock</tt> is so common that
+ the <tt>Instruction</tt> class and <tt>Instruction</tt>-derived
+ classes provide constructors which take a pointer to a
+ <tt>BasicBlock</tt> to be appended to. For example code that
+ looked like: </p>
+
+ <pre> BasicBlock *pb = ...;<br> Instruction *newInst = new Instruction(...);<br> pb->getInstList().push_back(newInst); // appends newInst to pb<br></pre>
+
+ <p>becomes: </p>
+
+ <pre> BasicBlock *pb = ...;<br> Instruction *newInst = new Instruction(..., pb);<br></pre>
+
+ <p>which is much cleaner, especially if you are creating
+ long instruction streams.</p></li>
<li>Insertion into an implicit instruction list
<p>You can use <tt>Value::replaceAllUsesWith</tt> and
<tt>User::replaceUsesOfWith</tt> to change more than one use at a time. See the
-doxygen documentation for the <a href="/doxygen/classValue.html">Value Class</a>
-and <a href="/doxygen/classUser.html">User Class</a>, respectively, for more
+doxygen documentation for the <a href="/doxygen/structllvm_1_1Value.html">Value Class</a>
+and <a href="/doxygen/classllvm_1_1User.html">User Class</a>, respectively, for more
information.</p>
<!-- Value::replaceAllUsesWith User::replaceUsesOfWith Point out:
<p><tt>#include "<a href="/doxygen/Value_8h-source.html">llvm/Value.h</a>"</tt>
<br>
-doxygen info: <a href="/doxygen/classValue.html">Value Class</a></p>
+doxygen info: <a href="/doxygen/structllvm_1_1Value.html">Value Class</a></p>
<p>The <tt>Value</tt> class is the most important class in the LLVM Source
base. It represents a typed value that may be used (among other things) as an
<p>
<tt>#include "<a href="/doxygen/User_8h-source.html">llvm/User.h</a>"</tt><br>
-doxygen info: <a href="/doxygen/classUser.html">User Class</a><br>
+doxygen info: <a href="/doxygen/classllvm_1_1User.html">User Class</a><br>
Superclass: <a href="#Value"><tt>Value</tt></a></p>
<p>The <tt>User</tt> class is the common base class of all LLVM nodes that may
<p><tt>#include "</tt><tt><a
href="/doxygen/Instruction_8h-source.html">llvm/Instruction.h</a>"</tt><br>
-doxygen info: <a href="/doxygen/classInstruction.html">Instruction Class</a><br>
+doxygen info: <a href="/doxygen/classllvm_1_1Instruction.html">Instruction Class</a><br>
Superclasses: <a href="#User"><tt>User</tt></a>, <a
href="#Value"><tt>Value</tt></a></p>
example <tt><a href="#BinaryOperator">BinaryOperator</a></tt> and <tt><a
href="#SetCondInst">SetCondInst</a></tt>). Unfortunately, the use of macros in
this file confuses doxygen, so these enum values don't show up correctly in the
-<a href="/doxygen/classInstruction.html">doxygen output</a>.</p>
+<a href="/doxygen/classllvm_1_1Instruction.html">doxygen output</a>.</p>
</div>
<div class="doc_text">
-<p><tt>#include "<a href="/doxygen/BasicBlock_8h-source.html">llvm/BasicBlock.h</a>"</tt><br>
-doxygen info: <a href="/doxygen/classBasicBlock.html">BasicBlock Class</a><br>
+<p><tt>#include "<a
+href="/doxygen/BasicBlock_8h-source.html">llvm/BasicBlock.h</a>"</tt><br>
+doxygen info: <a href="/doxygen/structllvm_1_1BasicBlock.html">BasicBlock
+Class</a><br>
Superclass: <a href="#Value"><tt>Value</tt></a></p>
<p>This class represents a single entry multiple exit section of the code,
<p><tt>#include "<a
href="/doxygen/GlobalValue_8h-source.html">llvm/GlobalValue.h</a>"</tt><br>
-doxygen info: <a href="/doxygen/classGlobalValue.html">GlobalValue Class</a><br>
+doxygen info: <a href="/doxygen/classllvm_1_1GlobalValue.html">GlobalValue
+Class</a><br>
Superclasses: <a href="#User"><tt>User</tt></a>, <a
href="#Value"><tt>Value</tt></a></p>
<p><tt>#include "<a
href="/doxygen/Function_8h-source.html">llvm/Function.h</a>"</tt><br> doxygen
-info: <a href="/doxygen/classFunction.html">Function Class</a><br> Superclasses:
-<a href="#GlobalValue"><tt>GlobalValue</tt></a>, <a
+info: <a href="/doxygen/classllvm_1_1Function.html">Function Class</a><br>
+Superclasses: <a href="#GlobalValue"><tt>GlobalValue</tt></a>, <a
href="#User"><tt>User</tt></a>, <a href="#Value"><tt>Value</tt></a></p>
<p>The <tt>Function</tt> class represents a single procedure in LLVM. It is
<p><tt>#include "<a
href="/doxygen/GlobalVariable_8h-source.html">llvm/GlobalVariable.h</a>"</tt>
<br>
-doxygen info: <a href="/doxygen/classGlobalVariable.html">GlobalVariable
+doxygen info: <a href="/doxygen/classllvm_1_1GlobalVariable.html">GlobalVariable
Class</a><br> Superclasses: <a href="#GlobalValue"><tt>GlobalValue</tt></a>, <a
href="#User"><tt>User</tt></a>, <a href="#Value"><tt>Value</tt></a></p>
<p><tt>#include "<a
href="/doxygen/Module_8h-source.html">llvm/Module.h</a>"</tt><br> doxygen info:
-<a href="/doxygen/classModule.html">Module Class</a></p>
+<a href="/doxygen/classllvm_1_1Module.html">Module Class</a></p>
<p>The <tt>Module</tt> class represents the top level structure present in LLVM
programs. An LLVM module is effectively either a translation unit of the
return false as they do with isSigned. This returns true for UByteTy,
UShortTy, UIntTy, and ULongTy. </li>
- <li><tt>bool isInteger() const</tt>: Equilivent to isSigned() || isUnsigned(),
- but with only a single virtual function invocation.</li>
+ <li><tt>bool isInteger() const</tt>: Equivalent to isSigned() || isUnsigned().</li>
<li><tt>bool isIntegral() const</tt>: Returns true if this is an integral
type, which is either Bool type or one of the Integer types.</li>