Thread: 68k details
View Single Post
Old 14 November 2018, 20:16   #780
coder76
Registered User
 
Join Date: Dec 2016
Location: Finland
Posts: 168
It's not easy to compare instruction cycle count between various architectures. If you look in MC68020 manual, there's 3 cases given for each instruction, best, cache and worst. Typically you would be interested in cache cases and try to optimize your code towards best case. By trying out first various memory alignments of start of code and then try to reorder instructions for better performance. Branches also have different cycle counts depending on whether the branch is taken or not. Variations between best and worst cases can be large, e.g. 2-3x cycles. Also, in some cases an instruction can take 0 cycles to execute (goes in parallell with some other) or then a few cycles, so difference is infinite.

You also can't see performance of a CPU by just looking at cycle counts for each instruction and comparing it against other CPUs . There are other factors, like cache performance, and number of registers available, which are also important for performance. The x86 cycles for instructions seem on paper often impressive, but x86's lacked the amount of CPU registers that 680x0's have. Also, the 386/486 caches weren't as good as 68030/68040's caches (386 had some sort of external cache).
coder76 is offline  
 
Page generated in 0.19323 seconds with 11 queries