Re: [hatari-devel] Basic cpu testsuite

[ Thread Index | Date Index | More Archives ]

> PS.: while looking at the code, there seems to be a check missing for moving a 
> control register to/from an address register: according to the documentation, 
> that is only allowed for the fpiar, but not for fpsr or fpcr.

Good catch. It also lacks check if multiple control register bits are
set at the same time (or none) which works strangely on 68060.. I'll
attach patch later today.

Quick real hardware tests:

If no bits set: same as FPIAR bit set.
Except if 68060 and An: F-line. If Dn: it works same as 68882 and 68040.

If more than one bit set: F-line.
Except if 68060: very strange behavior, nothing seems to happen
(registers not modified), except if all control register bits are set:
at least FPIAR gets set to some weird value..

So it looks like logic is only partially implemented in 68060 and it
does something undocumented if invalid bit combinations are set.

I am not sure how to handle 68060 case in emulation when more than one
bit is set (or no bits set An case). Technically it probably should do
nothing in emulation but because it can also do very weird things, it
may be better idea to just cause f-line.

But I have bad experiences of trying to be too strict in emulation (than
in real world): There is always at least one mysterious badly coded
program that does something really stupid enough to break when emulation
is technically correct but not exact same as in real world.

Mail converted by MHonArc 2.6.19+