[llvm-commits] CVS: llvm/docs/LangRef.html

Reid Spencer reid at x10sys.com
Sat Dec 30 23:08:09 PST 2006



Changes in directory llvm/docs:

LangRef.html updated: 1.180 -> 1.181
---
Log message:

For PR950: http://llvm.org/PR950 :
Update for signless integer types:
1. Replace [us]byte with i8
2. Replace [u]short with i16
3. Replace [u]int   with i32
4. Replace [u]long  with i64
5. Document the "define" keyword and use it in all examples.
6. Document parameter attributes and how they affect function types.


---
Diffs of the changes:  (+307 -277)

 LangRef.html |  584 +++++++++++++++++++++++++++++++----------------------------
 1 files changed, 307 insertions(+), 277 deletions(-)


Index: llvm/docs/LangRef.html
diff -u llvm/docs/LangRef.html:1.180 llvm/docs/LangRef.html:1.181
--- llvm/docs/LangRef.html:1.180	Thu Dec 28 10:55:55 2006
+++ llvm/docs/LangRef.html	Sun Dec 31 01:07:53 2006
@@ -24,6 +24,7 @@
       <li><a href="#callingconv">Calling Conventions</a></li>
       <li><a href="#globalvars">Global Variables</a></li>
       <li><a href="#functionstructure">Functions</a></li>
+      <li><a href="#paramattrs">Parameter Attributes</a></li>
       <li><a href="#moduleasm">Module-Level Inline Assembly</a></li>
     </ol>
   </li>
@@ -248,7 +249,7 @@
 following instruction is syntactically okay, but not well formed:</p>
 
 <pre>
-  %x = <a href="#i_add">add</a> int 1, %x
+  %x = <a href="#i_add">add</a> i32 1, %x
 </pre>
 
 <p>...because the definition of <tt>%x</tt> does not dominate all of
