summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorrdivacky <rdivacky@FreeBSD.org>2010-01-01 10:31:22 +0000
committerrdivacky <rdivacky@FreeBSD.org>2010-01-01 10:31:22 +0000
commita16c51cee9225a354c999dd1076d5dba2aa79807 (patch)
treedba00119388b84f9f44e6ec5e9129f807fd79ca3 /docs
parent40a6fcdb85efd93fe0e36c9552cfb0b18b5eacd6 (diff)
downloadFreeBSD-src-a16c51cee9225a354c999dd1076d5dba2aa79807.zip
FreeBSD-src-a16c51cee9225a354c999dd1076d5dba2aa79807.tar.gz
Update LLVM to 92395.
Diffstat (limited to 'docs')
-rw-r--r--docs/CompilerDriver.html49
-rw-r--r--docs/GettingStarted.html79
-rw-r--r--docs/LangRef.html37
3 files changed, 93 insertions, 72 deletions
diff --git a/docs/CompilerDriver.html b/docs/CompilerDriver.html
index 3af190d..b69b8c9 100644
--- a/docs/CompilerDriver.html
+++ b/docs/CompilerDriver.html
@@ -334,8 +334,8 @@ once). Incompatible with <tt class="docutils literal"><span class="pre">zero_or_
only for list options in conjunction with <tt class="docutils literal"><span class="pre">multi_val</span></tt>; for ordinary lists
it is synonymous with <tt class="docutils literal"><span class="pre">required</span></tt>. Incompatible with <tt class="docutils literal"><span class="pre">required</span></tt> and
<tt class="docutils literal"><span class="pre">zero_or_one</span></tt>.</li>
-<li><tt class="docutils literal"><span class="pre">zero_or_one</span></tt> - the option can be specified zero or one times. Useful
-only for list options in conjunction with <tt class="docutils literal"><span class="pre">multi_val</span></tt>. Incompatible with
+<li><tt class="docutils literal"><span class="pre">optional</span></tt> - the option can be specified zero or one times. Useful only
+for list options in conjunction with <tt class="docutils literal"><span class="pre">multi_val</span></tt>. Incompatible with
<tt class="docutils literal"><span class="pre">required</span></tt> and <tt class="docutils literal"><span class="pre">one_or_more</span></tt>.</li>
<li><tt class="docutils literal"><span class="pre">hidden</span></tt> - the description of this option will not appear in
the <tt class="docutils literal"><span class="pre">--help</span></tt> output (but will appear in the <tt class="docutils literal"><span class="pre">--help-hidden</span></tt>
@@ -350,13 +350,14 @@ gcc's <tt class="docutils literal"><span class="pre">-Wa,</span></tt>.</li>
<li><tt class="docutils literal"><span class="pre">multi_val</span> <span class="pre">n</span></tt> - this option takes <em>n</em> arguments (can be useful in some
special cases). Usage example: <tt class="docutils literal"><span class="pre">(parameter_list_option</span> <span class="pre">&quot;foo&quot;,</span> <span class="pre">(multi_val</span>
<span class="pre">3))</span></tt>; the command-line syntax is '-foo a b c'. Only list options can have
-this attribute; you can, however, use the <tt class="docutils literal"><span class="pre">one_or_more</span></tt>, <tt class="docutils literal"><span class="pre">zero_or_one</span></tt>
+this attribute; you can, however, use the <tt class="docutils literal"><span class="pre">one_or_more</span></tt>, <tt class="docutils literal"><span class="pre">optional</span></tt>
and <tt class="docutils literal"><span class="pre">required</span></tt> properties.</li>
<li><tt class="docutils literal"><span class="pre">init</span></tt> - this option has a default value, either a string (if it is a
-parameter), or a boolean (if it is a switch; boolean constants are called
-<tt class="docutils literal"><span class="pre">true</span></tt> and <tt class="docutils literal"><span class="pre">false</span></tt>). List options can't have this attribute. Usage
-examples: <tt class="docutils literal"><span class="pre">(switch_option</span> <span class="pre">&quot;foo&quot;,</span> <span class="pre">(init</span> <span class="pre">true))</span></tt>; <tt class="docutils literal"><span class="pre">(prefix_option</span> <span class="pre">&quot;bar&quot;,</span>
-<span class="pre">(init</span> <span class="pre">&quot;baz&quot;))</span></tt>.</li>
+parameter), or a boolean (if it is a switch; as in C++, boolean constants
+are called <tt class="docutils literal"><span class="pre">true</span></tt> and <tt class="docutils literal"><span class="pre">false</span></tt>). List options can't have <tt class="docutils literal"><span class="pre">init</span></tt>
+attribute.
+Usage examples: <tt class="docutils literal"><span class="pre">(switch_option</span> <span class="pre">&quot;foo&quot;,</span> <span class="pre">(init</span> <span class="pre">true))</span></tt>; <tt class="docutils literal"><span class="pre">(prefix_option</span>
+<span class="pre">&quot;bar&quot;,</span> <span class="pre">(init</span> <span class="pre">&quot;baz&quot;))</span></tt>.</li>
<li><tt class="docutils literal"><span class="pre">extern</span></tt> - this option is defined in some other plugin, see <a class="reference internal" href="#extern">below</a>.</li>
</ul>
</blockquote>
@@ -604,10 +605,10 @@ def LanguageMap : LanguageMap&lt;
$ llvmc hello.cpp
llvmc: Unknown suffix: cpp
</pre>
-<p>The language map entries should be added only for tools that are
-linked with the root node. Since tools are not allowed to have
-multiple output languages, for nodes &quot;inside&quot; the graph the input and
-output languages should match. This is enforced at compile-time.</p>
+<p>The language map entries are needed only for the tools that are linked from the
+root node. Since a tool can't have multiple output languages, for inner nodes of
+the graph the input and output languages should match. This is enforced at
+compile-time.</p>
</div>
<div class="section" id="option-preprocessor">
<h1><a class="toc-backref" href="#id20">Option preprocessor</a></h1>
@@ -619,22 +620,30 @@ the driver with both of these options enabled.</p>
occasions. Example (adapted from the built-in Base plugin):</p>
<pre class="literal-block">
def Preprocess : OptionPreprocessor&lt;
-(case (and (switch_on &quot;O3&quot;), (any_switch_on [&quot;O0&quot;, &quot;O1&quot;, &quot;O2&quot;])),
- [(unset_option [&quot;O0&quot;, &quot;O1&quot;, &quot;O2&quot;]),
- (warning &quot;Multiple -O options specified, defaulted to -O3.&quot;)],
+(case (not (any_switch_on [&quot;O0&quot;, &quot;O1&quot;, &quot;O2&quot;, &quot;O3&quot;])),
+ (set_option &quot;O2&quot;),
+ (and (switch_on &quot;O3&quot;), (any_switch_on [&quot;O0&quot;, &quot;O1&quot;, &quot;O2&quot;])),
+ (unset_option [&quot;O0&quot;, &quot;O1&quot;, &quot;O2&quot;]),
(and (switch_on &quot;O2&quot;), (any_switch_on [&quot;O0&quot;, &quot;O1&quot;])),
(unset_option [&quot;O0&quot;, &quot;O1&quot;]),
(and (switch_on &quot;O1&quot;), (switch_on &quot;O0&quot;)),
(unset_option &quot;O0&quot;))
&gt;;
</pre>
-<p>Here, <tt class="docutils literal"><span class="pre">OptionPreprocessor</span></tt> is used to unset all spurious optimization options
-(so that they are not forwarded to the compiler).</p>
+<p>Here, <tt class="docutils literal"><span class="pre">OptionPreprocessor</span></tt> is used to unset all spurious <tt class="docutils literal"><span class="pre">-O</span></tt> options so
+that they are not forwarded to the compiler. If no optimization options are
+specified, <tt class="docutils literal"><span class="pre">-O2</span></tt> is enabled.</p>
<p><tt class="docutils literal"><span class="pre">OptionPreprocessor</span></tt> is basically a single big <tt class="docutils literal"><span class="pre">case</span></tt> expression, which is
evaluated only once right after the plugin is loaded. The only allowed actions
-in <tt class="docutils literal"><span class="pre">OptionPreprocessor</span></tt> are <tt class="docutils literal"><span class="pre">error</span></tt>, <tt class="docutils literal"><span class="pre">warning</span></tt> and a special action
-<tt class="docutils literal"><span class="pre">unset_option</span></tt>, which, as the name suggests, unsets a given option. For
-convenience, <tt class="docutils literal"><span class="pre">unset_option</span></tt> also works on lists.</p>
+in <tt class="docutils literal"><span class="pre">OptionPreprocessor</span></tt> are <tt class="docutils literal"><span class="pre">error</span></tt>, <tt class="docutils literal"><span class="pre">warning</span></tt>, and two special actions:
+<tt class="docutils literal"><span class="pre">unset_option</span></tt> and <tt class="docutils literal"><span class="pre">set_option</span></tt>. As their names suggest, they can be used to
+set or unset a given option. To set an option with <tt class="docutils literal"><span class="pre">set_option</span></tt>, use the
+two-argument form: <tt class="docutils literal"><span class="pre">(set_option</span> <span class="pre">&quot;parameter&quot;,</span> <span class="pre">VALUE)</span></tt>. Here, <tt class="docutils literal"><span class="pre">VALUE</span></tt> can be
+either a string, a string list, or a boolean constant.</p>
+<p>For convenience, <tt class="docutils literal"><span class="pre">set_option</span></tt> and <tt class="docutils literal"><span class="pre">unset_option</span></tt> also work on lists. That
+is, instead of <tt class="docutils literal"><span class="pre">[(unset_option</span> <span class="pre">&quot;A&quot;),</span> <span class="pre">(unset_option</span> <span class="pre">&quot;B&quot;)]</span></tt> you can use
+<tt class="docutils literal"><span class="pre">(unset_option</span> <span class="pre">[&quot;A&quot;,</span> <span class="pre">&quot;B&quot;])</span></tt>. Obviously, <tt class="docutils literal"><span class="pre">(set_option</span> <span class="pre">[&quot;A&quot;,</span> <span class="pre">&quot;B&quot;])</span></tt> is valid
+only if both <tt class="docutils literal"><span class="pre">A</span></tt> and <tt class="docutils literal"><span class="pre">B</span></tt> are switches.</p>
</div>
<div class="section" id="more-advanced-topics">
<h1><a class="toc-backref" href="#id21">More advanced topics</a></h1>
@@ -739,7 +748,7 @@ the <tt class="docutils literal"><span class="pre">Base</span></tt> plugin behav
<a href="mailto:foldr@codedgers.com">Mikhail Glushenkov</a><br />
<a href="http://llvm.org">LLVM Compiler Infrastructure</a><br />
-Last modified: $Date: 2009-12-07 19:26:24 +0100 (Mon, 07 Dec 2009) $
+Last modified: $Date: 2009-12-23 13:49:51 +0100 (Wed, 23 Dec 2009) $
</address></div>
</div>
</div>
diff --git a/docs/GettingStarted.html b/docs/GettingStarted.html
index 4b2b56f..5f17b5b 100644
--- a/docs/GettingStarted.html
+++ b/docs/GettingStarted.html
@@ -114,13 +114,15 @@ and performance.
<li>Read the documentation.</li>
<li>Read the documentation.</li>
<li>Remember that you were warned twice about reading the documentation.</li>
- <li>Install the llvm-gcc-4.2 front end if you intend to compile C or C++:
+ <li>Install the llvm-gcc-4.2 front end if you intend to compile C or C++
+ (see <a href="#installcf">Install the GCC Front End</a> for details):</li>
<ol>
<li><tt>cd <i>where-you-want-the-C-front-end-to-live</i></tt></li>
- <li><tt>gunzip --stdout llvm-gcc-4.2-<i>version</i>-<i>platform</i>.tar.gz | tar -xvf -</tt>
- </li>
- <li>Note: If the binary extension is ".bz" use bunzip2 instead of gunzip.</li>
- <li>Add llvm-gcc's "bin" directory to your PATH variable.</li>
+ <li><tt>gunzip --stdout llvm-gcc-4.2-<i>version</i>-<i>platform</i>.tar.gz | tar -xvf -</tt></li>
+ <li><tt><i>install-binutils-binary-from-MinGW</i></tt> (Windows only)</li>
+ <li>Note: If the binary extension is "<tt>.bz</tt>" use <tt>bunzip2</tt> instead of <tt>gunzip</tt>.</li>
+ <li>Note: On Windows, use <a href="http://www.7-zip.org">7-Zip</a> or a similar archiving tool.</li>
+ <li>Add <tt>llvm-gcc</tt>'s "<tt>bin</tt>" directory to your <tt>PATH</tt> environment variable.</li>
</ol></li>
<li>Get the LLVM Source Code
@@ -774,13 +776,14 @@ instructions</a> to successfully get and build the LLVM GCC front-end.</p>
<div class="doc_text">
-<p>Before configuring and compiling the LLVM suite, you can optionally extract the
-LLVM GCC front end from the binary distribution. It is used for running the
-llvm-test testsuite and for compiling C/C++ programs. Note that you can optionally
-<a href="GCCFEBuildInstrs.html">build llvm-gcc yourself</a> after building the
+<p>Before configuring and compiling the LLVM suite (or if you want to use just the LLVM
+GCC front end) you can optionally extract the front end from the binary distribution.
+It is used for running the llvm-test testsuite and for compiling C/C++ programs. Note that
+you can optionally <a href="GCCFEBuildInstrs.html">build llvm-gcc yourself</a> after building the
main LLVM repository.</p>
-<p>To install the GCC front end, do the following:</p>
+<p>To install the GCC front end, do the following (on Windows, use an archival tool
+like <a href="http://www.7-zip.org">7-zip</a> that understands gzipped tars):</p>
<ol>
<li><tt>cd <i>where-you-want-the-front-end-to-live</i></tt></li>
@@ -788,22 +791,51 @@ main LLVM repository.</p>
-</tt></li>
</ol>
-<p>Once the binary is uncompressed, you should add a symlink for llvm-gcc and
-llvm-g++ to some directory in your path. When you configure LLVM, it will
-automatically detect llvm-gcc's presence (if it is in your path) enabling its
-use in llvm-test. Note that you can always build or install llvm-gcc at any
-pointer after building the main LLVM repository: just reconfigure llvm and
+<p>Once the binary is uncompressed, if you're using a *nix-based system, add a symlink for
+<tt>llvm-gcc</tt> and <tt>llvm-g++</tt> to some directory in your path. If you're using a
+Windows-based system, add the <tt>bin</tt> subdirectory of your front end installation directory
+to your <tt>PATH</tt> environment variable. For example, if you uncompressed the binary to
+<tt>c:\llvm-gcc</tt>, add <tt>c:\llvm-gcc\bin</tt> to your <tt>PATH</tt>.</p>
+
+<p>If you now want to build LLVM from source, when you configure LLVM, it will
+automatically detect <tt>llvm-gcc</tt>'s presence (if it is in your path) enabling its
+use in llvm-test. Note that you can always build or install <tt>llvm-gcc</tt> at any
+point after building the main LLVM repository: just reconfigure llvm and
llvm-test will pick it up.
</p>
-<p>The binary versions of the GCC front end may not suit all of your needs. For
-example, the binary distribution may include an old version of a system header
-file, not "fix" a header file that needs to be fixed for GCC, or it may be
-linked with libraries not available on your system.</p>
+<p>As a convenience for Windows users, the front end binaries for MinGW/x86 include
+versions of the required w32api and mingw-runtime binaries. The last remaining step for
+Windows users is to simply uncompress the binary binutils package from
+<a href="http://mingw.org/">MinGW</a> into your front end installation directory. While the
+front end installation steps are not quite the same as a typical manual MinGW installation,
+they should be similar enough to those who have previously installed MinGW on Windows systems.</p>
+
+<p>To install binutils on Windows:</p>
+
+<ol>
+ <li><tt><i>download GNU Binutils from <a href="http://sourceforge.net/projects/mingw/files/">MinGW Downloads</a></i></tt></li>
+ <li><tt>cd <i>where-you-uncompressed-the-front-end</i></tt></li>
+ <li><tt><i>uncompress archived binutils directories (not the tar file) into the current directory</i></tt></li>
+</ol>
-<p>In cases like these, you may want to try <a
-href="GCCFEBuildInstrs.html">building the GCC front end from source.</a> This is
-much easier now than it was in the past.</p>
+<p>The binary versions of the LLVM GCC front end may not suit all of your needs. For
+example, the binary distribution may include an old version of a system header
+file, not "fix" a header file that needs to be fixed for GCC, or it may be linked with
+libraries not available on your system. In cases like these, you may want to try
+<a href="GCCFEBuildInstrs.html">building the GCC front end from source</a>. Thankfully,
+this is much easier now than it was in the past.</p>
+
+<p>We also do not currently support updating of the GCC front end by manually overlaying
+newer versions of the w32api and mingw-runtime binary packages that may become available
+from MinGW. At this time, it's best to think of the MinGW LLVM GCC front end binary as
+a self-contained convenience package that requires Windows users to simply download and
+uncompress the GNU Binutils binary package from the MinGW project.</p>
+
+<p>Regardless of your platform, if you discover that installing the LLVM GCC front end
+binaries is not as easy as previously described, or you would like to suggest improvements,
+please let us know how you would like to see things improved by dropping us a note on our
+<a href="http://llvm.org/docs/#maillist">mailing list</a>.</p>
</div>
@@ -1171,7 +1203,6 @@ Cummings for pointing this out!
</div>
-
<!-- *********************************************************************** -->
<div class="doc_section">
<a name="layout"><b>Program Layout</b></a>
@@ -1640,7 +1671,7 @@ out:</p>
<a href="mailto:sabre@nondot.org">Chris Lattner</a><br>
<a href="http://llvm.x10sys.com/rspencer/">Reid Spencer</a><br>
<a href="http://llvm.org">The LLVM Compiler Infrastructure</a><br>
- Last modified: $Date: 2009-12-09 18:26:02 +0100 (Wed, 09 Dec 2009) $
+ Last modified: $Date: 2009-12-17 18:18:11 +0100 (Thu, 17 Dec 2009) $
</address>
</body>
</html>
diff --git a/docs/LangRef.html b/docs/LangRef.html
index 8b17e0e..ba09f4c 100644
--- a/docs/LangRef.html
+++ b/docs/LangRef.html
@@ -7257,8 +7257,8 @@ LLVM</a>.</p>
<h5>Syntax:</h5>
<pre>
- declare i32 @llvm.objectsize.i32( i8* &lt;ptr&gt;, i32 &lt;type&gt; )
- declare i64 @llvm.objectsize.i64( i8* &lt;ptr&gt;, i32 &lt;type&gt; )
+ declare i32 @llvm.objectsize.i32( i8* &lt;object&gt;, i1 &lt;type&gt; )
+ declare i64 @llvm.objectsize.i64( i8* &lt;object&gt;, i1 &lt;type&gt; )
</pre>
<h5>Overview:</h5>
@@ -7267,34 +7267,15 @@ LLVM</a>.</p>
operation like memcpy will either overflow a buffer that corresponds to
an object, or b) to determine that a runtime check for overflow isn't
necessary. An object in this context means an allocation of a
- specific <a href="#typesystem">type</a>.</p>
+ specific class, structure, array, or other object.</p>
<h5>Arguments:</h5>
<p>The <tt>llvm.objectsize</tt> intrinsic takes two arguments. The first
- argument is a pointer to the object <tt>ptr</tt>. The second argument
- is an integer <tt>type</tt> which ranges from 0 to 3. The first bit in
- the type corresponds to a return value based on whole objects,
- and the second bit whether or not we return the maximum or minimum
- remaining bytes computed.</p>
-<table class="layout">
- <tr class="layout">
- <td class="left"><tt>00</tt></td>
- <td class="left">whole object, maximum number of bytes</td>
- </tr>
- <tr class="layout">
- <td class="left"><tt>01</tt></td>
- <td class="left">partial object, maximum number of bytes</td>
- </tr>
- <tr class="layout">
- <td class="left"><tt>10</tt></td>
- <td class="left">whole object, minimum number of bytes</td>
- </tr>
- <tr class="layout">
- <td class="left"><tt>11</tt></td>
- <td class="left">partial object, minimum number of bytes</td>
- </tr>
-</table>
-
+ argument is a pointer to or into the <tt>object</tt>. The second argument
+ is a boolean 0 or 1. This argument determines whether you want the
+ maximum (0) or minimum (1) bytes remaining. This needs to be a literal 0 or
+ 1, variables are not allowed.</p>
+
<h5>Semantics:</h5>
<p>The <tt>llvm.objectsize</tt> intrinsic is lowered to either a constant
representing the size of the object concerned or <tt>i32/i64 -1 or 0</tt>
@@ -7313,7 +7294,7 @@ LLVM</a>.</p>
<a href="mailto:sabre@nondot.org">Chris Lattner</a><br>
<a href="http://llvm.org">The LLVM Compiler Infrastructure</a><br>
- Last modified: $Date: 2009-12-05 03:46:03 +0100 (Sat, 05 Dec 2009) $
+ Last modified: $Date: 2009-12-23 01:29:49 +0100 (Wed, 23 Dec 2009) $
</address>
</body>
OpenPOWER on IntegriCloud