+ # modulo + def case_modsd_regression(self): + lst = [f"modsd 17, 27, 0"] + initial_regs = [0] * 32 + initial_regs[0] = 0xff + initial_regs[27] = 0x7fffffffffffffff + with Program(lst, bigendian) as prog: + self.add_case(prog, initial_regs) +
commit b383af53f538aab1dccc7ea9950ffb300a1f5c45 (HEAD -> master) Author: Luke Kenneth Casson Leighton <lkcl@lkcl.net> Date: Sat Aug 22 14:01:26 2020 +0100 modsd bug, https://bugs.libre-soc.org/show_bug.cgi?id=471
the pipeline calculates this one correctly, as does DivSIM: check extra output. "DivPipeCore: modsd 17, 27, 0 'modsd 17, 27, 0\\n' [255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9223372036854775807, 0, 0, 0, 0]" 0 0 pia also gets it right: >>> 0x7fffffffffffffff % 255 >>> 127 however this might also be a bug in microwatt (urrr)
http://lists.libre-soc.org/pipermail/libre-soc-dev/2020-August/000205.html jacob this one's stopping me from being able to do comparisons on microwatt. i've a second case (this time divsd) which is producing incorrect results
commit dea6484bf446242dc049905f7a8babfdefad13bb (HEAD -> master) Author: Luke Kenneth Casson Leighton <lkcl@lkcl.net> Date: Sat Aug 22 16:07:22 2020 +0100 moved to div pipe temporarily in compunits
(In reply to Luke Kenneth Casson Leighton from comment #4) > commit dea6484bf446242dc049905f7a8babfdefad13bb (HEAD -> master) > Author: Luke Kenneth Casson Leighton <lkcl@lkcl.net> > Date: Sat Aug 22 16:07:22 2020 +0100 > > moved to div pipe temporarily in compunits git pull on ieee754fp, *might* now be getting correct results from DivPipe commit dc9082559f7fba8555c2f76a6de95a6d84a6d087 (HEAD -> master, origin/master) Author: Jacob Lifshay <programmerjake@gmail.com> Date: Sun Jul 19 20:19:22 2020 -0700 disable faulty bit_width reduction logic in DivPipeCore
AFAIK the bug was fixed by the following commit: https://git.libre-soc.org/?p=soc.git;a=commitdiff;h=a55449dd50d6a1658aec74625b3cbdb0fa17e8f9
i've still a simulator bug to track, found one yesterday, the other todo. i'll close when confirmed.