@@ -296,7 +297,7 @@
 ('<tt><a href="#i_add">add</a></tt>', 
  '<tt><a href="#i_bitcast">bitcast</a></tt>', 
  '<tt><a href="#i_ret">ret</a></tt>', etc...), for primitive type names ('<tt><a
-href="#t_void">void</a></tt>', '<tt><a href="#t_uint">uint</a></tt>', etc...),
+href="#t_void">void</a></tt>', '<tt><a href="#t_primitive">i32</a></tt>', etc...),
 and others.  These reserved words cannot conflict with variable names, because
 none of them start with a '%' character.</p>
 
@@ -306,21 +307,21 @@
 <p>The easy way:</p>
 
 <pre>
-  %result = <a href="#i_mul">mul</a> uint %X, 8
+  %result = <a href="#i_mul">mul</a> i32 %X, 8
 </pre>
 
 <p>After strength reduction:</p>
 
 <pre>
-  %result = <a href="#i_shl">shl</a> uint %X, ubyte 3
+  %result = <a href="#i_shl">shl</a> i32 %X, i8 3
 </pre>
 
 <p>And the hard way:</p>
 
 <pre>
-  <a href="#i_add">add</a> uint %X, %X           <i>; yields {uint}:%0</i>
-  <a href="#i_add">add</a> uint %0, %0           <i>; yields {uint}:%1</i>
-  %result = <a href="#i_add">add</a> uint %1, %1
+  <a href="#i_add">add</a> i32 %X, %X           <i>; yields {i32}:%0</i>
+  <a href="#i_add">add</a> i32 %0, %0           <i>; yields {i32}:%1</i>
+  %result = <a href="#i_add">add</a> i32 %1, %1
 </pre>
 
 <p>This last way of multiplying <tt>%X</tt> by 8 illustrates several
@@ -364,25 +365,25 @@
 
 <pre><i>; Declare the string constant as a global constant...</i>
 <a href="#identifiers">%.LC0</a> = <a href="#linkage_internal">internal</a> <a
- href="#globalvars">constant</a> <a href="#t_array">[13 x sbyte]</a> c"hello world\0A\00"          <i>; [13 x sbyte]*</i>
+ href="#globalvars">constant</a> <a href="#t_array">[13 x i8 ]</a> c"hello world\0A\00"          <i>; [13 x i8 ]*</i>
 
 <i>; External declaration of the puts function</i>
-<a href="#functionstructure">declare</a> int %puts(sbyte*)                                            <i>; int(sbyte*)* </i>
+<a href="#functionstructure">declare</a> i32 %puts(i8 *)                                            <i>; i32(i8 *)* </i>
 
 <i>; Global variable / Function body section separator</i>
 implementation
 
 <i>; Definition of main function</i>
-int %main() {                                                        <i>; int()* </i>
-        <i>; Convert [13x sbyte]* to sbyte *...</i>
+define i32 %main() {                                                 <i>; i32()* </i>
+        <i>; Convert [13x i8 ]* to i8  *...</i>
         %cast210 = <a
- href="#i_getelementptr">getelementptr</a> [13 x sbyte]* %.LC0, long 0, long 0 <i>; sbyte*</i>
+ href="#i_getelementptr">getelementptr</a> [13 x i8 ]* %.LC0, i64 0, i64 0 <i>; i8 *</i>
 
         <i>; Call puts function to write out the string to stdout...</i>
         <a
- href="#i_call">call</a> int %puts(sbyte* %cast210)                              <i>; int</i>
+ href="#i_call">call</a> i32 %puts(i8 * %cast210)                              <i>; i32</i>
         <a
- href="#i_ret">ret</a> int 0<br>}<br></pre>
+ href="#i_ret">ret</a> i32 0<br>}<br></pre>
 
 <p>This example is made up of a <a href="#globalvars">global variable</a>
 named "<tt>.LC0</tt>", an external declaration of the "<tt>puts</tt>"
@@ -440,7 +441,7 @@
 
   <dd>"<tt>weak</tt>" linkage is exactly the same as <tt>linkonce</tt> linkage,
   except that unreferenced <tt>weak</tt> globals may not be discarded.  This is
-  used to implement constructs in C such as "<tt>int X;</tt>" at global scope.
+  used to implement constructs in C such as "<tt>i32 X;</tt>" at global scope.
   </dd>
 
   <dt><tt><b><a name="linkage_appending">appending</a></b></tt>: </dt>
@@ -646,14 +647,18 @@
 
 <div class="doc_text">
 
-<p>LLVM function definitions consist of an optional <a href="#linkage">linkage
-type</a>, an optional <a href="#callingconv">calling convention</a>, a return
-type, a function name, a (possibly empty) argument list, an optional section,
-an optional alignment, an opening curly brace,
-a list of basic blocks, and a closing curly brace.  LLVM function declarations
-are defined with the "<tt>declare</tt>" keyword, an optional <a
-href="#callingconv">calling convention</a>, a return type, a function name,
-a possibly empty list of arguments, and an optional alignment.</p>
+<p>LLVM function definitions consist of the "<tt>define</tt>" keyord, 
+an optional <a href="#linkage">linkage type</a>, an optional 
+<a href="#callingconv">calling convention</a>, a return type, an optional
+<a href="#paramattrs">parameter attribute</a> for the return type, a function 
+name, a (possibly empty) argument list (each with optional 
+<a href="#paramattrs">parameter attributes</a>, an optional section, an optional
+alignment, an opening curly brace, a list of basic blocks, and a closing curly 
+brace.  LLVM function declarations
+are consist of the "<tt>declare</tt>" keyword, an optional <a
+  href="#callingconv">calling convention</a>, a return type, an optional
+<a href="#paramattrs">parameter attribute</a> for the return type, a function 
+name, a possibly empty list of arguments, and an optional alignment.</p>
 
 <p>A function definition contains a list of basic blocks, forming the CFG for
 the function.  Each basic block may optionally start with a label (giving the
@@ -684,6 +689,42 @@
 </div>
 
 <!-- ======================================================================= -->
+<div class="doc_subsection"><a name="paramattrs">Parameter Attributes</a></div>
+<div class="doc_text">
+  <p>The return type and each parameter of a function type may have a set of
+  <i>parameter attributes</i> associated with them. Parameter attributes are
+  used to communicate additional information about the result or parameters of
+  a function. Parameter attributes are considered to be part of the function
+  type so two functions types that differ only by the parameter attributes 
+  are different function types.</p>
+
+  <p>Parameter attributes consist of a at sign (@) followed by either a single
+  keyword or a comma separate list of keywords enclosed in parentheses. For
+  example:<pre>
+    %someFunc = i16 @zext (i8 @(sext) %someParam)
+    %someFunc = i16 @zext (i8 @zext %someParam)
+  </pre>Note that the two function types above are unique because the parameter
+  has a different attribute (@sext in the first one, @zext in the second).</p>
+
+  <p>Currently, only the following parameter attributes are defined:
+  <dl>
+    <dt><tt>@zext</tt></dt>
+    <dd>This indicates that the parameter should be zero extended just before
+    a call to this function.</dd>
+    <dt><tt>@sext</tt></dt>
+    <dd>This indicates that the parameter should be sign extended just before
+    a call to this function.</dd>
+  </dl></p>
+
+  <p>The current motivation for parameter attributes is to enable the sign and
+  zero extend information necessary for the C calling convention to be passed
+  from the front end to LLVM. The <tt>@zext</tt> and <tt>@sext</tt> attributes
+  are used by the code generator to perform the required extension. However, 
+  parameter attributes are an orthogonal feature to calling conventions and
+  may be used for other purposes in the future.</p>
+</div>
+
+<!-- ======================================================================= -->
 <div class="doc_subsection">
   <a name="moduleasm">Module-Level Inline Assembly</a>
 </div>
@@ -742,10 +783,8 @@
         <tbody>
         <tr><th>Type</th><th>Description</th></tr>
         <tr><td><tt>void</tt></td><td>No value</td></tr>
-        <tr><td><tt>ubyte</tt></td><td>Unsigned 8-bit value</td></tr>
-        <tr><td><tt>ushort</tt></td><td>Unsigned 16-bit value</td></tr>
-        <tr><td><tt>uint</tt></td><td>Unsigned 32-bit value</td></tr>
-        <tr><td><tt>ulong</tt></td><td>Unsigned 64-bit value</td></tr>
+        <tr><td><tt>i8</tt></td><td>Signless 8-bit value</td></tr>
+        <tr><td><tt>i32</tt></td><td>Signless 32-bit value</td></tr>
         <tr><td><tt>float</tt></td><td>32-bit floating point value</td></tr>
         <tr><td><tt>label</tt></td><td>Branch destination</td></tr>
         </tbody>
@@ -756,11 +795,9 @@
         <tbody>
           <tr><th>Type</th><th>Description</th></tr>
           <tr><td><tt>bool</tt></td><td>True or False value</td></tr>
-          <tr><td><tt>sbyte</tt></td><td>Signed 8-bit value</td></tr>
-          <tr><td><tt>short</tt></td><td>Signed 16-bit value</td></tr>
-          <tr><td><tt>int</tt></td><td>Signed 32-bit value</td></tr>
-          <tr><td><tt>long</tt></td><td>Signed 64-bit value</td></tr>
-          <tr><td><tt>double</tt></td><td>64-bit floating point value</td></tr>
+          <tr><td><tt>i16</tt></td><td>Signless 16-bit value</td></tr>
+          <tr><td><tt>i64</tt></td><td>Signless 64-bit value</td></tr>
+         <tr><td><tt>double</tt></td><td>64-bit floating point value</td></tr>
         </tbody>
       </table>
     </td>
@@ -779,20 +816,12 @@
   <tbody>
     <tr><th>Classification</th><th>Types</th></tr>
     <tr>
-      <td><a name="t_signed">signed</a></td>
-      <td><tt>sbyte, short, int, long, float, double</tt></td>
-    </tr>
-    <tr>
-      <td><a name="t_unsigned">unsigned</a></td>
-      <td><tt>ubyte, ushort, uint, ulong</tt></td>
-    </tr>
-    <tr>
       <td><a name="t_integer">integer</a></td>
-      <td><tt>ubyte, sbyte, ushort, short, uint, int, ulong, long</tt></td>
+      <td><tt>i8, i16, i32, i64</tt></td>
     </tr>
     <tr>
       <td><a name="t_integral">integral</a></td>
-      <td><tt>bool, ubyte, sbyte, ushort, short, uint, int, ulong, long</tt>
+      <td><tt>bool, i8, i16, i32, i64</tt>
       </td>
     </tr>
     <tr>
@@ -801,9 +830,9 @@
     </tr>
     <tr>
       <td><a name="t_firstclass">first class</a></td>
-      <td><tt>bool, ubyte, sbyte, ushort, short, uint, int, ulong, long,<br> 
-      float, double, <a href="#t_pointer">pointer</a>, 
-      <a href="#t_packed">packed</a></tt></td>
+      <td><tt>bool, i8, i16, i32, i64, float, double, <br/>
+          <a href="#t_pointer">pointer</a>,<a href="#t_packed">packed</a></tt>
+      </td>
     </tr>
   </tbody>
 </table>
@@ -851,9 +880,9 @@
 <table class="layout">
   <tr class="layout">
     <td class="left">
-      <tt>[40 x int ]</tt><br/>
-      <tt>[41 x int ]</tt><br/>
-      <tt>[40 x uint]</tt><br/>
+      <tt>[40 x i32 ]</tt><br/>
+      <tt>[41 x i32 ]</tt><br/>
+      <tt>[40 x i32]</tt><br/>
     </td>
     <td class="left">
       Array of 40 integer values.<br/>
@@ -866,9 +895,9 @@
 <table class="layout">
   <tr class="layout">
     <td class="left">
-      <tt>[3 x [4 x int]]</tt><br/>
+      <tt>[3 x [4 x i32]]</tt><br/>
       <tt>[12 x [10 x float]]</tt><br/>
-      <tt>[2 x [3 x [4 x uint]]]</tt><br/>
+      <tt>[2 x [3 x [4 x i32]]]</tt><br/>
     </td>
     <td class="left">
       3x4 array of integer values.<br/>
@@ -883,7 +912,7 @@
 LLVM (e.g. it is illegal to access the 5th element of a 3 element array).
 As a special case, however, zero length arrays are recognized to be variable
 length.  This allows implementation of 'pascal style arrays' with the  LLVM
-type "{ int, [0 x float]}", for example.</p>
+type "{ i32, [0 x float]}", for example.</p>
 
 </div>
 
@@ -910,17 +939,18 @@
 <table class="layout">
   <tr class="layout">
     <td class="left">
-      <tt>int (int)</tt> <br/>
-      <tt>float (int, int *) *</tt><br/>
-      <tt>int (sbyte *, ...)</tt><br/>
+      <tt>i32 (i32)</tt> <br/>
+      <tt>float (i16 @sext, i32 *) *</tt><br/>
+      <tt>i32 (i8*, ...)</tt><br/>
     </td>
     <td class="left">
-      function taking an <tt>int</tt>, returning an <tt>int</tt><br/>
+      function taking an <tt>i32</tt>, returning an <tt>i32</tt><br/>
       <a href="#t_pointer">Pointer</a> to a function that takes an
-      <tt>int</tt> and a <a href="#t_pointer">pointer</a> to <tt>int</tt>,
-      returning <tt>float</tt>.<br/>
-      A vararg function that takes at least one <a href="#t_pointer">pointer</a> 
-      to <tt>sbyte</tt> (signed char in C), which returns an integer.  This is 
+      <tt>i16</tt> that should be sign extended and a 
+      <a href="#t_pointer">pointer</a> to <tt>i32</tt>, returning 
+      <tt>float</tt>.<br/>
+      A vararg function that takes at least one <a href="#t_pointer">pointer</a>
+      to <tt>i8 </tt> (signed char in C), which returns an integer.  This is 
       the signature for <tt>printf</tt> in LLVM.<br/>
     </td>
   </tr>
@@ -945,14 +975,14 @@
 <table class="layout">
   <tr class="layout">
     <td class="left">
-      <tt>{ int, int, int }</tt><br/>
-      <tt>{ float, int (int) * }</tt><br/>
+      <tt>{ i32, i32, i32 }</tt><br/>
+      <tt>{ float, i32 (i32) * }</tt><br/>
     </td>
     <td class="left">
-      a triple of three <tt>int</tt> values<br/>
+      a triple of three <tt>i32</tt> values<br/>
       A pair, where the first element is a <tt>float</tt> and the second element 
       is a <a href="#t_pointer">pointer</a> to a <a href="#t_function">function</a> 
-      that takes an <tt>int</tt>, returning an <tt>int</tt>.<br/>
+      that takes an <tt>i32</tt>, returning an <tt>i32</tt>.<br/>
     </td>
   </tr>
 </table>
@@ -977,14 +1007,14 @@
 <table class="layout">
   <tr class="layout">
     <td class="left">
-      <tt> < { int, int, int } > </tt><br/>
-      <tt> < { float, int (int) * } > </tt><br/>
+      <tt> < { i32, i32, i32 } > </tt><br/>
+      <tt> < { float, i32 (i32) * } > </tt><br/>
     </td>
     <td class="left">
-      a triple of three <tt>int</tt> values<br/>
+      a triple of three <tt>i32</tt> values<br/>
       A pair, where the first element is a <tt>float</tt> and the second element 
       is a <a href="#t_pointer">pointer</a> to a <a href="#t_function">function</a> 
-      that takes an <tt>int</tt>, returning an <tt>int</tt>.<br/>
+      that takes an <tt>i32</tt>, returning an <tt>i32</tt>.<br/>
     </td>
   </tr>
 </table>
@@ -1002,15 +1032,15 @@
 <table class="layout">
   <tr class="layout">
     <td class="left">
-      <tt>[4x int]*</tt><br/>
-      <tt>int (int *) *</tt><br/>
+      <tt>[4x i32]*</tt><br/>
+      <tt>i32 (i32 *) *</tt><br/>
     </td>
     <td class="left">
       A <a href="#t_pointer">pointer</a> to <a href="#t_array">array</a> of
-      four <tt>int</tt> values<br/>
+      four <tt>i32</tt> values<br/>
       A <a href="#t_pointer">pointer</a> to a <a
-      href="#t_function">function</a> that takes an <tt>int*</tt>, returning an
-      <tt>int</tt>.<br/>
+      href="#t_function">function</a> that takes an <tt>i32*</tt>, returning an
+      <tt>i32</tt>.<br/>
     </td>
   </tr>
 </table>
@@ -1044,9 +1074,9 @@
 <table class="layout">
   <tr class="layout">
     <td class="left">
-      <tt><4 x int></tt><br/>
+      <tt><4 x i32></tt><br/>
       <tt><8 x float></tt><br/>
-      <tt><2 x uint></tt><br/>
+      <tt><2 x i32></tt><br/>
     </td>
     <td class="left">
       Packed vector of 4 integer values.<br/>
@@ -1158,8 +1188,8 @@
 
   <dd>Structure constants are represented with notation similar to structure
   type definitions (a comma separated list of elements, surrounded by braces
-  (<tt>{}</tt>)).  For example: "<tt>{ int 4, float 17.0, int* %G }</tt>",
-  where "<tt>%G</tt>" is declared as "<tt>%G = external global int</tt>".  Structure constants
+  (<tt>{}</tt>)).  For example: "<tt>{ i32 4, float 17.0, i32* %G }</tt>",
+  where "<tt>%G</tt>" is declared as "<tt>%G = external global i32</tt>".  Structure constants
   must have <a href="#t_struct">structure type</a>, and the number and
   types of elements must match those specified by the type.
   </dd>
@@ -1168,7 +1198,7 @@
 
   <dd>Array constants are represented with notation similar to array type
   definitions (a comma separated list of elements, surrounded by square brackets
-  (<tt>[]</tt>)).  For example: "<tt>[ int 42, int 11, int 74 ]</tt>".  Array
+  (<tt>[]</tt>)).  For example: "<tt>[ i32 42, i32 11, i32 74 ]</tt>".  Array
   constants must have <a href="#t_array">array type</a>, and the number and
   types of elements must match those specified by the type.
   </dd>
@@ -1177,8 +1207,8 @@
 
   <dd>Packed constants are represented with notation similar to packed type
   definitions (a comma separated list of elements, surrounded by
-  less-than/greater-than's (<tt><></tt>)).  For example: "<tt>< int 42,
-  int 11, int 74, int 100 ></tt>".  Packed constants must have <a
+  less-than/greater-than's (<tt><></tt>)).  For example: "<tt>< i32 42,
+  i32 11, i32 74, i32 100 ></tt>".  Packed constants must have <a
   href="#t_packed">packed type</a>, and the number and types of elements must
   match those specified by the type.
   </dd>
@@ -1210,9 +1240,9 @@
 file:</p>
 
 <pre>
-  %X = global int 17
-  %Y = global int 42
-  %Z = global [2 x int*] [ int* %X, int* %Y ]
+  %X = global i32 17
+  %Y = global i32 42
+  %Z = global [2 x i32*] [ i32* %X, i32* %Y ]
 </pre>
 
 </div>
@@ -1368,7 +1398,7 @@
 </p>
 
 <pre>
-  int(int) asm "bswap $0", "=r,r"
+  i32 (i32) asm "bswap $0", "=r,r"
 </pre>
 
 <p>
@@ -1377,7 +1407,7 @@
 </p>
 
 <pre>
-  %X = call int asm "<a href="#i_bswap">bswap</a> $0", "=r,r"(int %Y)
+  %X = call i32 asm "<a href="#i_bswap">bswap</a> $0", "=r,r"(i32 %Y)
 </pre>
 
 <p>
@@ -1463,7 +1493,7 @@
 returns a value, that value shall set the call or invoke instruction's
 return value.</p>
 <h5>Example:</h5>
-<pre>  ret int 5                       <i>; Return an integer value of 5</i>
+<pre>  ret i32 5                       <i>; Return an integer value of 5</i>
   ret void                        <i>; Return from a void function</i>
 </pre>
 </div>
@@ -1489,8 +1519,8 @@
 to the '<tt>iftrue</tt>' <tt>label</tt> argument.  If "cond" is <tt>false</tt>,
 control flows to the '<tt>iffalse</tt>' <tt>label</tt> argument.</p>
 <h5>Example:</h5>
-<pre>Test:<br>  %cond = <a href="#i_icmp">icmp</a> eq, int %a, %b<br>  br bool %cond, label %IfEqual, label %IfUnequal<br>IfEqual:<br>  <a
- href="#i_ret">ret</a> int 1<br>IfUnequal:<br>  <a href="#i_ret">ret</a> int 0<br></pre>
+<pre>Test:<br>  %cond = <a href="#i_icmp">icmp</a> eq, i32 %a, %b<br>  br bool %cond, label %IfEqual, label %IfUnequal<br>IfEqual:<br>  <a
+ href="#i_ret">ret</a> i32 1<br>IfUnequal:<br>  <a href="#i_ret">ret</a> i32 0<br></pre>
 </div>
 <!-- _______________________________________________________________________ -->
 <div class="doc_subsubsection">
@@ -1538,16 +1568,16 @@
 
 <pre>
  <i>; Emulate a conditional br instruction</i>
- %Val = <a href="#i_zext">zext</a> bool %value to int
- switch int %Val, label %truedest [int 0, label %falsedest ]
+ %Val = <a href="#i_zext">zext</a> bool %value to i32
+ switch i32 %Val, label %truedest [i32 0, label %falsedest ]
 
  <i>; Emulate an unconditional br instruction</i>
- switch uint 0, label %dest [ ]
+ switch i32 0, label %dest [ ]
 
  <i>; Implement a jump table:</i>
- switch uint %val, label %otherwise [ uint 0, label %onzero 
-                                      uint 1, label %onone 
-                                      uint 2, label %ontwo ]
+ switch i32 %val, label %otherwise [ i32 0, label %onzero 
+                                      i32 1, label %onone 
+                                      i32 2, label %ontwo ]
 </pre>
 </div>
 
@@ -1622,10 +1652,10 @@
 
 <h5>Example:</h5>
 <pre>
-  %retval = invoke int %Test(int 15)             to label %Continue
-              unwind label %TestCleanup     <i>; {int}:retval set</i>
-  %retval = invoke <a href="#callingconv">coldcc</a> int %Test(int 15)             to label %Continue
-              unwind label %TestCleanup     <i>; {int}:retval set</i>
+  %retval = invoke i32 %Test(i32 15)             to label %Continue
+              unwind label %TestCleanup     <i>; {i32}:retval set</i>
+  %retval = invoke <a href="#callingconv">coldcc</a> i32 %Test(i32 15)             to label %Continue
+              unwind label %TestCleanup     <i>; {i32}:retval set</i>
 </pre>
 </div>
 
@@ -1714,7 +1744,7 @@
 <p>The value produced is the integer or floating point sum of the two
 operands.</p>
 <h5>Example:</h5>
-<pre>  <result> = add int 4, %var          <i>; yields {int}:result = 4 + %var</i>
+<pre>  <result> = add i32 4, %var          <i>; yields {i32}:result = 4 + %var</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -1739,8 +1769,8 @@
 <p>The value produced is the integer or floating point difference of
 the two operands.</p>
 <h5>Example:</h5>
-<pre>  <result> = sub int 4, %var          <i>; yields {int}:result = 4 - %var</i>
-  <result> = sub int 0, %val          <i>; yields {int}:result = -%var</i>
+<pre>  <result> = sub i32 4, %var          <i>; yields {i32}:result = 4 - %var</i>
+  <result> = sub i32 0, %val          <i>; yields {i32}:result = -%var</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -1765,7 +1795,7 @@
 <p>There is no signed vs unsigned multiplication.  The appropriate
 action is taken based on the type of the operand.</p>
 <h5>Example:</h5>
-<pre>  <result> = mul int 4, %var          <i>; yields {int}:result = 4 * %var</i>
+<pre>  <result> = mul i32 4, %var          <i>; yields {i32}:result = 4 * %var</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -1788,7 +1818,7 @@
 instruction always performs an unsigned division operation, regardless of 
 whether the arguments are unsigned or not.</p>
 <h5>Example:</h5>
-<pre>  <result> = udiv uint 4, %var          <i>; yields {uint}:result = 4 / %var</i>
+<pre>  <result> = udiv i32 4, %var          <i>; yields {i32}:result = 4 / %var</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -1811,7 +1841,7 @@
 instruction always performs a signed division operation, regardless of whether
 the arguments are signed or not.</p>
 <h5>Example:</h5>
-<pre>  <result> = sdiv int 4, %var          <i>; yields {int}:result = 4 / %var</i>
+<pre>  <result> = sdiv i32 4, %var          <i>; yields {i32}:result = 4 / %var</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -1854,7 +1884,7 @@
 This instruction always performs an unsigned division to get the remainder,
 regardless of whether the arguments are unsigned or not.</p>
 <h5>Example:</h5>
-<pre>  <result> = urem uint 4, %var          <i>; yields {uint}:result = 4 % %var</i>
+<pre>  <result> = urem i32 4, %var          <i>; yields {i32}:result = 4 % %var</i>
 </pre>
 
 </div>
@@ -1880,7 +1910,7 @@
  href="http://mathforum.org/dr.math/problems/anne.4.28.99.html">The
 Math Forum</a>.</p>
 <h5>Example:</h5>
-<pre>  <result> = srem int 4, %var          <i>; yields {int}:result = 4 % %var</i>
+<pre>  <result> = srem i32 4, %var          <i>; yields {i32}:result = 4 % %var</i>
 </pre>
 
 </div>
@@ -1965,9 +1995,9 @@
 </table>
 </div>
 <h5>Example:</h5>
-<pre>  <result> = and int 4, %var         <i>; yields {int}:result = 4 & %var</i>
-  <result> = and int 15, 40          <i>; yields {int}:result = 8</i>
-  <result> = and int 4, 8            <i>; yields {int}:result = 0</i>
+<pre>  <result> = and i32 4, %var         <i>; yields {i32}:result = 4 & %var</i>
+  <result> = and i32 15, 40          <i>; yields {i32}:result = 8</i>
+  <result> = and i32 4, 8            <i>; yields {i32}:result = 0</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -2018,9 +2048,9 @@
 </table>
 </div>
 <h5>Example:</h5>
-<pre>  <result> = or int 4, %var         <i>; yields {int}:result = 4 | %var</i>
-  <result> = or int 15, 40          <i>; yields {int}:result = 47</i>
-  <result> = or int 4, 8            <i>; yields {int}:result = 12</i>
+<pre>  <result> = or i32 4, %var         <i>; yields {i32}:result = 4 | %var</i>
+  <result> = or i32 15, 40          <i>; yields {i32}:result = 47</i>
+  <result> = or i32 4, 8            <i>; yields {i32}:result = 12</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -2074,10 +2104,10 @@
 </div>
 <p> </p>
 <h5>Example:</h5>
-<pre>  <result> = xor int 4, %var         <i>; yields {int}:result = 4 ^ %var</i>
-  <result> = xor int 15, 40          <i>; yields {int}:result = 39</i>
-  <result> = xor int 4, 8            <i>; yields {int}:result = 12</i>
-  <result> = xor int %V, -1          <i>; yields {int}:result = ~%V</i>
+<pre>  <result> = xor i32 4, %var         <i>; yields {i32}:result = 4 ^ %var</i>
+  <result> = xor i32 15, 40          <i>; yields {i32}:result = 39</i>
+  <result> = xor i32 4, 8            <i>; yields {i32}:result = 12</i>
+  <result> = xor i32 %V, -1          <i>; yields {i32}:result = ~%V</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -2085,21 +2115,21 @@
 Instruction</a> </div>
 <div class="doc_text">
 <h5>Syntax:</h5>
-<pre>  <result> = shl <ty> <var1>, ubyte <var2>   <i>; yields {ty}:result</i>
+<pre>  <result> = shl <ty> <var1>, i8 <var2>   <i>; yields {ty}:result</i>
 </pre>
 <h5>Overview:</h5>
 <p>The '<tt>shl</tt>' instruction returns the first operand shifted to
 the left a specified number of bits.</p>
 <h5>Arguments:</h5>
 <p>The first argument to the '<tt>shl</tt>' instruction must be an <a
- href="#t_integer">integer</a> type.  The second argument must be an '<tt>ubyte</tt>'
+ href="#t_integer">integer</a> type.  The second argument must be an '<tt>i8</tt>'
 type.</p>
 <h5>Semantics:</h5>
 <p>The value produced is <tt>var1</tt> * 2<sup><tt>var2</tt></sup>.</p>
 <h5>Example:</h5>
-<pre>  <result> = shl int 4, ubyte %var   <i>; yields {int}:result = 4 << %var</i>
-  <result> = shl int 4, ubyte 2      <i>; yields {int}:result = 16</i>
-  <result> = shl int 1, ubyte 10     <i>; yields {int}:result = 1024</i>
+<pre>  <result> = shl i32 4, i8 %var   <i>; yields {i32}:result = 4 << %var</i>
+  <result> = shl i32 4, i8 2      <i>; yields {i32}:result = 16</i>
+  <result> = shl i32 1, i8 10     <i>; yields {i32}:result = 1024</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -2107,7 +2137,7 @@
 Instruction</a> </div>
 <div class="doc_text">
 <h5>Syntax:</h5>
-<pre>  <result> = lshr <ty> <var1>, ubyte <var2>   <i>; yields {ty}:result</i>
+<pre>  <result> = lshr <ty> <var1>, i8 <var2>   <i>; yields {ty}:result</i>
 </pre>
 
 <h5>Overview:</h5>
@@ -2116,7 +2146,7 @@
 
 <h5>Arguments:</h5>
 <p>The first argument to the '<tt>lshr</tt>' instruction must be an <a
- href="#t_integer">integer</a> type.  The second argument must be an '<tt>ubyte</tt>' type.</p>
+ href="#t_integer">integer</a> type.  The second argument must be an '<tt>i8</tt>' type.</p>
 
 <h5>Semantics:</h5>
 <p>This instruction always performs a logical shift right operation, regardless
@@ -2125,10 +2155,10 @@
 
 <h5>Example:</h5>
 <pre>
-  <result> = lshr uint 4, ubyte 1   <i>; yields {uint}:result = 2</i>
-  <result> = lshr int 4, ubyte 2    <i>; yields {uint}:result = 1</i>
-  <result> = lshr sbyte 4, ubyte 3  <i>; yields {sbyte}:result = 0</i>
-  <result> = lshr sbyte -2, ubyte 1 <i>; yields {sbyte}:result = 0x7FFFFFFF </i>
+  <result> = lshr i32 4, i8 1   <i>; yields {i32}:result = 2</i>
+  <result> = lshr i32 4, i8 2    <i>; yields {i32}:result = 1</i>
+  <result> = lshr i8  4, i8 3  <i>; yields {i8 }:result = 0</i>
+  <result> = lshr i8  -2, i8 1 <i>; yields {i8 }:result = 0x7FFFFFFF </i>
 </pre>
 </div>
 
@@ -2138,7 +2168,7 @@
 <div class="doc_text">
 
 <h5>Syntax:</h5>
-<pre>  <result> = ashr <ty> <var1>, ubyte <var2>   <i>; yields {ty}:result</i>
+<pre>  <result> = ashr <ty> <var1>, i8 <var2>   <i>; yields {ty}:result</i>
 </pre>
 
 <h5>Overview:</h5>
@@ -2148,7 +2178,7 @@
 <h5>Arguments:</h5>
 <p>The first argument to the '<tt>ashr</tt>' instruction must be an 
 <a href="#t_integer">integer</a> type.  The second argument must be an
-'<tt>ubyte</tt>' type.</p>
+'<tt>i8</tt>' type.</p>
 
 <h5>Semantics:</h5>
 <p>This instruction always performs an arithmetic shift right operation, 
@@ -2157,10 +2187,10 @@
 
 <h5>Example:</h5>
 <pre>
-  <result> = ashr uint 4, ubyte 1    <i>; yields {uint}:result = 2</i>
-  <result> = ashr int 4, ubyte 2      <i>; yields {int}:result = 1</i>
-  <result> = ashr ubyte 4, ubyte 3    <i>; yields {ubyte}:result = 0</i>
-  <result> = ashr sbyte -2, ubyte 1   <i>; yields {sbyte}:result = -1</i>
+  <result> = ashr i32 4, i8 1    <i>; yields {i32}:result = 2</i>
+  <result> = ashr i32 4, i8 2      <i>; yields {i32}:result = 1</i>
+  <result> = ashr i8 4, i8 3    <i>; yields {i8}:result = 0</i>
+  <result> = ashr i8  -2, i8 1   <i>; yields {i8 }:result = -1</i>
 </pre>
 </div>
 
@@ -2190,7 +2220,7 @@
 <h5>Syntax:</h5>
 
 <pre>
-  <result> = extractelement <n x <ty>> <val>, uint <idx>    <i>; yields <ty></i>
+  <result> = extractelement <n x <ty>> <val>, i32 <idx>    <i>; yields <ty></i>
 </pre>
 
 <h5>Overview:</h5>
@@ -2221,7 +2251,7 @@
 <h5>Example:</h5>
 
 <pre>
-  %result = extractelement <4 x int> %vec, uint 0    <i>; yields int</i>
+  %result = extractelement <4 x i32> %vec, i32 0    <i>; yields i32</i>
 </pre>
 </div>
 
@@ -2236,7 +2266,7 @@
 <h5>Syntax:</h5>
 
 <pre>
-  <result> = insertelement <n x <ty>> <val>, <ty> <elt&gt, uint <idx>    <i>; yields <n x <ty>></i>
+  <result> = insertelement <n x <ty>> <val>, <ty> <elt&gt, i32 <idx>    <i>; yields <n x <ty>></i>
 </pre>
 
 <h5>Overview:</h5>
@@ -2268,7 +2298,7 @@
 <h5>Example:</h5>
 
 <pre>
-  %result = insertelement <4 x int> %vec, int 1, uint 0    <i>; yields <4 x int></i>
+  %result = insertelement <4 x i32> %vec, i32 1, i32 0    <i>; yields <4 x i32></i>
 </pre>
 </div>
 
@@ -2282,7 +2312,7 @@
 <h5>Syntax:</h5>
 
 <pre>
-  <result> = shufflevector <n x <ty>> <v1>, <n x <ty>> <v2>, <n x uint> <mask>    <i>; yields <n x <ty>></i>
+  <result> = shufflevector <n x <ty>> <v1>, <n x <ty>> <v2>, <n x i32> <mask>    <i>; yields <n x <ty>></i>
 </pre>
 
 <h5>Overview:</h5>
@@ -2298,7 +2328,7 @@
 The first two operands of a '<tt>shufflevector</tt>' instruction are vectors
 with types that match each other and types that match the result of the
 instruction.  The third argument is a shuffle mask, which has the same number
-of elements as the other vector type, but whose element type is always 'uint'.
+of elements as the other vector type, but whose element type is always 'i32'.
 </p>
 
 <p>
@@ -2319,10 +2349,10 @@
 <h5>Example:</h5>
 
 <pre>
-  %result = shufflevector <4 x int> %v1, <4 x int> %v2, 
-                          <4 x uint> <uint 0, uint 4, uint 1, uint 5>    <i>; yields <4 x int></i>
-  %result = shufflevector <4 x int> %v1, <4 x int> undef, 
-                          <4 x uint> <uint 0, uint 1, uint 2, uint 3>  <i>; yields <4 x int></i> - Identity shuffle.
+  %result = shufflevector <4 x i32> %v1, <4 x i32> %v2, 
+                          <4 x i32> <i32 0, i32 4, i32 1, i32 5>    <i>; yields <4 x i32></i>
+  %result = shufflevector <4 x i32> %v1, <4 x i32> undef, 
+                          <4 x i32> <i32 0, i32 1, i32 2, i32 3>  <i>; yields <4 x i32></i> - Identity shuffle.
 </pre>
 </div>
 
@@ -2351,7 +2381,7 @@
 <h5>Syntax:</h5>
 
 <pre>
-  <result> = malloc <type>[, uint <NumElements>][, align <alignment>]     <i>; yields {type*}:result</i>
+  <result> = malloc <type>[, i32 <NumElements>][, align <alignment>]     <i>; yields {type*}:result</i>
 </pre>
 
 <h5>Overview:</h5>
@@ -2380,13 +2410,13 @@
 <h5>Example:</h5>
 
 <pre>
-  %array  = malloc [4 x ubyte ]                    <i>; yields {[%4 x ubyte]*}:array</i>
+  %array  = malloc [4 x i8 ]                    <i>; yields {[%4 x i8]*}:array</i>
 
-  %size   = <a href="#i_add">add</a> uint 2, 2                          <i>; yields {uint}:size = uint 4</i>
-  %array1 = malloc ubyte, uint 4                   <i>; yields {ubyte*}:array1</i>
-  %array2 = malloc [12 x ubyte], uint %size        <i>; yields {[12 x ubyte]*}:array2</i>
-  %array3 = malloc int, uint 4, align 1024         <i>; yields {int*}:array3</i>
-  %array4 = malloc int, align 1024                 <i>; yields {int*}:array4</i>
+  %size   = <a href="#i_add">add</a> i32 2, 2                          <i>; yields {i32}:size = i32 4</i>
+  %array1 = malloc i8, i32 4                   <i>; yields {i8*}:array1</i>
+  %array2 = malloc [12 x i8], i32 %size        <i>; yields {[12 x i8]*}:array2</i>
+  %array3 = malloc i32, i32 4, align 1024         <i>; yields {i32*}:array3</i>
+  %array4 = malloc i32, align 1024                 <i>; yields {i32*}:array4</i>
 </pre>
 </div>
 
@@ -2422,8 +2452,8 @@
 <h5>Example:</h5>
 
 <pre>
-  %array  = <a href="#i_malloc">malloc</a> [4 x ubyte]                    <i>; yields {[4 x ubyte]*}:array</i>
-            free   [4 x ubyte]* %array
+  %array  = <a href="#i_malloc">malloc</a> [4 x i8]                    <i>; yields {[4 x i8]*}:array</i>
+            free   [4 x i8]* %array
 </pre>
 </div>
 
@@ -2437,7 +2467,7 @@
 <h5>Syntax:</h5>
 
 <pre>
-  <result> = alloca <type>[, uint <NumElements>][, align <alignment>]     <i>; yields {type*}:result</i>
+  <result> = alloca <type>[, i32 <NumElements>][, align <alignment>]     <i>; yields {type*}:result</i>
 </pre>
 
 <h5>Overview:</h5>
@@ -2470,10 +2500,10 @@
 <h5>Example:</h5>
 
 <pre>
-  %ptr = alloca int                              <i>; yields {int*}:ptr</i>
-  %ptr = alloca int, uint 4                      <i>; yields {int*}:ptr</i>
-  %ptr = alloca int, uint 4, align 1024          <i>; yields {int*}:ptr</i>
-  %ptr = alloca int, align 1024                  <i>; yields {int*}:ptr</i>
+  %ptr = alloca i32                              <i>; yields {i32*}:ptr</i>
+  %ptr = alloca i32, i32 4                      <i>; yields {i32*}:ptr</i>
+  %ptr = alloca i32, i32 4, align 1024          <i>; yields {i32*}:ptr</i>
+  %ptr = alloca i32, align 1024                  <i>; yields {i32*}:ptr</i>
 </pre>
 </div>
 
@@ -2496,10 +2526,10 @@
 <h5>Semantics:</h5>
 <p>The location of memory pointed to is loaded.</p>
 <h5>Examples:</h5>
-<pre>  %ptr = <a href="#i_alloca">alloca</a> int                               <i>; yields {int*}:ptr</i>
+<pre>  %ptr = <a href="#i_alloca">alloca</a> i32                               <i>; yields {i32*}:ptr</i>
   <a
- href="#i_store">store</a> int 3, int* %ptr                          <i>; yields {void}</i>
-  %val = load int* %ptr                           <i>; yields {int}:val = int 3</i>
+ href="#i_store">store</a> i32 3, i32* %ptr                          <i>; yields {void}</i>
+  %val = load i32* %ptr                           <i>; yields {i32}:val = i32 3</i>
 </pre>
 </div>
 <!-- _______________________________________________________________________ -->
@@ -2524,10 +2554,10 @@
 <p>The contents of memory are updated to contain '<tt><value></tt>'
 at the location specified by the '<tt><pointer></tt>' operand.</p>
 <h5>Example:</h5>
-<pre>  %ptr = <a href="#i_alloca">alloca</a> int                               <i>; yields {int*}:ptr</i>
+<pre>  %ptr = <a href="#i_alloca">alloca</a> i32                               <i>; yields {i32*}:ptr</i>
   <a
- href="#i_store">store</a> int 3, int* %ptr                          <i>; yields {void}</i>
-  %val = load int* %ptr                           <i>; yields {int}:val = int 3</i>
+ href="#i_store">store</a> i32 3, i32* %ptr                          <i>; yields {void}</i>
+  %val = load i32* %ptr                           <i>; yields {i32}:val = i32 3</i>
 </pre>
 </div>
 
@@ -2555,7 +2585,7 @@
 provided depend on the type of the first pointer argument.  The
 '<tt>getelementptr</tt>' instruction is used to index down through the type
 levels of a structure or to a specific index in an array.  When indexing into a
-structure, only <tt>uint</tt> integer constants are allowed.  When indexing 
+structure, only <tt>i32</tt> integer constants are allowed.  When indexing 
 into an array or pointer, only integers of 32 or 64 bits are allowed, and will 
 be sign extended to 64-bit values.</p>
 
@@ -2565,16 +2595,16 @@
 <pre>
   struct RT {
     char A;
-    int B[10][20];
+    i32 B[10][20];
     char C;
   };
   struct ST {
-    int X;
+    i32 X;
     double Y;
     struct RT Z;
   };
 
-  int *foo(struct ST *s) {
+  define i32 *foo(struct ST *s) {
     return &s[1].Z.B[5][13];
   }
 </pre>
@@ -2582,15 +2612,15 @@
 <p>The LLVM code generated by the GCC frontend is:</p>
 
 <pre>
-  %RT = type { sbyte, [10 x [20 x int]], sbyte }
-  %ST = type { int, double, %RT }
+  %RT = type { i8 , [10 x [20 x i32]], i8  }
+  %ST = type { i32, double, %RT }
 
   implementation
 
-  int* %foo(%ST* %s) {
+  define i32* %foo(%ST* %s) {
   entry:
-    %reg = getelementptr %ST* %s, int 1, uint 2, uint 1, int 5, int 13
-    ret int* %reg
+    %reg = getelementptr %ST* %s, i32 1, i32 2, i32 1, i32 5, i32 13
+    ret i32* %reg
   }
 </pre>
 
@@ -2600,31 +2630,31 @@
 on the pointer type that is being indexed into. <a href="#t_pointer">Pointer</a>
 and <a href="#t_array">array</a> types can use a 32-bit or 64-bit
 <a href="#t_integer">integer</a> type but the value will always be sign extended
-to 64-bits.  <a href="#t_struct">Structure</a> types, require <tt>uint</tt>
+to 64-bits.  <a href="#t_struct">Structure</a> types, require <tt>i32</tt>
 <b>constants</b>.</p>
 
 <p>In the example above, the first index is indexing into the '<tt>%ST*</tt>'
-type, which is a pointer, yielding a '<tt>%ST</tt>' = '<tt>{ int, double, %RT
+type, which is a pointer, yielding a '<tt>%ST</tt>' = '<tt>{ i32, double, %RT
 }</tt>' type, a structure.  The second index indexes into the third element of
-the structure, yielding a '<tt>%RT</tt>' = '<tt>{ sbyte, [10 x [20 x int]],
-sbyte }</tt>' type, another structure.  The third index indexes into the second
-element of the structure, yielding a '<tt>[10 x [20 x int]]</tt>' type, an
+the structure, yielding a '<tt>%RT</tt>' = '<tt>{ i8 , [10 x [20 x i32]],
+i8  }</tt>' type, another structure.  The third index indexes into the second
+element of the structure, yielding a '<tt>[10 x [20 x i32]]</tt>' type, an
 array.  The two dimensions of the array are subscripted into, yielding an
-'<tt>int</tt>' type.  The '<tt>getelementptr</tt>' instruction returns a pointer
-to this element, thus computing a value of '<tt>int*</tt>' type.</p>
+'<tt>i32</tt>' type.  The '<tt>getelementptr</tt>' instruction returns a pointer
+to this element, thus computing a value of '<tt>i32*</tt>' type.</p>
 
 <p>Note that it is perfectly legal to index partially through a
 structure, returning a pointer to an inner element.  Because of this,
 the LLVM code for the given testcase is equivalent to:</p>
 
 <pre>
-  int* %foo(%ST* %s) {
-    %t1 = getelementptr %ST* %s, int 1                        <i>; yields %ST*:%t1</i>
-    %t2 = getelementptr %ST* %t1, int 0, uint 2               <i>; yields %RT*:%t2</i>
-    %t3 = getelementptr %RT* %t2, int 0, uint 1               <i>; yields [10 x [20 x int]]*:%t3</i>
-    %t4 = getelementptr [10 x [20 x int]]* %t3, int 0, int 5  <i>; yields [20 x int]*:%t4</i>
-    %t5 = getelementptr [20 x int]* %t4, int 0, int 13        <i>; yields int*:%t5</i>
-    ret int* %t5
+  define i32* %foo(%ST* %s) {
+    %t1 = getelementptr %ST* %s, i32 1                        <i>; yields %ST*:%t1</i>
+    %t2 = getelementptr %ST* %t1, i32 0, i32 2               <i>; yields %RT*:%t2</i>
+    %t3 = getelementptr %RT* %t2, i32 0, i32 1               <i>; yields [10 x [20 x i32]]*:%t3</i>
+    %t4 = getelementptr [10 x [20 x i32]]* %t3, i32 0, i32 5  <i>; yields [20 x i32]*:%t4</i>
+    %t5 = getelementptr [20 x i32]* %t4, i32 0, i32 13        <i>; yields i32*:%t5</i>
+    ret i32* %t5
   }
 </pre>
 
@@ -2641,8 +2671,8 @@
 <h5>Example:</h5>
 
 <pre>
-    <i>; yields [12 x ubyte]*:aptr</i>
-    %aptr = getelementptr {int, [12 x ubyte]}* %sptr, long 0, uint 1
+    <i>; yields [12 x i8]*:aptr</i>
+    %aptr = getelementptr {i32, [12 x i8]}* %sptr, i64 0, i32 1
 </pre>
 </div>
 
@@ -2688,8 +2718,8 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = trunc int 257 to ubyte              <i>; yields ubyte:1</i>
-  %Y = trunc int 123 to bool               <i>; yields bool:true</i>
+  %X = trunc i32 257 to i8              <i>; yields i8:1</i>
+  %Y = trunc i32 123 to bool               <i>; yields bool:true</i>
 </pre>
 </div>
 
@@ -2727,8 +2757,8 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = zext int 257 to ulong              <i>; yields ulong:257</i>
-  %Y = zext bool true to int              <i>; yields int:1</i>
+  %X = zext i32 257 to i64              <i>; yields i64:257</i>
+  %Y = zext bool true to i32              <i>; yields i32:1</i>
 </pre>
 </div>
 
@@ -2766,8 +2796,8 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = sext sbyte -1 to ushort           <i>; yields ushort:65535</i>
-  %Y = sext bool true to int             <i>; yields int:-1</i>
+  %X = sext i8  -1 to i16              <i>; yields i16   :65535</i>
+  %Y = sext bool true to i32             <i>; yields i32:-1</i>
 </pre>
 </div>
 
@@ -2877,9 +2907,9 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = fp2uint double 123.0 to int         <i>; yields int:123</i>
+  %X = fp2uint double 123.0 to i32         <i>; yields i32:123</i>
   %Y = fp2uint float 1.0E+300 to bool      <i>; yields bool:true</i>
-  %X = fp2uint float 1.04E+17 to ubyte     <i>; yields undefined:1</i>
+  %X = fp2uint float 1.04E+17 to i8     <i>; yields undefined:1</i>
 </pre>
 </div>
 
@@ -2917,9 +2947,9 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = fptosi double -123.0 to int        <i>; yields int:-123</i>
+  %X = fptosi double -123.0 to i32        <i>; yields i32:-123</i>
   %Y = fptosi float 1.0E-247 to bool      <i>; yields bool:true</i>
-  %X = fptosi float 1.04E+17 to sbyte     <i>; yields undefined:1</i>
+  %X = fptosi float 1.04E+17 to i8      <i>; yields undefined:1</i>
 </pre>
 </div>
 
@@ -2952,8 +2982,8 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = uitofp int 257 to float         <i>; yields float:257.0</i>
-  %Y = uitofp sbyte -1 to double       <i>; yields double:255.0</i>
+  %X = uitofp i32 257 to float         <i>; yields float:257.0</i>
+  %Y = uitofp i8  -1 to double       <i>; yields double:255.0</i>
 </pre>
 </div>
 
@@ -2984,8 +3014,8 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = sitofp int 257 to float         <i>; yields float:257.0</i>
-  %Y = sitofp sbyte -1 to double       <i>; yields double:-1.0</i>
+  %X = sitofp i32 257 to float         <i>; yields float:257.0</i>
+  %Y = sitofp i8  -1 to double       <i>; yields double:-1.0</i>
 </pre>
 </div>
 
@@ -3019,8 +3049,8 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = ptrtoint int* %X to sbyte          <i>; yields truncation on 32-bit</i>
-  %Y = ptrtoint int* %x to ulong          <i>; yields zero extend on 32-bit</i>
+  %X = ptrtoint i32* %X to i8           <i>; yields truncation on 32-bit</i>
+  %Y = ptrtoint i32* %x to i64          <i>; yields zero extend on 32-bit</i>
 </pre>
 </div>
 
@@ -3054,9 +3084,9 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = inttoptr int 255 to int*            <i>; yields zero extend on 64-bit</i>
-  %X = inttoptr int 255 to int*            <i>; yields no-op on 32-bit </i>
-  %Y = inttoptr short 0 to int*            <i>; yields zero extend on 32-bit</i>
+  %X = inttoptr i32 255 to i32*            <i>; yields zero extend on 64-bit</i>
+  %X = inttoptr i32 255 to i32*            <i>; yields no-op on 32-bit </i>
+  %Y = inttoptr i16 0 to i32*            <i>; yields zero extend on 32-bit</i>
 </pre>
 </div>
 
@@ -3092,9 +3122,9 @@
 
 <h5>Example:</h5>
 <pre>
-  %X = bitcast ubyte 255 to sbyte         <i>; yields sbyte:-1</i>
-  %Y = bitcast uint* %x to sint*          <i>; yields sint*:%x</i>
-  %Z = bitcast <2xint> %V to long;        <i>; yields long: %V</i>   
+  %X = bitcast i8 255 to i8          <i>; yields i8 :-1</i>
+  %Y = bitcast i32* %x to sint*          <i>; yields sint*:%x</i>
+  %Z = bitcast <2xint> %V to i64;        <i>; yields i64: %V</i>   
 </pre>
 </div>
 
@@ -3169,12 +3199,12 @@
 elements.</p>
 
 <h5>Example:</h5>
-<pre>  <result> = icmp eq int 4, 5           <i>; yields: result=false</i>
-  <result> = icmp ne float* %X, %X      <i>; yields: result=false</i>
-  <result> = icmp ult short 4, 5        <i>; yields: result=true</i>
-  <result> = icmp sgt sbyte 4, 5        <i>; yields: result=false</i>
-  <result> = icmp ule sbyte -4, 5       <i>; yields: result=false</i>
-  <result> = icmp sge sbyte 4, 5        <i>; yields: result=false</i>
+<pre>  <result> = icmp eq i32 4, 5          <i>; yields: result=false</i>
+  <result> = icmp ne float* %X, %X     <i>; yields: result=false</i>
+  <result> = icmp ult i16  4, 5        <i>; yields: result=true</i>
+  <result> = icmp sgt i16  4, 5        <i>; yields: result=false</i>
+  <result> = icmp ule i16 -4, 5        <i>; yields: result=false</i>
+  <result> = icmp sge i16  4, 5        <i>; yields: result=false</i>
 </pre>
 </div>
 
@@ -3287,7 +3317,7 @@
 value specified by the parameter, depending on which basic block we
 came from in the last <a href="#terminators">terminator</a> instruction.</p>
 <h5>Example:</h5>
-<pre>Loop:       ; Infinite loop that counts from 0 on up...<br>  %indvar = phi uint [ 0, %LoopHeader ], [ %nextindvar, %Loop ]<br>  %nextindvar = add uint %indvar, 1<br>  br label %Loop<br></pre>
+<pre>Loop:       ; Infinite loop that counts from 0 on up...<br>  %indvar = phi i32 [ 0, %LoopHeader ], [ %nextindvar, %Loop ]<br>  %nextindvar = add i32 %indvar, 1<br>  br label %Loop<br></pre>
 </div>
 
 <!-- _______________________________________________________________________ -->
@@ -3327,7 +3357,7 @@
 <h5>Example:</h5>
 
 <pre>
-  %X = select bool true, ubyte 17, ubyte 42          <i>; yields ubyte:17</i>
+  %X = select bool true, i8 17, i8 42          <i>; yields i8:17</i>
 </pre>
 </div>
 
@@ -3399,10 +3429,10 @@
 <h5>Example:</h5>
 
 <pre>
-  %retval = call int %test(int %argc)
-  call int(sbyte*, ...) *%printf(sbyte* %msg, int 12, sbyte 42);
-  %X = tail call int %foo()
-  %Y = tail call <a href="#callingconv">fastcc</a> int %foo()
+  %retval = call i32 %test(i32 %argc)
+  call i32(i8 *, ...) *%printf(i8 * %msg, i32 12, i8  42);
+  %X = tail call i32 %foo()
+  %Y = tail call <a href="#callingconv">fastcc</a> i32 %foo()
 </pre>
 
 </div>
@@ -3506,22 +3536,22 @@
 used.</p>
 
 <pre>
-int %test(int %X, ...) {
+define i32 %test(i32 %X, ...) {
   ; Initialize variable argument processing
-  %ap = alloca sbyte*
-  call void %<a href="#i_va_start">llvm.va_start</a>(sbyte** %ap)
+  %ap = alloca i8 *
+  call void %<a href="#i_va_start">llvm.va_start</a>(i8 ** %ap)
 
   ; Read a single integer argument
-  %tmp = va_arg sbyte** %ap, int
+  %tmp = va_arg i8 ** %ap, i32
 
   ; Demonstrate usage of llvm.va_copy and llvm.va_end
-  %aq = alloca sbyte*
-  call void %<a href="#i_va_copy">llvm.va_copy</a>(sbyte** %aq, sbyte** %ap)
-  call void %<a href="#i_va_end">llvm.va_end</a>(sbyte** %aq)
+  %aq = alloca i8 *
+  call void %<a href="#i_va_copy">llvm.va_copy</a>(i8 ** %aq, i8 ** %ap)
+  call void %<a href="#i_va_end">llvm.va_end</a>(i8 ** %aq)
 
   ; Stop processing of arguments.
-  call void %<a href="#i_va_end">llvm.va_end</a>(sbyte** %ap)
-  ret int %tmp
+  call void %<a href="#i_va_end">llvm.va_end</a>(i8 ** %ap)
+  ret i32 %tmp
 }
 </pre>
 </div>
@@ -3675,7 +3705,7 @@
 <h5>Syntax:</h5>
 
 <pre>
-  declare sbyte* %llvm.gcread(sbyte* %ObjPtr, sbyte** %Ptr)
+  declare i8 * %llvm.gcread(i8 * %ObjPtr, i8 ** %Ptr)
 </pre>
 
 <h5>Overview:</h5>
@@ -3710,7 +3740,7 @@
 <h5>Syntax:</h5>
 
 <pre>
-  declare void %llvm.gcwrite(sbyte* %P1, sbyte* %Obj, sbyte** %P2)
+  declare void %llvm.gcwrite(i8 * %P1, i8 * %Obj, i8 ** %P2)
 </pre>
 
 <h5>Overview:</h5>
@@ -3758,7 +3788,7 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare sbyte *%llvm.returnaddress(uint <level>)
+  declare i8  *%llvm.returnaddress(i32 <level>)
 </pre>
 
 <h5>Overview:</h5>
@@ -3803,7 +3833,7 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare sbyte *%llvm.frameaddress(uint <level>)
+  declare i8  *%llvm.frameaddress(i32 <level>)
 </pre>
 
 <h5>Overview:</h5>
@@ -3846,7 +3876,7 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare sbyte *%llvm.stacksave()
+  declare i8  *%llvm.stacksave()
 </pre>
 
 <h5>Overview:</h5>
@@ -3881,7 +3911,7 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare void %llvm.stackrestore(sbyte* %ptr)
+  declare void %llvm.stackrestore(i8 * %ptr)
 </pre>
 
 <h5>Overview:</h5>
@@ -3912,8 +3942,8 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare void %llvm.prefetch(sbyte * <address>,
-                                uint <rw>, uint <locality>)
+  declare void %llvm.prefetch(i8  * <address>,
+                                i32 <rw>, i32 <locality>)
 </pre>
 
 <h5>Overview:</h5>
@@ -3957,7 +3987,7 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare void %llvm.pcmarker( uint <id> )
+  declare void %llvm.pcmarker( i32 <id> )
 </pre>
 
 <h5>Overview:</h5>
@@ -3998,7 +4028,7 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare ulong %llvm.readcyclecounter( )
+  declare i64 %llvm.readcyclecounter( )
 </pre>
 
 <h5>Overview:</h5>
@@ -4046,10 +4076,10 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare void %llvm.memcpy.i32(sbyte* <dest>, sbyte* <src>,
-                                uint <len>, uint <align>)
-  declare void %llvm.memcpy.i64(sbyte* <dest>, sbyte* <src>,
-                                ulong <len>, uint <align>)
+  declare void %llvm.memcpy.i32(i8 * <dest>, i8 * <src>,
+                                i32 <len>, i32 <align>)
+  declare void %llvm.memcpy.i64(i8 * <dest>, i8 * <src>,
+                                i64 <len>, i32 <align>)
 </pre>
 
 <h5>Overview:</h5>
@@ -4100,10 +4130,10 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare void %llvm.memmove.i32(sbyte* <dest>, sbyte* <src>,
-                                 uint <len>, uint <align>)
-  declare void %llvm.memmove.i64(sbyte* <dest>, sbyte* <src>,
-                                 ulong <len>, uint <align>)
+  declare void %llvm.memmove.i32(i8 * <dest>, i8 * <src>,
+                                 i32 <len>, i32 <align>)
+  declare void %llvm.memmove.i64(i8 * <dest>, i8 * <src>,
+                                 i64 <len>, i32 <align>)
 </pre>
 
 <h5>Overview:</h5>
@@ -4155,10 +4185,10 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare void %llvm.memset.i32(sbyte* <dest>, ubyte <val>,
-                                uint <len>, uint <align>)
-  declare void %llvm.memset.i64(sbyte* <dest>, ubyte <val>,
-                                ulong <len>, uint <align>)
+  declare void %llvm.memset.i32(i8 * <dest>, i8 <val>,
+                                i32 <len>, i32 <align>)
+  declare void %llvm.memset.i64(i8 * <dest>, i8 <val>,
+                                i64 <len>, i32 <align>)
 </pre>
 
 <h5>Overview:</h5>
@@ -4279,8 +4309,8 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare float  %llvm.powi.f32(float  %Val, int %power)
-  declare double %llvm.powi.f64(double %Val, int %power)
+  declare float  %llvm.powi.f32(float  %Val, i32 %power)
+  declare double %llvm.powi.f64(double %Val, i32 %power)
 </pre>
 
 <h5>Overview:</h5>
@@ -4328,9 +4358,9 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare ushort %llvm.bswap.i16(ushort <id>)
-  declare uint   %llvm.bswap.i32(uint <id>)
-  declare ulong  %llvm.bswap.i64(ulong <id>)
+  declare i16 %llvm.bswap.i16(i16 <id>)
+  declare i32 %llvm.bswap.i32(i32 <id>)
+  declare i64 %llvm.bswap.i64(i64 <id>)
 </pre>
 
 <h5>Overview:</h5>
@@ -4344,12 +4374,12 @@
 <h5>Semantics:</h5>
 
 <p>
-The <tt>llvm.bswap.16</tt> intrinsic returns a ushort value that has the high and low
-byte of the input ushort swapped.  Similarly, the <tt>llvm.bswap.i32</tt> intrinsic
-returns a uint value that has the four bytes of the input uint swapped, so that 
-if the input bytes are numbered 0, 1, 2, 3 then the returned uint will have its
-bytes in 3, 2, 1, 0 order.  The <tt>llvm.bswap.i64</tt> intrinsic extends this concept
-to 64 bits.
+The <tt>llvm.bswap.16</tt> intrinsic returns an i16 value that has the high 
+and low byte of the input i16 swapped.  Similarly, the <tt>llvm.bswap.i32</tt> 
+intrinsic returns an i32 value that has the four bytes of the input i32 
+swapped, so that if the input bytes are numbered 0, 1, 2, 3 then the returned 
+i32 will have its bytes in 3, 2, 1, 0 order.  The <tt>llvm.bswap.i64</tt> 
+intrinsic extends this concept to 64 bits.
 </p>
 
 </div>
@@ -4363,10 +4393,10 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare ubyte  %llvm.ctpop.i8 (ubyte <src>)
-  declare ushort %llvm.ctpop.i16(ushort <src>)
-  declare uint   %llvm.ctpop.i32(uint <src>)
-  declare ulong  %llvm.ctpop.i64(ulong <src>)
+  declare i8  %llvm.ctpop.i8 (i8  <src>)
+  declare i16 %llvm.ctpop.i16(i16 <src>)
+  declare i32 %llvm.ctpop.i32(i32 <src>)
+  declare i64 %llvm.ctpop.i64(i64 <src>)
 </pre>
 
 <h5>Overview:</h5>
@@ -4399,10 +4429,10 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare ubyte  %llvm.ctlz.i8 (ubyte <src>)
-  declare ushort %llvm.ctlz.i16(ushort <src>)
-  declare uint   %llvm.ctlz.i32(uint <src>)
-  declare ulong  %llvm.ctlz.i64(ulong <src>)
+  declare i8  %llvm.ctlz.i8 (i8  <src>)
+  declare i16 %llvm.ctlz.i16(i16 <src>)
+  declare i32 %llvm.ctlz.i32(i32 <src>)
+  declare i64 %llvm.ctlz.i64(i64 <src>)
 </pre>
 
 <h5>Overview:</h5>
@@ -4424,7 +4454,7 @@
 <p>
 The '<tt>llvm.ctlz</tt>' intrinsic counts the leading (most significant) zeros
 in a variable.  If the src == 0 then the result is the size in bits of the type
-of src. For example, <tt>llvm.ctlz(int 2) = 30</tt>.
+of src. For example, <tt>llvm.ctlz(i32 2) = 30</tt>.
 </p>
 </div>
 
@@ -4439,10 +4469,10 @@
 
 <h5>Syntax:</h5>
 <pre>
-  declare ubyte  %llvm.cttz.i8 (ubyte <src>)
-  declare ushort %llvm.cttz.i16(ushort <src>)
-  declare uint   %llvm.cttz.i32(uint <src>)
-  declare ulong  %llvm.cttz.i64(ulong <src>)
+  declare i8  %llvm.cttz.i8 (i8  <src>)
+  declare i16 %llvm.cttz.i16(i16 <src>)
+  declare i32 %llvm.cttz.i32(i32 <src>)
+  declare i64 %llvm.cttz.i64(i64 <src>)
 </pre>
 
 <h5>Overview:</h5>
@@ -4493,7 +4523,7 @@
 
   <a href="mailto:sabre at nondot.org">Chris Lattner</a><br>
   <a href="http://llvm.org">The LLVM Compiler Infrastructure</a><br>
-  Last modified: $Date: 2006/12/28 16:55:55 $
+  Last modified: $Date: 2006/12/31 07:07:53 $
 </address>
 </body>
 </html>






More information about the llvm-commits mailing list