[Libre-soc-bugs] [Bug 684] XLEN-16 fails when XLEN=8

bugzilla-daemon at libre-soc.org bugzilla-daemon at libre-soc.org
Sat Sep 4 20:17:11 BST 2021


https://bugs.libre-soc.org/show_bug.cgi?id=684

--- Comment #4 from dmitry.selyutin at 3mdeb.com ---
I think the most natural and logical change to fixedlogical (no pun intended)
is scaling all things appropriately, i.e.

RA <- (RS) ^ ([0]*32 || UI || [0]*16)

...converts into this:

RA <- (RS) ^ ([0]*(XLEN/2) || (UI & ([0b1]*(XLEN/4))) || [0]*(XLEN/4))

and this...

if      a <u ([0]*(XLEN-16) || UI) then c <- 0b100
else if a >u ([0]*(XLEN-16) || UI) then c <- 0b010

...is converted in a similar fashion:

if      a <u ([0]*(XLEN-(XLEN/4)) || (UI & ([0b1]*(XLEN/4))) then c <- 0b100
else if a >u ([0]*(XLEN-(XLEN/4)) || (UI & ([0b1]*(XLEN/4))) then c <- 0b010

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the libre-soc-bugs mailing list