Re: [hatari-devel] CPU emulation issue in 68030 emulation? (movem.w (sp)+,Dn) |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
- To: hatari-devel@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [hatari-devel] CPU emulation issue in 68030 emulation? (movem.w (sp)+,Dn)
- From: Uwe Seimet <Uwe.Seimet@xxxxxxxxx>
- Date: Sat, 7 Sep 2024 20:52:55 +0200
- Arc-authentication-results: i=1; strato.com; arc=none; dkim=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; t=1725735178; s=strato-dkim-0002; d=strato.com; h=In-Reply-To:References:Message-ID:Subject:To:From:Date:Cc:Date:From: Subject:Sender; bh=80w3UAq3zC1m3/KQgxY+RlsDef664mb6jFZ0dJ01BIU=; b=Zh7Q9ZrsKgu3glF82GXcSWGz3UlsUQ3TuHd+kAq/ndOPFNgtWbghJSOvFfn3hd8coY XIAydyazOO7xBbNilFpyW8QhFumCf3gY+EhDbfmliC+h2/6KYZsWvPfcDdGwHQKnoE99 UvLgtuN9nFLPvwWqVcIakW0vvjO41AtUXQ5KVhLrkQi2Yb9xaO4ubb5zCffaSPV8MBYW eHv0p1mV+fpnKvniBFAxuTJrCG0V72NHXlCBlcTWH62p1dSQV1/fKOUnS3wcc59LVEIe zOkICAyllPIDTS10zvLEyjCjNL+NCu6DhTfPaV6j+TvVN9aoS73QzV0QgvsfqIWi/PVR VouA==
- Arc-seal: i=1; a=rsa-sha256; t=1725735178; cv=none; d=strato.com; s=strato-dkim-0002; b=JLkd9xMxvv8pb8D+A/MwWIgwByyApTJHL1dajDq3Q0XMvhh5XpcpcNhh0DAH6+FJTt OloUQ4n/448QRinlMUQDWWj0z3k63FOnyo+1fNt16IzOR1fSAiA9tZlK9FqMczXG3Ihs s/d3rVtI4z0S3wMs1mCXt3Y1bXLufeAbUNLyYPGjitJufq9u1mKJYtrhu8ACJgTreT1Y L5O6kq/4lV2EXXvJ2L+BWEqLtEoSQ5+nZlGd2BAxP7qX0m3waSgT5dmZUh3fCxu3XAZX aRptc5nwmLJrdCl+MX9b5feOckGUPsYur9gXJgbrc7yb3amSyMEu/Tih9ZkjA0G+aKyC pZ4Q==
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1725735178; s=strato-dkim-0002; d=seimet.de; h=In-Reply-To:References:Message-ID:Subject:To:From:Date:Cc:Date:From: Subject:Sender; bh=80w3UAq3zC1m3/KQgxY+RlsDef664mb6jFZ0dJ01BIU=; b=cZF5aMRWTUWymgCKOVDb3vLTyRtDyH8mgQ+FvEE6XEt9scvCJFrPFA0kGI6yd3I2I6 wE3jrlteaBFOzXmmsBuNsQM1ovHTim3XpHtXGu+/jb5xG9qolJLhSSEVEMUBuQ12aDox luI7hoa9GpE21s/BKRgzdQZE4GIfBCOwPgmcylxO8iTtCD8W65WdFLBRX4cSQB8wEL7u AE0qE+fPVPW7eVykNyFY32GCyQui5xgp+ylfSrcHNb17mxX1YQpnQcQjEcTVXCo67cVg 3ByompzACL55SJzAQbInoECbDfIXDAA0eDh1g1uIHU2r/MCvo3UVNDlpK2tLVlCvXunu 8lGg==
- Dkim-signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; t=1725735178; s=strato-dkim-0003; d=seimet.de; h=In-Reply-To:References:Message-ID:Subject:To:From:Date:Cc:Date:From: Subject:Sender; bh=80w3UAq3zC1m3/KQgxY+RlsDef664mb6jFZ0dJ01BIU=; b=YcoRpGdQOanNXZbA4CiqZ57YZy/5Q17E75JrJp+KLcsaXDBXohDjsw0Gb52qkieKed 5v8ff1620p2sRg1KXeBw==
Thank you for checking this.
>
> > Am 07.09.2024 um 19:54 schrieb Uwe Seimet <Uwe.Seimet@xxxxxxxxx>:
> >
> > Hi,
> >
> > I just stumbled upon this in the 68030 emulation:
> >
> > moveq #0,d0
> > move #$ffff,-(sp)
> > movem.w (sp)+,d0
> >
> > D0 now is $ffffffff, but it should be $0000ffff, shouldn't it? For an
> > address register $ffffffff would be correct, but not for a data register.
> > Or am I missing something?
> >
> > Best regards
> >
> > Uwe
> >
>
> I think it is correct. See https://68k.hax.com/MOVEM:
>
> „In the case of a word transfer to either address or data registers, each word is sign extended to 32 bits, and the resulting long word is loaded into the associated register.“