Search found 16 matches

by miker00lz
Sat Mar 16, 2013 4:03 pm
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

About the simplest TMU1 code ever: irq_set_handler(EXC_TMU1_TUNI1, irq_handler); timer_prime(TMU1, tps, 1); timer_clear(TMU1); timer_start(TMU1); Where irq_handler is prototyped as follows: static void irq_handler(irq_t source, irq_context_t *context); And tps is the number of ticks you want per se...
by miker00lz
Sat Mar 16, 2013 12:36 am
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

I've been working on this more, and I'd like to share what I've got so far. Here's a self-boot CDI image that comes with a 50 MB MS-DOS disk image with a selection of very, very old games and apps (nothing from after 1991 or so). http://rubbermallet.org/fake86-0.13.3.15-dreamcast.rar It requires tha...
by miker00lz
Wed Mar 13, 2013 7:22 pm
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

Great stuff, thanks for that! Yes, some video modes on the PC are interleaved. CGA graphics modes are, as well as EGA and some VGA modes. That's a really clever little hack with the packed pixel modes though. Good idea there. I also got a small bost by using RGB565 for the video output. It also boos...
by miker00lz
Tue Mar 12, 2013 2:03 pm
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

Excellent, thanks guys. Sorry I've been away a bit. My back has been killing me, I've been laying down a lot. I'm going to have a look at both of your guys' code. The DC keyboard I ordered came in today, so I'd like to hurry up and back into working on this. :)
by miker00lz
Fri Mar 08, 2013 8:16 pm
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

Maybe you could save the data to the VMU compressed by LZMA for example (it has a very high ratio), or these datas are completly useless? That's a pretty good idea actually. Another thing besides scores and savegames that would probably be written to disk a lot is game settings/configurations. It w...
by miker00lz
Thu Mar 07, 2013 2:46 am
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

BTW, I came up with a cheap solution for emulating a hard drive from a file off a read-only CD to prevent reporting write errors to the emulated programs. I dedicated 1 MB of the DC's RAM to remember the data sectors that want to be written, then on a read request it just check an index to see if it...
by miker00lz
Thu Mar 07, 2013 2:15 am
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

I managed to squeeze an extra 5-10% better performance out of it, depending on what it's emulating. I added a cache to hold all of the important data from the time-expensive parsing of every addressing mode byte (mod/reg/rm) in memory the first time it gets emulated. Subsequent attempts to parse the...
by miker00lz
Wed Mar 06, 2013 2:44 pm
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

I'd definitely look into optimizing the interpreter before switching to a recompiler. Usually there is some way to slim down or even eliminate the central dispatch loop and the overhead of function calls to instruction handlers. I also wonder whether it would be worthwhile to reduce the use of cond...
by miker00lz
Wed Mar 06, 2013 2:19 am
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

Am I correct in assuming that any image processing/stretching is being done in software right now? You could definitely take quite a load off of the SH4 by letting the PVR do that. Do you have a DC keyboard by any chance? It makes debugging a million times easier, and you can still leave in keyboar...
by miker00lz
Wed Mar 06, 2013 2:07 am
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

Good call not to use SDL_Mixer on DC for audio output, it works but is stupid slow compared to interfacing the AICA using the KOS library. Can you tell me how the sound is generated by the emulator? How many chanels are needed? Are the samples generated as a stream, or as clips? Well, there are 4 d...
by miker00lz
Wed Mar 06, 2013 1:33 am
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

I have a Coders Cable and a BBA, so if you need some alpha/beta test, feel free to PM me! :) Keep us informed about your project :) ! Awesome, those BBAs are SO damn expensive. I'll definitely keep you guys updated. I've got a sort of make-shift on-screen keyboard working, so even with just a regul...
by miker00lz
Mon Mar 04, 2013 3:31 am
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Re: Looking for DC optimization experts to help on emu port

Thanks for the reply. I just found a DreamCPC screenshot, and that on-screen keyboard looks perfect! :) I use both nullDC and real hardware to develop. I don't have a coder cable unfortunately, so I mostly use the emu for testing but burn it to a CD-R and run it on my DC just to be safe when I make ...
by miker00lz
Sun Mar 03, 2013 9:00 pm
Forum: Programming Discussion
Topic: Looking for DC optimization experts to help on emu port
Replies: 31
Views: 7093

Looking for DC optimization experts to help on emu port

I'm working on porting an x86 PC emu I wrote for Win32/Linux/OSX to the Dreamcast. I've got basics working like video output and controller input, but I've never programmed for the DC before. I'm fumbling my way through with the poor KOS documentation, and lots of trial and error. If anybody is inte...
by miker00lz
Sat Mar 02, 2013 8:15 pm
Forum: Programming Discussion
Topic: compile error using KOS toolchain
Replies: 3
Views: 461

Re: compile error using KOS toolchain

Alright, I ended up just using some if/else if statements instead of the switch. That compiled. Compiling and setting up the DC toolchain is kind of a PITA, so I went with the cheap fix. :)
by miker00lz
Sat Mar 02, 2013 8:07 pm
Forum: Programming Discussion
Topic: compile error using KOS toolchain
Replies: 3
Views: 461

Re: compile error using KOS toolchain

Okay, thanks. That's what I was guessing since the compiler should specify the code syntax error if that is what is wrong. I'm using gcc 4.7, it looks like the latest is 4.7.2. I'll see what happens if I upgrade.
by miker00lz
Sat Mar 02, 2013 7:58 pm
Forum: Programming Discussion
Topic: compile error using KOS toolchain
Replies: 3
Views: 461

compile error using KOS toolchain

Hi, I'm new here and to DC development in general. I'm working on porting my 8086 PC emulator to the Dreamcast (Fake86, http://sourceforge.net/projects/fake86 ). I tried DOSBOXDC, but it doesn't work very well. Anyway, during the compile using sh-elf gcc and the KOS library under cygwin I am getting...