From: lkcl Date: Sat, 25 Mar 2023 23:24:51 +0000 (+0000) Subject: (no commit message) X-Git-Tag: opf_rfc_ls001_v3~64 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6f36cc6a46b7ea91f122f930c91f1ae87c0c2e67;p=libreriscv.git --- diff --git a/openpower/sv/rfc/ls008.mdwn b/openpower/sv/rfc/ls008.mdwn index 8e8d6dbbe..03217387b 100644 --- a/openpower/sv/rfc/ls008.mdwn +++ b/openpower/sv/rfc/ls008.mdwn @@ -277,18 +277,27 @@ field may only be set **statically** as an immediate, by the `setvl` instruction It may **NOT** be set dynamically from a register. Compiler writers and assembly programmers are expected to perform static register file analysis, subdivision, and allocation and only utilise `setvl`. Direct writing to SVSTATE in order to -"bypass" this Note could, in less-advanced implementations, potentially cause stalling. +"bypass" this Note could, in less-advanced implementations, potentially cause stalling, +particularly if SVP64 instructions are issued directly after the `mtspr` to SVSTATE. **Vector Length (vl)** +The actual Vector length, the number of elements in a "Vector", vl may be set +entirely dynamically at runtime from a number of sources. `setvl` is the primary +instruction for setting Vector Length. `setvl` is conceptually similar but different from the Cray, SX Aurora, and RISC-V RVV equivalent. Similar to RVV, VL is set to be within the range 0 <= VL <= MVL. Unlike RVV, VL is set **exactly** according to the following: VL = (RT|0) = MIN(vlen, MVL) -where 0 <= MVL <= XLEN and vlen may come from an immediate, `RA`, or from the `CTR` SPR, -depending on options set with the `setvl` instruction. +where 0 <= MVL <= 127 and vlen may come from an immediate, `RA`, or from the `CTR` SPR, +depending on options selected with the `setvl` instruction. + +Programmer's Note: understanding of Cray-style Vectors is far beyond the scope +of the Power ISA Technical Reference. Guidance on the Cray Vector paradigm is +best sought elsewhere: good studies include Academic Courses given on the 1970s +Cray Supercomputers over the past 30 years. **SUBVL - Sub Vector Length** @@ -303,6 +312,8 @@ representing 1 operation (1 element) thru 4 operations (4 elements) respectively Elements are best though of in the context of 3D, Audio and Video: two Left and Right Channel "elements" or four ARGB "elements", or three XYZ coordinate "elements". +`subvl` is again primarily set by the `setvl` instruction. + **Horizontal Parallelism** A problem exists for hardware where it may not be able to detect