diff --git a/docs/LangRef.html b/docs/LangRef.html index dde18bd7118..2a1d3a1bda1 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -100,6 +100,7 @@
  • 'phi' Instruction
  • 'cast .. to' Instruction
  • 'select' Instruction
  • +
  • 'extractelement' Instruction
  • 'call' Instruction
  • 'vaarg' Instruction
  • @@ -2230,7 +2231,50 @@ value argument; otherwise, it returns the second value argument. + +
    + 'extractelement' Instruction +
    +
    + +
    Syntax:
    + +
    +  <result> = extractelement <n x <ty>> <val>, uint <idx>    ; yields <ty>
    +
    + +
    Overview:
    + +

    +The 'extractelement' instruction extracts a single scalar +element from a vector at a specified index. +

    + + +
    Arguments:
    + +

    +The first operand of an 'extractelement' instruction is a +value of packed type. The second operand is +an index indicating the position from which to extract the element. +The index may be a variable.

    + +
    Semantics:
    + +

    +The result is a scalar of the same type as the element type of +val. Its value is the value at position idx of +val. If idx exceeds the length of val, the +results are undefined. +

    + +
    Example:
    + +
    +  %result = extractelement <4 x int> %vec, uint 0    ; yields int
    +
    +