Skip to content

Commit

Permalink
[LangRef][VP] Change masked-off lanes from undef to poison
Browse files Browse the repository at this point in the history
These were all changed in 32b1b06 (as
discussed in D133967) but some intrinsics introduced since have
re-introduced `undef` as the masked-off value.

Reviewed By: reames, eopXD

Differential Revision: https://reviews.llvm.org/D135244
  • Loading branch information
frasercrmck committed Oct 5, 2022
1 parent 3e97e94 commit 043a585
Showing 1 changed file with 15 additions and 14 deletions.
29 changes: 15 additions & 14 deletions llvm/docs/LangRef.rst
Expand Up @@ -19390,7 +19390,8 @@ Semantics:

The '``llvm.vp.sqrt``' intrinsic performs floating-point square root (:ref:`sqrt <int_sqrt>`) of
the first vector operand on each enabled lane. The result on disabled lanes is
undefined. The operation is performed in the default floating-point environment.
a :ref:`poison value <poisonvalues>`. The operation is performed in the default
floating-point environment.

Examples:
"""""""""
Expand All @@ -19401,7 +19402,7 @@ Examples:
;; For all lanes below %evl, %r is lane-wise equivalent to %also.r

%t = call <4 x float> @llvm.sqrt.v4f32(<4 x float> %a)
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> undef
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> poison


.. _int_vp_fma:
Expand Down Expand Up @@ -21508,8 +21509,8 @@ Semantics:
""""""""""

The '``llvm.vp.ceil``' intrinsic performs floating-point ceiling
(:ref:`ceil <int_ceil>`) of the first vector operand on each enabled lane. The
result on disabled lanes is undefined.
(:ref:`ceil <int_ceil>`) of the first vector operand on each enabled lane. The
result on disabled lanes is a :ref:`poison value <poisonvalues>`.

Examples:
"""""""""
Expand All @@ -21520,7 +21521,7 @@ Examples:
;; For all lanes below %evl, %r is lane-wise equivalent to %also.r

%t = call <4 x float> @llvm.ceil.v4f32(<4 x float> %a)
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> undef
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> poison

.. _int_vp_floor:

Expand Down Expand Up @@ -21555,8 +21556,8 @@ Semantics:
""""""""""

The '``llvm.vp.floor``' intrinsic performs floating-point floor
(:ref:`floor <int_floor>`) of the first vector operand on each enabled lane. The
result on disabled lanes is undefined.
(:ref:`floor <int_floor>`) of the first vector operand on each enabled lane.
The result on disabled lanes is a :ref:`poison value <poisonvalues>`.

Examples:
"""""""""
Expand All @@ -21567,7 +21568,7 @@ Examples:
;; For all lanes below %evl, %r is lane-wise equivalent to %also.r

%t = call <4 x float> @llvm.floor.v4f32(<4 x float> %a)
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> undef
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> poison

.. _int_vp_round:

Expand Down Expand Up @@ -21602,8 +21603,8 @@ Semantics:
""""""""""

The '``llvm.vp.round``' intrinsic performs floating-point round
(:ref:`round <int_round>`) of the first vector operand on each enabled lane. The
result on disabled lanes is undefined.
(:ref:`round <int_round>`) of the first vector operand on each enabled lane.
The result on disabled lanes is a :ref:`poison value <poisonvalues>`.

Examples:
"""""""""
Expand All @@ -21614,7 +21615,7 @@ Examples:
;; For all lanes below %evl, %r is lane-wise equivalent to %also.r

%t = call <4 x float> @llvm.round.v4f32(<4 x float> %a)
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> undef
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> poison

.. _int_vp_roundeven:

Expand Down Expand Up @@ -21649,8 +21650,8 @@ Semantics:
""""""""""

The '``llvm.vp.roundeven``' intrinsic performs floating-point roundeven
(:ref:`roundeven <int_roundeven>`) of the first vector operand on each enabled lane. The
result on disabled lanes is undefined.
(:ref:`roundeven <int_roundeven>`) of the first vector operand on each enabled
lane. The result on disabled lanes is a :ref:`poison value <poisonvalues>`.

Examples:
"""""""""
Expand All @@ -21661,7 +21662,7 @@ Examples:
;; For all lanes below %evl, %r is lane-wise equivalent to %also.r

%t = call <4 x float> @llvm.roundeven.v4f32(<4 x float> %a)
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> undef
%also.r = select <4 x i1> %mask, <4 x float> %t, <4 x float> poison

.. _int_mload_mstore:

Expand Down

0 comments on commit 043a585

Please sign in to comment.