slingshot wrote:The most notable is MOVEM.l d0-d7/a0-a6, (-a7),
MasterOfGizmo wrote:slingshot wrote:The most notable is MOVEM.l d0-d7/a0-a6, (-a7),
The tg68k is not cycle exact. So there are differences. But they are usually in the range of +/-5%.
According to http://oldwww.nvg.ntnu.no/amiga/MC680x0 ... mpetc.HTML The "movem.l regs,-(aX)" takes 8+8n clock cycles with n being the number of registers to store. A bus cycles on the real 68000 is four clock cycles, so this is 2+2n bus cycles which makes sense since each register is 32 bits and it takes two bus cycles to write 32 bits via the 16 bit bus. In the genesis the CPU is clocked at 53/7=~7.6 Mhz.
For the TG68 in the fpgagen the clock is additionally divided by 4 resulting in ~1.9MHz. But it runs at full speed. It needs one cycle to fetch the instruction, one to fetch a word containing the register mask and then it writes all registers one 16 bit word per cycle. This results in 2+2n bus cycles.
So the movem.l instruction should be quite exact with respect to the execution time.
slingshot wrote:I calculated as: the cpu clock is roughly the same as the pixel clock. So 8+8*15=128 cycles would be required for this instruction, it's about 128 pixels. But currently the horizontal counter advances much less.
Created a SignalTap capture: INTACK cycle is about 22 pixels, but I read it should be 44 cycles. The long MOVEM instruction is 70 pixels, should be more than 100. So these are 30-50% faster than necessary. At the end, read of the counter happens about 150 cycles(pixels) before it should.
MasterOfGizmo wrote:The movem.l with 15 registers takes 32 (2*15+2) bus cycles. A bus cycle at 1.9MHz is roughly 500ns, so the movem.l should be 16us. One line at 15khz is 64us. So a movem.l is roughly 1/4 line which at 512 pixel clock per line is roughly 128 pixels. So we agree on that
So something is wrong here.
jotego wrote:The game Dragon, the Bruce Lee Story doesn't work with FPGAgen version 2018-10-13. I don't know if it worked with previous versions, I suppose it didn't. It's just a blank screen.
slingshot wrote:As I see from the capture, it writes one register in 14 MCLKs, which is 2 CPU clocks - twice as fast as it should be.
MasterOfGizmo wrote:As already written in PM it was actually four times as fast as it should have. Although it never really ran that fast because memory access was slowing it down somewhat, Still we now know that most Genesis games cope with a way faster CPU. I wonder if there are games that would benefit from it like giving a faster refresh rate or the like.
hyperterminal wrote:Here is a compatibility list for games running with a faster CPU: http://www.sega-16.com/forum/showthread ... ility-List
MasterOfGizmo wrote:BTW: Did you now that you can place any rom under the name "genesis.rom" in the SD cards root directory and it will be loaded automatically at startup. I have mine permanently set to run Sonic.
For some reason the latest changes prevent the titan overdrive demo to run further than the initial robot progress bar.
Users browsing this forum: No registered users and 4 guests