English Amiga Board


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

 
 
Thread Tools
Old 17 July 2024, 19:05   #21
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 54
Posts: 4,504
The simplest answer might be that cop1lc to internal copy is done only when DMA is active.

But here I venture with my 'alternative' explanation* (which will be refuted when we have more informations ).

I think it has to do with the absolute first DMA fetch word at the VB (or, as in this case, at the DMA reactivation after VB).
It is not as you might expect the first instruction of the 'new' copper list, but the word following the last of the 'old' one.
So I think what happens is that it is simply used as STROBE (and therefore starts as if it were done manually) from the value present in COP1LC.

The problem is that the address of COPJMP is not present on the RGA but that of COPINS...

EDIT: *no, this cannot be for 'prefetch' reasons
The 'old' word act like the second word after a COPJMP strobe, i.e. suppressed to COPINS destination.

So the simplest answer remains the first: the Copper start require both VB and COPEN -> strobe -> 'standard' COP1LC to COPPTR (and 'usual' 'old' word suppressed to COPINS because of prefetch).

Sequence at VB+COPEN start: COPINS (old) COPINS (new) DEST (new)

Last edited by ross; 17 July 2024 at 20:16.
ross is offline  
Old 17 July 2024, 20:38   #22
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,582
COPJMPx (or indirect via VBLANK) strobe only pre-selects which pointer register to copy. Actual COPxLC to internal pointer register copy requires enabled DMA and execution of COPJMP cycle sequence. Which means last written COPxLC is copied when DMA is re-enabled and copper got few free cycles.

Infamous copper wait blitter bug is related to this (happens when blitter is active, copper is waiting and CPU writes to COPJMPx during odd cycle and blitter also wants the cycle), the copper cycle that does the COPxLC to internal copy gets "stolen" by blitter and DMA addressing logic gets confused causing COPxLC getting copied to selected blitter pointer..
Toni Wilen is online now  
Old Today, 19:56   #23
Blueberry
Registered User
 
Join Date: Dec 2007
Location: Aarhus / Denmark
Posts: 45
Quote:
Originally Posted by ross View Post
Not only 0, all Copper 'opcodes' that do a Move on 'protected' RGA registers (i.e. the usuals with CDANG=0)
I did some testing to make sure I understood this correctly.

AFAICT, a MOVE will halt the copper if (and only if) it attempts to write to a register that is prohibited according to the current setting of CDANG.

Specifically, on ECS and above, when CDANG=1, the copper can access all registers, and thus a MOVE will never halt the copper due to this mechanism, even when writing to register 0.

Last edited by Blueberry; Today at 21:00.
Blueberry is offline  
Old Today, 21:06   #24
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 54
Posts: 4,504
Quote:
Originally Posted by Blueberry View Post
I did some testing to make sure I understood this correctly.
...
Everything correct.
So if you want to use CHALT for some reason, and that it works on any chipset, it is important to set CDANG=0 first (as it usually is, but better to do it because someone might have changed it before you..).
ross is offline  
 


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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Copper WAIT, copper SKIP and $80/$100 vpos problem defor Coders. Asm / Hardware 2 23 July 2021 08:32
Combining copper scrolling with copper background phx Coders. Asm / Hardware 16 13 February 2021 12:41
Copper, Horizontal Blanking, and DMA AlexBruger support.Hardware 5 19 July 2020 17:31
Copper instructions and dma Jherek Carnelia Coders. Asm / Hardware 4 05 December 2019 22:33
Best way to mix blitting with copper and copper effects roondar Coders. Asm / Hardware 3 12 September 2016 13:12

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 22:11.

Top

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