So I can now boot Irix 6.5 (emulated Indy) in ~45 seconds on a relatively modern computer (Intel 12400F + NVME) with Mame.
While Mame proudly cares more about emulation accuracy than performance, there are a few things that can be done in the code to make this run a bit better. It took some profiling and hacking, and here are some initial findings:
1. DRC (dynamic recompiler) on windows is useless. Although it now works (v277 and later), it doesn't yield much in terms of performance.
2. There are three main reasons for low speed
2.a. Emulation - the only possible improvement can come from better DRC (or better DRC configuration).
2.b. Memory access - mips emulation uses emumem.h and some very slow generic routines, specifically RWORD macro expands to a lot of code. This (RWORD) eats up as much as 70% of the host CPU. To make things worse, this is so wrapped up in some C++ wizardry with templates it is really not trivial to overcome. I've started by adding dedicated memory macros for R4600 (see patch in the zip below), so watch this space.
2.c. Disk access. Now while this doesn't come up much in the profiler, it has a huge impact on boot time and general responsiveness of the OS. Simple bump in the wd33c clock resulted in the boot time going from 1 minute to 45 seconds. This can't be done in the UI unfortunately so I've included the patch + pre-built binary for windows in the zip below.
I've also bumped CPU to 133MHz. Emulation speed does dip occasionally to below 50%, mostly when graphics and disk get busy but this emulation still feels more responsive than a real low-end indy.
So I wrapped up my "optimised" build here. The linked zip contains everything you need to get this going:
1. indy_indigo2.exe - it's basically mame.exe built just for indy emulation (and also so we don't overwrite your original mame.exe)
2. roms and nvram directories needed for SGI emulation. This is safe to unzip even if you already have them.
3. run-net-no-throttle.bat - a batch file to run the emulator with recommended options. Make sure you look at this and that the CHD name matches your image filename (-hard1 option).
4. Patch file in case you want to build this yourself. The patch is for revision
https://github.com/mamedev/mame/commit/3...6f5483f213
Anyway, here is how to use it:
1. Get latest mame, install it and place the CHD image in the mame installation root (where your mame.exe lands).
2. Unzip the linked zip over the Mame installation. This will just add files so won't break anything.
3. Verify that indy_indigo2.exe ended up in the mame root directory (same directory where you have mame.exe)
4. Edit run-net-no-throttle.bat and set CHD file name to your CHD (-hard1 option)
5. Run run-net-no-throttle.bat
And the link to the zip:
https://spektar.io/download/mame-irix/indy-patched.zip
Side notes on how far I got with this.
I got networking going (not easy - needs tap/tun + bridged eth adapter + IP forwarding).
A big issue for mame is mouse handling. It wont pass mouse coordinates to Irix, and instead it creates a virtual mouse that translates your mouse movements to presumably ps2 signals. It's a very poor solution. So once you get networking going, you can use Xming or any Linux machine to connect remotely. It's a comfortable and very usable Irix experience. Most apps + OpenGL (ideas demo, bzflag, cycles) work a treat with Xming 7 on Windows (
get Xming here, definitely worth £10 if nothing else for the support you get from Colin). Native IrisGL stuff (buttonfly, atlantis) of course will only work locally or if you connect from an SGI box, or perhaps you can try with
igl.
For a modern browser on Irix, I use
ssh -X <modern-linux-box> firefox which runs modern firefox on a linux machine and renders on my windows box via XMing. This works super fast - Irix only does window management, all the rendering / memory and disk access is away from the emulator. I also have a directory mounted via NFS so I can get to downloads and other files.
Frankly I would have preferred to see Irix on qemu or some serious virtualisation environment, but with all it's flaws and idiosyncrasies, you can make Mame work.
To close, here is an obligatory screenshot: