X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=docs%2FLangRef.html;h=cd8b7e9f967a5e607af176bccbef90a141901e1f;hb=04eeefb32a3ae7de4cde1908d30bff61e0d6b86e;hp=59d6581ce211e915c7ac6121c01f7e01acca662b;hpb=5568e94dbf1b54e959f3f290eed9679398e5d85c;p=oota-llvm.git diff --git a/docs/LangRef.html b/docs/LangRef.html index 59d6581ce21..cd8b7e9f967 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -466,7 +466,7 @@ All Global Variables and Functions have one of the following types of linkage:
-
internal
+
internal:
Global values with internal linkage are only directly accessible by objects in the current module. In particular, linking code into a module with @@ -485,14 +485,22 @@ All Global Variables and Functions have one of the following types of linkage: allowed to be discarded.
+
common:
+ +
"common" linkage is exactly the same as linkonce + linkage, except that unreferenced common globals may not be + discarded. This is used for globals that may be emitted in multiple + translation units, but that are not guaranteed to be emitted into every + translation unit that uses them. One example of this is tentative + definitions in C, such as "int X;" at global scope. +
+
weak:
-
"weak" linkage is exactly the same as linkonce linkage, - except that unreferenced weak globals may not be discarded. This is - used for globals that may be emitted in multiple translation units, but that - are not guaranteed to be emitted into every translation unit that uses them. - One example of this are common globals in C, such as "int X;" at - global scope. +
"weak" linkage is the same as common linkage, except + that some targets may choose to emit different assembly sequences for them + for target-dependent reasons. This is used for globals that are declared + "weak" in C source code.
appending:
@@ -1037,16 +1045,16 @@ classifications:

integer, floating point, pointer, - vector + vector, structure, array, + label. primitive label, void, - integer, floating point. @@ -1066,8 +1074,7 @@ classifications:

The first class types are perhaps the most important. Values of these types are the only ones which can be produced by instructions, passed as arguments, or used as operands to -instructions. This means that all structures and arrays must be -manipulated either by pointer or by component.

+instructions.

@@ -2910,7 +2917,7 @@ or array element from an aggregate value. The first operand of an 'extractvalue' instruction is a value of struct or array type. The operands are constant indices to specify which value to extract -in the same manner as indices in a +in a similar manner as indices in a 'getelementptr' instruction.

@@ -2924,7 +2931,7 @@ the index operands.
Example:
-  %result = extractvalue {i32, float} %agg, i32 0    ; yields i32
+  %result = extractvalue {i32, float} %agg, 0    ; yields i32
 
@@ -2939,7 +2946,7 @@ the index operands.
Syntax:
-  <result> = insertvalue <aggregate type> <val>, <ty> <val>, i32 <idx>    ; yields <n x <ty>>
+  <result> = insertvalue <aggregate type> <val>, <ty> <val>, <idx>    ; yields <n x <ty>>
 
Overview:
@@ -2956,8 +2963,8 @@ into a struct field or array element in an aggregate. The first operand of an 'insertvalue' instruction is a value of struct or array type. The second operand is a first-class value to insert. -type of the first operand. The following operands are constant indices -indicating the position at which to insert the value in the same manner as +The following operands are constant indices +indicating the position at which to insert the value in a similar manner as indices in a 'getelementptr' instruction. The value to insert must have the same type as the value identified @@ -2974,7 +2981,7 @@ specified by the indices is that of elt.
Example:
-  %result = insertvalue {i32, float} %agg, i32 1, i32 0    ; yields {i32, float}
+  %result = insertvalue {i32, float} %agg, 1, 0    ; yields {i32, float}