[Libre-soc-isa] [Bug 680] bpermd XLEN update needs refinement
bugzilla-daemon at libre-soc.org
bugzilla-daemon at libre-soc.org
Mon Aug 30 14:29:17 BST 2021
https://bugs.libre-soc.org/show_bug.cgi?id=680
Luke Kenneth Casson Leighton <lkcl at lkcl.net> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|b |bpermd XLEN update needs
| |refinement
--- Comment #1 from Luke Kenneth Casson Leighton <lkcl at lkcl.net> ---
https://git.libre-soc.org/?p=openpower-isa.git;a=commitdiff;h=5fee1b0a044b78890c747d359f7bfed8c8c585dd
@@ -468,11 +468,11 @@ Pseudo-code:
perm <- [0] * 8
for i = 0 to 7
index <- (RS)[8*i:8*i+7]
- if index <u 64 then
+ if index <u XLEN then
perm[i] <- (RB)[index]
else
perm[i] <- 0
- RA <- [0]*56 || perm[0:7]
+ RA <- [0]*(XLEN-8) || perm[0:7]
the for-loop for i = 0 to 7 needs adjusting otherwise
it will overrun RS. for i = 0 to (XLEN/8-1) would
probably do the trick.
see https://bugs.libre-soc.org/show_bug.cgi?id=671#c26
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the Libre-SOC-ISA
mailing list