From: lkcl Date: Mon, 11 Apr 2022 08:47:08 +0000 (+0100) Subject: (no commit message) X-Git-Tag: opf_rfc_ls005_v1~2790 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=fbf08d0d2f56576cbb7d15c803e23e3a43bb5293;p=libreriscv.git --- diff --git a/openpower/sv/svp64/appendix.mdwn b/openpower/sv/svp64/appendix.mdwn index a94caed5e..6896b8726 100644 --- a/openpower/sv/svp64/appendix.mdwn +++ b/openpower/sv/svp64/appendix.mdwn @@ -851,6 +851,7 @@ achieved in DCT and FFT REMAP** /// /// all input arrays have length `vl` def reduce(vl, vec, pred): + pred = copy(pred) # must not damage preficate step = 1; while step < vl step *= 2; @@ -887,7 +888,8 @@ An alternative algorithm is therefore required that does not perform MVs, and does not require additional state to be saved on context-switching. ``` -def reduce( vl, vec, pred, pred,): +def reduce( vl, vec, pred ): + pred = copy(pred) # must not damage predicate j = 0 vi = [] # array of lookup indices to skip nonpredicated for i, pbit in enumerate(pred):