diff --git a/docs/LangRef.html b/docs/LangRef.html index e578a0d8402..27bcb920025 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -24,7 +24,7 @@
LLVM identifiers come in two basic types: global and local. Global identifiers (functions, global variables) begin with the @ character. Local identifiers (register names, types) begin with the % character. Additionally, - there are three different formats for identifiers, for different purposes: + there are three different formats for identifiers, for different purposes:
Aliases can have only external, internal and weak -linkages. +linkages.
@@ -1077,7 +1078,7 @@ are given in this list:When LLVM is determining the alignment for a given type, it uses the -following rules: +following rules:
%X = uitofp i32 257 to float ; yields float:257.0 - %Y = uitofp i8 -1 to double ; yields double:255.0 + %Y = uitofp i8 -1 to double ; yields double:255.0@@ -3768,7 +3770,7 @@ the value cannot fit in the floating point value, the results are undefined.
%X = sitofp i32 257 to float ; yields float:257.0 - %Y = sitofp i8 -1 to double ; yields double:-1.0 + %Y = sitofp i8 -1 to double ; yields double:-1.0@@ -3790,7 +3792,7 @@ the integer type ty2.
The 'ptrtoint' instruction takes a value to cast, which must be a pointer value, and a type to cast it to -ty2, which must be an integer type. +ty2, which must be an integer type.
The 'ptrtoint' instruction converts value to integer type @@ -3826,7 +3828,7 @@ a pointer type, ty2.
The 'inttoptr' instruction takes an integer value to cast, and a type to cast it to, which must be a -pointer type. +pointer type.
The 'inttoptr' instruction converts value to type @@ -3884,7 +3886,7 @@ other types, use the inttoptr or
%X = bitcast i8 255 to i8 ; yields i8 :-1 %Y = bitcast i32* %x to sint* ; yields sint*:%x - %Z = bitcast <2xint> %V to i64; ; yields i64: %V + %Z = bitcast <2 x int> %V to i64; ; yields i64: %V@@ -3900,7 +3902,7 @@ instructions, which defy better classification.
<result> = icmp <cond> <ty> <op1>, <op2> ; yields {i1} or {<N x i1>}:result +<result> = icmp <cond> <ty> <op1>, <op2> ; yields {i1} or {<N x i1>}:resultOverview:
The 'icmp' instruction returns a boolean value or @@ -3910,6 +3912,7 @@ of its two integer, integer vector, or pointer operands.
The 'icmp' instruction takes three operands. The first operand is the condition code indicating the kind of comparison to perform. It is not a value, just a keyword. The possible condition code are: +
- eq: equal
- ne: not equal
@@ -3930,12 +3933,13 @@ They must also be identical types.The 'icmp' compares op1 and op2 according to the condition code given as cond. The comparison performed always yields either an i1 or vector of i1 result, as follows: +
- eq: yields true if the operands are equal, false otherwise. No sign interpretation is necessary or performed.
- ne: yields true if the operands are unequal, - false otherwise. No sign interpretation is necessary or performed. + false otherwise. No sign interpretation is necessary or performed.
- ugt: interprets the operands as unsigned values and yields true if op1 is greater than op2.
- uge: interprets the operands as unsigned values and yields @@ -3976,12 +3980,12 @@ Otherwise, the result is an i1.
<result> = fcmp <cond> <ty> <op1>, <op2> ; yields {i1} or {<N x i1>}:result +<result> = fcmp <cond> <ty> <op1>, <op2> ; yields {i1} or {<N x i1>}:resultOverview:
The 'fcmp' instruction returns a boolean value or vector of boolean values based on comparison -of its operands. +of its operands.
If the operands are floating point scalars, then the result type is a boolean (i1). @@ -3992,7 +3996,7 @@ operands being compared.
Arguments:
The 'fcmp' instruction takes three operands. The first operand is the condition code indicating the kind of comparison to perform. It is not -a value, just a keyword. The possible condition code are: +a value, just a keyword. The possible condition code are:
- false: no comparison, always returns false
- oeq: ordered and equal
@@ -4023,7 +4027,7 @@ according to the condition code given as cond. If the operands are vectors, then the vectors are compared element by element. Each comparison performed -always yields an i1 result, as follows: +always yields an i1 result, as follows:
- false: always yields false, regardless of operands.
- oeq: yields true if both operands are not a QNAN and @@ -4077,7 +4081,7 @@ element-wise comparison of its two integer vector operands.
Arguments:
The 'vicmp' instruction takes three operands. The first operand is the condition code indicating the kind of comparison to perform. It is not -a value, just a keyword. The possible condition code are: +a value, just a keyword. The possible condition code are:
- eq: equal
- ne: not equal
@@ -4100,7 +4104,7 @@ identical type as the values being compared. The most significant bit in each element is 1 if the element-wise comparison evaluates to true, and is 0 otherwise. All other bits of the result are undefined. The condition codes are evaluated identically to the 'icmp' -instruction. +instruction.Example:
@@ -4123,7 +4127,7 @@ elements have the same width as the input elements.Arguments:
The 'vfcmp' instruction takes three operands. The first operand is the condition code indicating the kind of comparison to perform. It is not -a value, just a keyword. The possible condition code are: +a value, just a keyword. The possible condition code are:
- false: no comparison, always returns false
- oeq: ordered and equal
@@ -4154,7 +4158,7 @@ having identical with to the width of the floating point elements. The most significant bit in each element is 1 if the element-wise comparison evaluates to true, and is 0 otherwise. All other bits of the result are undefined. The condition codes are evaluated identically to the -'fcmp' instruction. +'fcmp' instruction.Example:
@@ -4219,7 +4223,7 @@ Loop: ; Infinite loop that counts from 0 on up...<result> = select selty <cond>, <ty> <val1>, <ty> <val2> ; yields ty - selty is either i1 or {<N x i1>} + selty is either i1 or {<N x i1>}Overview:
@@ -4287,12 +4291,12 @@ by element. any allocas or varargs in the caller. If the "tail" marker is present, the function call is eligible for tail call optimization. Note that calls may be marked "tail" even if they do not occur before a ret instruction. + href="#i_ret">ret instruction.The optional "cconv" marker indicates which calling convention the call should use. If none is specified, the call defaults - to using C calling conventions. + to using C calling conventions.
- @@ -4339,7 +4343,7 @@ transfer to a specified function, with its incoming arguments bound to the specified values. Upon a 'ret' instruction in the called function, control flow continues with the instruction after the function call, and the return value of the -function is bound to the result argument. +function is bound to the result argument.
Example:
@@ -4519,17 +4523,17 @@ declare void @llvm.va_end(i8*)Syntax:
declare void %llvm.va_start(i8* <arglist>)Overview:
-The 'llvm.va_start' intrinsic initializes +
The 'llvm.va_start' intrinsic initializes *<arglist> for subsequent use by va_arg.
Arguments:
-The argument is a pointer to a va_list element to initialize.
+The argument is a pointer to a va_list element to initialize.
Semantics:
-The 'llvm.va_start' intrinsic works just like the va_start +
The 'llvm.va_start' intrinsic works just like the va_start macro available in C. In a target-dependent way, it initializes the va_list element to which the argument points, so that the next call to va_arg will produce the first variable argument passed to the function. @@ -5209,7 +5213,7 @@ this can be specified as the fourth argument, otherwise it should be set to 0 or
Syntax:
This is an overloaded intrinsic. You can use llvm.sqrt on any floating point or vector of floating point type. Not all targets support all -types however. +types however.
declare float @llvm.sqrt.f32(float %Val) declare double @llvm.sqrt.f64(double %Val) @@ -5253,7 +5257,7 @@ floating point number.Syntax:
This is an overloaded intrinsic. You can use llvm.powi on any floating point or vector of floating point type. Not all targets support all -types however. +types however.
declare float @llvm.powi.f32(float %Val, i32 %power) declare double @llvm.powi.f64(double %Val, i32 %power) @@ -5295,7 +5299,7 @@ unspecified sequence of rounding operations.Syntax:
This is an overloaded intrinsic. You can use llvm.sin on any floating point or vector of floating point type. Not all targets support all -types however. +types however.
declare float @llvm.sin.f32(float %Val) declare double @llvm.sin.f64(double %Val) @@ -5334,7 +5338,7 @@ conditions in the same way.Syntax:
This is an overloaded intrinsic. You can use llvm.cos on any floating point or vector of floating point type. Not all targets support all -types however. +types however.
declare float @llvm.cos.f32(float %Val) declare double @llvm.cos.f64(double %Val) @@ -5373,7 +5377,7 @@ conditions in the same way.Syntax:
This is an overloaded intrinsic. You can use llvm.pow on any floating point or vector of floating point type. Not all targets support all -types however. +types however.
declare float @llvm.pow.f32(float %Val, float %Power) declare double @llvm.pow.f64(double %Val, double %Power) @@ -5428,7 +5432,7 @@ These allow efficient code generation for some algorithms.Syntax:
This is an overloaded intrinsic function. You can use bswap on any integer -type that is an even number of bytes (i.e. BitWidth % 16 == 0). +type that is an even number of bytes (i.e. BitWidth % 16 == 0).
declare i16 @llvm.bswap.i16(i16 <id>) declare i32 @llvm.bswap.i32(i32 <id>) @@ -5467,7 +5471,7 @@ additional even-byte lengths (6 bytes, 8 bytes and more, respectively).Syntax:
This is an overloaded intrinsic. You can use llvm.ctpop on any integer bit -width. Not all targets support all bit widths however. +width. Not all targets support all bit widths however.
declare i8 @llvm.ctpop.i8 (i8 <src>) declare i16 @llvm.ctpop.i16(i16 <src>) @@ -5506,7 +5510,7 @@ The 'llvm.ctpop' intrinsic counts the 1's in a variable.Syntax:
This is an overloaded intrinsic. You can use llvm.ctlz on any -integer bit width. Not all targets support all bit widths however. +integer bit width. Not all targets support all bit widths however.
declare i8 @llvm.ctlz.i8 (i8 <src>) declare i16 @llvm.ctlz.i16(i16 <src>) @@ -5549,7 +5553,7 @@ of src. For example, llvm.ctlz(i32 2) = 30.Syntax:
This is an overloaded intrinsic. You can use llvm.cttz on any -integer bit width. Not all targets support all bit widths however. +integer bit width. Not all targets support all bit widths however.
declare i8 @llvm.cttz.i8 (i8 <src>) declare i16 @llvm.cttz.i16(i16 <src>) @@ -5590,7 +5594,7 @@ of src. For example, llvm.cttz(2) = 1.Syntax:
This is an overloaded intrinsic. You can use llvm.part.select -on any integer bit width. +on any integer bit width.
declare i17 @llvm.part.select.i17 (i17 %val, i32 %loBit, i32 %hiBit) declare i29 @llvm.part.select.i29 (i29 %val, i32 %loBit, i32 %hiBit) @@ -5620,7 +5624,7 @@ only the %hiBit - %loBit bits set, as follows:- The %loBits value is subtracted from the %hiBits value to determine the number of bits to retain.
- A mask of the retained bits is created by shifting a -1 value.
-- The mask is ANDed with %val to produce the result. +
- The mask is ANDed with %val to produce the result.
In reverse mode, a similar computation is made except that the bits are returned in the reverse order. So, for example, if X has the value @@ -5637,7 +5641,7 @@ returned in the reverse order. So, for example, if X has the value
Syntax:
This is an overloaded intrinsic. You can use llvm.part.set -on any integer bit width. +on any integer bit width.
declare i17 @llvm.part.set.i17.i9 (i17 %val, i9 %repl, i32 %lo, i32 %hi) declare i29 @llvm.part.set.i29.i9 (i29 %val, i9 %repl, i32 %lo, i32 %hi) @@ -5666,10 +5670,10 @@ up to that size.In forward mode, the bits between %lo and %hi (inclusive) are replaced with corresponding bits from %repl. That is the 0th bit in %repl replaces the %loth bit in %val and etc. up -to the %hith bit. +to the %hith bit.
In reverse mode, a similar computation is made except that the bits are reversed. That is, the 0th bit in %repl replaces the -%hi bit in %val and etc. down to the %loth bit. +%hi bit in %val and etc. down to the %loth bit.
Examples:
llvm.part.set(0xFFFF, 0, 4, 7) -> 0xFF0F @@ -5836,7 +5840,7 @@ i1 <device> )- ls: load-store barrier
- sl: store-load barrier
- ss: store-store barrier
-- device: barrier applies to device and uncached memory also. +
- device: barrier applies to device and uncached memory also.
Semantics:
@@ -6360,6 +6364,7 @@ This intrinsic allows annotations to be put on arbitrary expressions with arbitrary strings. This can be useful for special purpose optimizations that want to look for these annotations. These have no other defined use, they are ignored by code generation and optimization. +