X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=docs%2FLangRef.html;h=25ac4cbde1b6be025f5884d5519f5faeeb5a3ac2;hb=e7de7e3574245fe4cdee3ea895c3aeabca04db63;hp=e92fa5bc8664cf68a9db684d804eeb99f1510a09;hpb=cdc0669c737db1590e6c8bed05b2f1dd5a7d28fc;p=oota-llvm.git diff --git a/docs/LangRef.html b/docs/LangRef.html index e92fa5bc866..25ac4cbde1b 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -802,7 +802,7 @@ a power of 2.

-@<Name> = [Linkage] [Visibility] alias <AliaseeTy> @<Aliasee>
+@<Name> = alias [Linkage] [Visibility] <AliaseeTy> @<Aliasee>
 
@@ -922,30 +922,30 @@ the named garbage collection algorithm.

various passes.

-
define void @f() notes(inline=Always) { ... }
-
define void @f() notes(inline=Always,opt-size) { ... }
-
define void @f() notes(inline=Never,opt-size) { ... }
-
define void @f() notes(opt-size) { ... }
+
+define void @f() notes(inline=Always) { ... }
+define void @f() notes(inline=Always,opt-size) { ... }
+define void @f() notes(inline=Never,opt-size) { ... }
+define void @f() notes(opt-size) { ... }
+
-

