From db80e9ea0350b812c203df4c3e968125fda44c1a Mon Sep 17 00:00:00 2001 From: "Paul A. Clarke" Date: Mon, 4 May 2020 12:46:00 -0500 Subject: [PATCH] Add examples for vec_unsigned{e,o} Add simple examples for `vec_unsignede` and `vec_unsignedo`, making sure to show undefined results and negative truncation. Fixes #29. Signed-off-by: Paul A. Clarke --- Intrinsics_Reference/ch_vec_reference.xml | 94 +++++++++++++++++++++++ 1 file changed, 94 insertions(+) diff --git a/Intrinsics_Reference/ch_vec_reference.xml b/Intrinsics_Reference/ch_vec_reference.xml index 5868dce..a1b6569 100644 --- a/Intrinsics_Reference/ch_vec_reference.xml +++ b/Intrinsics_Reference/ch_vec_reference.xml @@ -36497,6 +36497,53 @@ xmlns:xlink="http://www.w3.org/1999/xlink" xml:id="VIPR.vec-ref"> 3 of r are undefined. Truncation of a negative number to an unsigned integer results in a value of zero. + An example follows: + + + + + + + + + + + + + a + + + 1.0 + + + -1.0 + + + + + r + + + 00000001 + + + ???????? + (undefined) + + + 00000000 + (truncation of a negative number to unsigned is 0) + + + ???????? + (undefined) + + + + + + + Endian considerations: The element numbering within a register is left-to-right for big-endian targets, and right-to-left for little-endian targets. @@ -36587,6 +36634,53 @@ xmlns:xlink="http://www.w3.org/1999/xlink" xml:id="VIPR.vec-ref"> and 2 of r are undefined. Truncation of a negative number to an unsigned integer results in a value of zero. + An example follows: + + + + + + + + + + + + + a + + + 1.0 + + + -1.0 + + + + + r + + + ???????? + (undefined) + + + 00000001 + + + ???????? + (undefined) + + + 00000000 + (truncation of a negative number to unsigned is 0) + + + + + + + Endian considerations: The element numbering within a register is left-to-right for big-endian targets, and right-to-left for little-endian targets.