What's new

On the road of accuracy

OP
Hacktarux

Hacktarux

Emulator Developer
Moderator
Probably, portability is really not something to worry about right now :)

I have not made progress during a few months as i had to move and change job. But i restarted working on the project last week. First problem i worked on is a start button bug in FZOOM demo. I debugged the whole button reading part of this rom and i still don't get how it works on the real console :p Here is an overview:
- the rom starts a dma transfer of the controller state to the RAM
- then it asks to write back and invalidate the cpu cache line of the dma destination
- something is written by the cpu in destination location: at this stage it is only in cpu cache
- the dma ends and

steps 3 and 4 are not always in this order depending on pif timing. It can be considered a bug, the buttons are not always read correctly.... On all over emulators, these kinds of problem can not be seen as cache is not emulated.

Nevertheless all this investigation was useless. The problem was that i was just forgetting to initialize the button state to 0 :/
I still have a few fpu opcodes missing but i hope FZOOM will work soon. This demo may seem simple but it need a large part of the FPU done correctly.


I still have some difficulties to measure time taken by pif operations. For example:
- write to pif ram
- read from pif ram
- reading and writing from/to pif ram using the SI dma.

I anyone has any result on the speed of these operations, i'd be glad to hear how you measured it. Every time i try it seems inconsistent.
 
Last edited:

Rodimus Primal

New member
Life changes so good luck with the new job Hack. As for progress, Rome wasn't built in a day but its good to hear how much has progressed. Keep up the good work! Soon enough there will be a N64 emulator for PCs that does what BSNES has done for SNES.
 
OP
Hacktarux

Hacktarux

Emulator Developer
Moderator
It took longer than expected and i had to pause the project for several months but here it is. It required a major rewrite of the fpu pipeline emulation. As you can see there are some vertical artifacts at the botom of the screen during fractal zooming. That seems caused by the processor cache not handled correctly by this demo. Hopefully, emulating it will some other more positive effects in commercial games ;-)

 

squall_leonhart

The Great Gunblade Wielder
D: cycle accurate is a dangerous term with mudlord :<

but maybe in the n64 case, cycle accuracy would resolve some of the weirder glitches
 

Zera

New member
Exciting stuff. But the hardware needed for a cycle accurate N64 Emu may not exist yet. Still, you never know with technology these days.
 

DETOMINE

New member
wrong, mandelbrot can be done without floating point numbers.
I like the way you're always being aggressive and stuff.
You know, I'm just a casual gamer who like to play some N64 games like in the days my N64 was still working.
You seem to be persuaded that a cycle accurate emulator is a waste of time and it's your right.
I just don't understand why you keep posting on subject that doesn't seem to interest you.

But I think you're taking it too seriously. You and Hacktarux can do whatever you want in your free time, and as far as I am concerned, me too...
 
OP
Hacktarux

Hacktarux

Emulator Developer
Moderator
It is not a matter of how mandelbrot should be done, or what does it require. I have only used this demo that is using heavily the n64 fpu to test my fpu implementation. I post it here so that people interested in this project can see how it progresses but if it disturbs people that much, i can keep it private. So if you are not interested i can't see why you are posting here.

The only thing i will tell about accuracy in this thread, is that up until now (and i was one the developpers who attempted it with mupen64), all emulators have focused on developping something fast enough for current computers and to improve accuracy later. With mupen64, i think i have reached some limits of this approach: with time it is harder and harder to improve accuracy. With this new project, i am attempting to buld an almost perfect model of the n64 and then improve speed step by step. It is fun to do, will provide a great tool for n64 programming and maybe one day (but not sure) a platform to play n64 games. I won't discuss more on this thread about the pros and cons of a really accurate emulator. If you want to discuss more about that, please create another thread.
 

mrmudlord

New member
So in other words: replicating what the MAME/MESS people have been doing and doing the bsnes approach to it.
That, and using a broken and unoptimized Mandelbrot fractal as a "test" to prove you did something.

In that case, I have nothing to say in regards to this project any more in this subforum. Good luck. <_<
 

DETOMINE

New member
It is not a matter of how mandelbrot should be done, or what does it require. I have only used this demo that is using heavily the n64 fpu to test my fpu implementation. I post it here so that people interested in this project can see how it progresses but if it disturbs people that much, i can keep it private. So if you are not interested i can't see why you are posting here.
The only thing i will tell about accuracy in this thread, is that up until now (and i was one the developpers who attempted it with mupen64), all emulators have focused on developping something fast enough for current computers and to improve accuracy later. With mupen64, i think i have reached some limits of this approach: with time it is harder and harder to improve accuracy. With this new project, i am attempting to buld an almost perfect model of the n64 and then improve speed step by step. It is fun to do, will provide a great tool for n64 programming and maybe one day (but not sure) a platform to play n64 games. I won't discuss more on this thread about the pros and cons of a really accurate emulator. If you want to discuss more about that, please create another thread.

Please don't keep it private, some people (me included) share your interest in (precise) emulation. I don't care if it takes 20 years before being able to emulate perfectly every N64's games. I personally think N64 (and others) is a piece of history and emulation is a way to preserve that history. Though I must say that as I am not a programmer, I don't understand many of the things that come across this thread.

@mrmudlord : please respect the work of other people, you're not the centre of the world you know...
 

Remote

Active member
Moderator
Agreed, reading progress reports and thought on implementation is often (always) more interesting then seing the actual outcome. And there is always going to be haters, only hating to get their 15 min in the spotlight. I can still remember when people said that 640 kB of ram was more then plentyfull :p
 

Stachelsk

New member
I, too, am extremely interested in this work. I'm mostly a lurker on these forums, but began studying the N64 a couple months ago and have too been working towards writing a cycle-accurate simulator. Your work so far has been very impressive, here's to hoping that you can get simulation running at full-speed someday.
 

EmulationEmu

New member
Have also been following this for a while, but mrmudlords incoherent ranting has inspired me to say that I think this project is awesome and I'm very much enjoying watching things develop. Thanks for keeping us updated!
 

Top