TASEmulators / gens-rerecording

The Gens rerecording project, a Sega Genesis, 32x, Sega CD emulator. The primary purpose is to expand features related to creating Tool-Assisted movies.
http://tasvideos.org/EmulatorResources/Gens.html
20 stars 10 forks source link

LSL.L emulation incorrect #108

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
D0 = 0x12211221 
D1 = 0x20
lsl.l d0,d1  (opcode E3A8)

After execution: D0=0x80000000 instead of 0

Original issue reported on code.google.com by r57sh...@uralweb.ru on 12 Oct 2013 at 2:54

GoogleCodeExporter commented 9 years ago
For what is worth, the root of the problem is that StarScream uses native x86 
left shift instruction for this, which is modulo 32, instead of properly 
accounting for the fact that the shift should be modulo 64.

Original comment by marz...@gmail.com on 4 Sep 2014 at 1:41

GoogleCodeExporter commented 9 years ago
So, I have been taking a look at this. StarScream is a horrid mess of 
unmaintainable, unportable, inextensible code; the more time I spent looking at 
its code, the more I am convinced it should be burned to the ground and 
forgotten, and a new core be written instead.

If you are think it is not that bad, you are right, in a way: it is worse.

Original comment by marz...@gmail.com on 5 Dec 2014 at 1:10

DerekTurtleRoe commented 9 years ago

We could use FAME for this (Fast and Accurate Motorola Emulation library). Will look into everything when we organize the repo.