From 1f23b3bc515f1d66968d958c5d99550c11528b77 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Tue, 20 Nov 2018 20:30:26 +0000 Subject: [PATCH] notes on LD pseudocode --- simple_v_extension/specification.mdwn | 29 +++++++++++++++++---------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/simple_v_extension/specification.mdwn b/simple_v_extension/specification.mdwn index 5e038cf10..5e93369f5 100644 --- a/simple_v_extension/specification.mdwn +++ b/simple_v_extension/specification.mdwn @@ -1279,29 +1279,36 @@ elements are treated as indirection addresses. Simplified pseudo-code would look like this: function op_load(rd, rs) # LD not VLD! -  rd = int_csr[rd].active ? int_csr[rd].regidx : rd; -  rs = int_csr[rs].active ? int_csr[rs].regidx : rs; +  rdv = int_csr[rd].active ? int_csr[rd].regidx : rd; +  rsv = int_csr[rs].active ? int_csr[rs].regidx : rs;  ps = get_pred_val(FALSE, rs); # predication on src  pd = get_pred_val(FALSE, rd); # ... AND on dest  for (int i = 0, int j = 0; i < VL && j < VL;): if (int_csr[rs].isvec) while (!(ps & 1< -- 2.30.2