-

  • inline=Always -

    -This note requests inliner to inline this function irrespective of -inlining size threshold for this function. -

  • -
  • inline=Never -

    -This note requests inliner to never inline this function in any situation. -This note may not be used together with inline=Always note. -

  • -
  • opt-size -

    -This note suggests optimization passes and code generator passes to make -choices that help reduce code size. -

  • -

    -The notes that are not documented here are considered invalid notes. +

    +
    inline=Always
    +
    This note requests inliner to inline this function irrespective of inlining +size threshold for this function.
    + +
    inline=Never
    +
    This note requests inliner to never inline this function in any situation. +This note may not be used together with inline=Always note.
    + +
    opt-size
    +
    This note suggests optimization passes and code generator passes to make +choices that help reduce code size.
    + +
    + +

    Any notes that are not documented here are considered invalid notes.

    @@ -1395,7 +1395,8 @@ instruction.

    < { i32, i32, i32 } > A triple of three i32 values - < { float, i32 (i32)* } > + +< { float, i32 (i32)* } > A pair, where the first element is a float and the second element is a pointer to a function that takes an i32, returning @@ -1728,7 +1729,8 @@ following is the syntax for constant expressions:

    was stored to memory and read back as TYPE. In other words, no bits change with this operator, just the type. This can be used for conversion of vector types to any other type, as long as they have the same bit width. For - pointers it is only valid to cast to another pointer type. + pointers it is only valid to cast to another pointer type. It is not valid + to bitcast to or from an aggregate type.
    getelementptr ( CSTPTR, IDX0, IDX1, ... )
    @@ -2610,7 +2612,7 @@ values. Both arguments must have identical types.

    Semantics:

    The truth table used for the 'and' instruction is:

    -
    +
    @@ -2665,7 +2667,7 @@ values. Both arguments must have identical types.

    Semantics:

    The truth table used for the 'or' instruction is:

    -
    +
    @@ -2722,7 +2724,7 @@ values. Both arguments must have identical types.

    The truth table used for the 'xor' instruction is:

    -
    +
    @@ -3807,8 +3809,9 @@ nothing is done (no-op cast).

    Arguments:

    The 'bitcast' instruction takes a value to cast, which must be -a first class value, and a type to cast it to, which must also be a first class type. The bit sizes of value +a non-aggregate first class value, and a type to cast it to, which must also be +a non-aggregate first class type. The bit sizes of +value and the destination type, ty2, must be identical. If the source type is a pointer, the destination type must also be a pointer. This instruction supports bitwise conversion of vectors to integers and to vectors @@ -3843,11 +3846,12 @@ instructions, which defy better classification.

    Syntax:
    -
      <result> = icmp <cond> <ty> <op1>, <op2>   ; yields {i1}:result
    +
      <result> = icmp <cond> <ty> <op1>, <op2>   ; yields {i1} or {<N x i1>}:result
     
    Overview:
    -

    The 'icmp' instruction returns a boolean value based on comparison -of its two integer or pointer operands.

    +

    The 'icmp' instruction returns a boolean value or +a vector of boolean values based on comparison +of its two integer, integer vector, or pointer operands.

    Arguments:

    The 'icmp' instruction takes three operands. The first operand is the condition code indicating the kind of comparison to perform. It is not @@ -3865,11 +3869,13 @@ a value, just a keyword. The possible condition code are:

  • sle: signed less or equal
  • The remaining two arguments must be integer or -pointer typed. They must also be identical types.

    +pointer +or integer vector typed. +They must also be identical types.

    Semantics:

    The 'icmp' compares op1 and op2 according to the condition code given as cond. The comparison performed always -yields a i1 result, as follows: +yields either an i1 or vector of i1 result, as follows:

    1. eq: yields true if the operands are equal, false otherwise. No sign interpretation is necessary or performed. @@ -3895,6 +3901,11 @@ yields a i1 result, as follows:

    If the operands are pointer typed, the pointer values are compared as if they were integers.

    +

    If the operands are integer vectors, then they are compared +element by element. The result is an i1 vector with +the same number of elements as the values being compared. +Otherwise, the result is an i1. +

    Example:
      <result> = icmp eq i32 4, 5          ; yields: result=false
    @@ -3911,11 +3922,19 @@ values are compared as if they were integers.

    Syntax:
    -
      <result> = fcmp <cond> <ty> <op1>, <op2>     ; yields {i1}:result
    +
      <result> = fcmp <cond> <ty> <op1>, <op2>     ; yields {i1} or {<N x i1>}:result
     
    Overview:
    -

    The 'fcmp' instruction returns a boolean value based on comparison -of its floating point operands.

    +

    The 'fcmp' instruction returns a boolean value +or vector of boolean values based on comparison +of its operands. +

    +If the operands are floating point scalars, then the result +type is a boolean (i1). +

    +

    If the operands are floating point vectors, then the result type +is a vector of boolean with the same number of elements as the +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 @@ -3940,13 +3959,17 @@ a value, just a keyword. The possible condition code are:

    Ordered means that neither operand is a QNAN while unordered means that either operand may be a QNAN.

    -

    The val1 and val2 arguments must be -floating point typed. They must have identical -types.

    +

    Each of val1 and val2 arguments must be +either a floating point type +or a vector of floating point type. +They must have identical types.

    Semantics:

    The 'fcmp' instruction compares op1 and op2 -according to the condition code given as cond. The comparison performed -always yields a i1 result, as follows: +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:

    1. false: always yields false, regardless of operands.
    2. oeq: yields true if both operands are not a QNAN and @@ -3980,9 +4003,9 @@ always yields a i1 result, as follows:
      Example:
        <result> = fcmp oeq float 4.0, 5.0    ; yields: result=false
      -  <result> = icmp one float 4.0, 5.0    ; yields: result=true
      -  <result> = icmp olt float 4.0, 5.0    ; yields: result=true
      -  <result> = icmp ueq double 1.0, 2.0   ; yields: result=false
      +  <result> = fcmp one float 4.0, 5.0    ; yields: result=true
      +  <result> = fcmp olt float 4.0, 5.0    ; yields: result=true
      +  <result> = fcmp ueq double 1.0, 2.0   ; yields: result=false
       
    @@ -4013,7 +4036,7 @@ a value, just a keyword. The possible condition code are:
  • slt: signed less than
  • sle: signed less or equal
  • -

    The remaining two arguments must be vector of +

    The remaining two arguments must be vector or integer typed. They must also be identical types.

    Semantics:

    The 'vicmp' instruction compares op1 and op2 @@ -4137,7 +4160,9 @@ Loop: ; Infinite loop that counts from 0 on up...

    Syntax:
    -  <result> = select i1 <cond>, <ty> <val1>, <ty> <val2>             ; yields ty
    +  <result> = select selty <cond>, <ty> <val1>, <ty> <val2>             ; yields ty
    +
    +  selty is either i1 or {<N x i1>}
     
    Overview:
    @@ -4151,18 +4176,25 @@ condition, without branching.
    Arguments:

    -The 'select' instruction requires an 'i1' value indicating the +The 'select' instruction requires an 'i1' value or +a vector of 'i1' values indicating the condition, and two values of the same first class -type. If the val1/val2 are vectors, the entire vectors are selected, not +type. If the val1/val2 are vectors and +the condition is a scalar, then entire vectors are selected, not individual elements.

    Semantics:

    -If the i1 condition evaluates is 1, the instruction returns the first +If the condition is an i1 and it evaluates to 1, the instruction returns the first value argument; otherwise, it returns the second value argument.

    +

    +If the condition is a vector of i1, then the value arguments must +be vectors of the same size, and the selection is done element +by element. +

    Example: