English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Asm / Hardware

 
 
Thread Tools
Old 15 July 2017, 15:53   #1
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,303
68030 vs 68020 line-f behaviour

Hi,

Trying to fix a 030-specific bug report on a whdload slave, I found out that the game uses LINEF emulator vector

When 68020, 2+A7 contains the address of the LINE-F instruction
When 68030, 2+A7 contains the address of the LINE-F instruction + 4 !!!!

(tested on WinUAE)

Anyone can comment on that difference? Where is that behaviour documented? (I suppose that it wasn't coded like that in WinUAE just for fun)
jotd is offline  
Old 15 July 2017, 16:02   #2
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,534
Which opcode word?

(Either it is a bug, or MMU instruction which was "executed" normally and following F-line caused the exception)
Toni Wilen is offline  
Old 15 July 2017, 17:53   #3
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,303
F005 (followed by 43FA 0A1C)

So on 68020, taking the "code" of the line-F gives "5", whereas on 68030 it takes 0A1C (and "skips" the LEA opcode)

could be a WinUAE-only bug: http://mantis.whdload.de/view.php?id=3171
jotd is offline  
Old 15 July 2017, 20:10   #4
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,534
It is PMOVE but it does not appear to be valid PMOVE. It probably causes F-line on real 68030.

68030 MMU instructions does not do much validation, needs to be fixed..
Toni Wilen is offline  
Old 15 July 2017, 20:23   #5
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,303
ok thanks for confirming.
jotd is offline  
Old 15 July 2017, 20:35   #6
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,534
It is not yet 100% confirmed, that needs 1-2 days more
Toni Wilen is offline  
Old 16 July 2017, 19:25   #7
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,534
Confirmed. Game uses MMU instructions that have invalid mode/reg pair and also other invalid bits set that 68030 won't accept and will generate F-line.

I tested all real 68030 MMU instruction bit combinations. Emulation should be correct now.

(68040+ don't have this problem, they don't have multiple different modes and "unused" opcode bits)

EDIT: Thanks for reporting it instead of quietly adding some workaround!

Last edited by Toni Wilen; 16 July 2017 at 19:52.
Toni Wilen is offline  
Old 16 July 2017, 20:29   #8
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,303
You're welcome Toni! (I doubt I could've workarounded this anyway)
jotd is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Understanding the (in)famous copper's lost cycle (PAL all line, NTSC short line). ross Coders. Asm / Hardware 10 13 March 2017 17:50
Overclocking 68020? Marchie support.Hardware 8 11 October 2016 13:33
68020 33 MHz Leandro Jardim support.WinUAE 2 02 January 2012 19:21
Questions about 68020 CE Maren support.WinUAE 11 09 December 2009 21:01
Apollo 1220 - instructions and 68020 to 68030 upgrade fc.studio support.Hardware 11 10 January 2008 20:30

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 13:59.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.07215 seconds with 14 queries