' Display Clear Test By Kev G. v2.0 - For The AMOS Factory
'
'
Screen Open 0,320,256,16,Lowres : Flash Off : Curs Off : Ink 1,0 : Cls 0
'
Print "Press any key to start the test."
Wait Key
'
Amos Lock
E=Execall(-132) : Rem disbale O.S.
'
ITERATIONS=100
'
P0_PHYS=Phybase(0)
P1_PHYS=Phybase(1)
P2_PHYS=Phybase(2)
P3_PHYS=Phybase(3)
'
P0_END=P0_PHYS+10240
P1_END=P1_PHYS+10240
P2_END=P2_PHYS+10240
P3_END=P3_PHYS+10240
'
'First test.. AMOS CLS.
'
TIME1=Timer
For I=1 To ITERATIONS
Cls 0
Next I
TIME2=Timer
TEST1=TIME2-TIME1
'
'Second test.. AMOS FILL
TIME1=Timer
For I=1 To ITERATIONS
Fill P0_PHYS To P0_END,$0
Fill P1_PHYS To P1_END,$0
Fill P2_PHYS To P2_END,$0
Fill P3_PHYS To P3_END,$0
Next I
TIME2=Timer
TEST2=TIME2-TIME1
'
'Third test.. The Turbo Blit Clear command
TIME1=Timer
For I=1 To ITERATIONS
Blit Clear -1
Next I
TIME2=Timer
TEST3=TIME2-TIME1
'
'Fourth Test.. The Turbo Blit + Fill Command
TIME1=Timer
For I=1 To ITERATIONS
Blit Clear 1
Fill P1_PHYS To P1_END,$0
Blit Clear 3
Fill P3_PHYS To P3_END,$0
Next I
TIME2=Timer
TEST4=TIME2-TIME1
'
' Print results....
'
Print "AMOS CLS time = "+Str$(TEST1)+" (50ths/sec)"
Print "AMOS FILL time = "+Str$(TEST2)+" (50ths/sec)"
Print "TURBO BLIT time = "+Str$(TEST3)+" (50ths/sec)"
Print "FILL + TURBO BLIT = "+Str$(TEST4)+" (50ths/sec)"
Print
Print "Press a key to end"
'
E=Execall(-138) : Rem enable O.S.
Amos Unlock
'
Wait Key
End
'
' ********************
' MY RESULTS
' ********************
'
' TEST 1 - A600 2MB Chip RAM
'
' AMOS CLS = 134
' AMOS FILL = 113
' TURBO BLIT = 86
' BLIT + FILL = 71
'
'
' TEST 2 - A1200 2MB Chip, 4MB Fast
'
' AMOS CLS = 133
' AMOS FILL = 30 !!!!!
' TURBO BLIT = 89
' BLIT + FILL = 43
'
'
' Conclusions from this test.
' There is no speed advantage using the turbo Blit command on its own or the AMOS CLS command.
' There was a slight improvement using a combination of BLIT + FILL.
' However, there is a massive improvement using the FILL command alone (A1200).
' If you are developing AMOS programs for the A1200 or above then use the FILL routine.
' If you need speed and compatibility with A500/A600 then go for BLIT + FILL
'
' The program was compiled and the resulting executable file was used for this test.
' All times are in 50ths of a second. Less is better.