Skip to content

Commit

Permalink
Added early WOW MIPS demo disks
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffpar committed Nov 4, 2023
1 parent 9ea96b8 commit 745b046
Show file tree
Hide file tree
Showing 4 changed files with 7,386 additions and 5 deletions.
18 changes: 13 additions & 5 deletions pcx86/diskettes.json
Original file line number Diff line number Diff line change
Expand Up @@ -3190,11 +3190,19 @@
"@format": "PC360K"
},
{
"@title": "Jeff's PC DOS 1.00 with MASM",
"@diskette": "JEFFPAR-PCDOS100-MASM100-160K.img",
"@link": "/software/pcjs/JEFFPAR-PCDOS100-MASM100-160K.img",
"@localonly": true,
"@format": "PC160K"
"@title": "WOW Reversi MIPS Demo (Disk 1)",
"@diskette": "JEFFPAR-WOW-REVERSI-MIPS-DISK1.json",
"@format": "PC1200K"
},
{
"@title": "WOW Reversi MIPS Demo (Disk 2)",
"@diskette": "JEFFPAR-WOW-REVERSI-MIPS-DISK2.json",
"@format": "PC1200K"
},
{
"@title": "WOW Reversi MIPS Demo (Disk 3)",
"@diskette": "JEFFPAR-WOW-REVERSI-MIPS-DISK3.json",
"@format": "PC1200K"
}
]
}
Expand Down
Loading

22 comments on commit 745b046

@hyenasky
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These disks are fascinating. They look like they contain an April 1991 build of NT, for a Jazz board with an R3000 chip (WOW indeed!). Any idea what the NT build number is?

@jeffpar
Copy link
Owner Author

@jeffpar jeffpar commented on 745b046 Nov 7, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't recall, sorry. I believe these files memorialize our first attempt to run a 16-bit Intel Windows binary (eg, Reversi) on a MIPS NT build, using a using a rudimentary x86 emulator I'd written for the demo. If anyone figures out how to do anything useful with these files, be sure to let me know. :-) Thanks.

@iProgramMC
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is cool! I thought it may have been an accidental addition personally. But what do these have to do with PCjs? They're specifically for hardware based on MIPS.

@hyenasky
Copy link

@hyenasky hyenasky commented on 745b046 Nov 7, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jeffpar The current best idea is to try it with a Jazz machine, emulated in MAME. However, Jazz had an R4000, while this build seems to be R3000 (which is quite exotic), so one would have to jerry-rig an R3000 Jazz in MAME (with custom firmware) and then do some trial and error.

Do you remember enough about the hardware this ran on to say whether that's a good start?

@jeffpar
Copy link
Owner Author

@jeffpar jeffpar commented on 745b046 Nov 7, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True, the binaries are only viewable (not runnable) in PCjs, but I didn't have a better place to store them, and I don't plan on doing a MIPS emulator any time soon, so here they are for now. As for hardware details, I honestly don't recall, but it sounds like you're on the right track. The only other bit of information I was able to find is a PDF copy of some early WOW planning email, which may be helpful. As soon as it's uploaded, I'll post a link here.

@jeffpar
Copy link
Owner Author

@jeffpar jeffpar commented on 745b046 Nov 7, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hyenasky
Copy link

@hyenasky hyenasky commented on 745b046 Nov 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jeffpar I put together a simple R3000 Jazz platform and managed to get an ARC firmware running on it and loading the kernel, which hangs waiting for a debugger connection (miraculously, the R3000 Jazz IO as used by this NT kernel seems to be identical to the R4000 Jazz stuff). The trouble now is that the mipskd debugger (running on OS/2) doesn't seem to want to connect; almost like it's waiting for something else. I noticed that mipskd sends: boot -f mop(1)/ntoskrnl.exe over serial, first thing after you run it; probably as a command over serial to some ancient firmware. Do you recall anything about what mop(1) means here, or what the debugger might be waiting for?

@thewanderingtraderm
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jeffpar where did you get these images from

@jeffpar
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the physical diskettes that I backed the files up on in 1991.

@thewanderingtraderm
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you have any other beta versions of windows?

@jeffpar
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jeffpar I put together a simple R3000 Jazz platform and managed to get an ARC firmware running on it and loading the kernel, which hangs waiting for a debugger connection (miraculously, the R3000 Jazz IO as used by this NT kernel seems to be identical to the R4000 Jazz stuff). The trouble now is that the mipskd debugger (running on OS/2) doesn't seem to want to connect; almost like it's waiting for something else. I noticed that mipskd sends: boot -f mop(1)/ntoskrnl.exe over serial, first thing after you run it; probably as a command over serial to some ancient firmware. Do you recall anything about what mop(1) means here, or what the debugger might be waiting for?

I've asked some other WOW developers if they recall anything useful and will let you know. Other than preparing for the April 1991 demo, I did very little work with MIPS hardware, and my recollections of NT kernel debugging are vague (I moved to the Windows team in mid-1991), so you may have to sleuth this out on your own.

@jeffpar
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you have any other beta versions of windows?

No. I might have a few more old OS/2 files somewhere, but that's probably it.

@hyenasky
Copy link

@hyenasky hyenasky commented on 745b046 Nov 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've asked some other WOW developers if they recall anything useful and will let you know. Other than preparing for the April 1991 demo, I did very little work with MIPS hardware, and my recollections of NT kernel debugging are vague (I moved to the Windows team in mid-1991), so you may have to sleuth this out on your own.

Nice, thank you! Also, if you have any idea where a real firmware image/source code for R3000 Jazz might be found, or someone who might have one, that would be extremely helpful. I think it's possible to make do without it, but it makes debugging these weird issues much more difficult when you can't tell whether it's your hacked-up ARC's fault.

@neozeed
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you have any other beta versions of windows?

No. I might have a few more old OS/2 files somewhere, but that's probably it.

None of the Microsoft OS/2 2.0 stuff by any chance?

One of the tee shirts appeared on eBay, love the Star Trek V vibe!

@hyenasky
Copy link

@hyenasky hyenasky commented on 745b046 Nov 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jeffpar I thought you'd like to hear that myself and @substanc3-dev managed to boot this build in a purpose-built R3000 Jazz emulator with custom firmware!
0007
0004
sdfgsdf

@jeffpar
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WOW indeed! That is so cool. I had my doubts those disks were even usable, especially considering how little help or other info I was able to find. You guys are awesome.
You should think about doing a write-up on the whole process you went through. You’re welcome to do a guest post on my blog, but it doesn’t matter where, it should be a great read. Thanks for doing this!

@jackson2k2
Copy link

@jackson2k2 jackson2k2 commented on 745b046 Nov 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here's the essential of what had to be done to get it working:

  • There was already an emulator (MAME) that emulates a Jazz reference design for the MIPS R4000.
  • MAME is the only emulator to emulate a MIPS machine that can install and boot Windows NT 3.1.
  • Because the MIPS R3000 has incompatibilities, a custom firmware had to be hacked from scratch.
  • To the obvious, a separate machine driver also had to be created to support this custom firmware.

Because it's a homebrew hackjob, it obviously will not be accepted in MAME, but here's the gist:

  • Most of the infrastructure between the MIPS Magnum and the Jazz R3000 board that this build uses are the same.
  • This also helped fix a bug with the Innotek G300 emulation that was already in MAME, including masking problems with DMA translation and a race condition within multithreading critical sections of the MCT-ADR DMA chip emulation.
  • There is currently a hack in the PS/2 emulation to disable interrupts for a brief period of time after self reset. The keyboard controller firmware, which is emulated at a low level, appears to be different between IBM machines and Jazz boards, and this build will not work without that behavior. The Jazz firmware is currently undumped.
  • MAME currently seems to have trouble syncing at 19200 baud for some reason-- that looks to be a bug within MAME, so the UART emulation is forced to run at 9600 baud and the debugger was patched.
  • The CPU frequency had to be lowered from 50 to 25 MHz. Write buffering also needs to be disabled for branch conditionals and there's a hack in the address translation to disable a caching conditional.
  • An interrupt in the I82357 EISA controller had to be disabled.

@jeffpar
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So many hurdles, and you didn't lose hope. Just saying thanks seems insufficient. Let me know if there's something I can help sponsor (a project, a hardware request, whatever) to thank you for your time, too. Also hoping you will ultimately be able to share a set of binaries or files to help others recreate the experience (including your custom firmware and driver).

@iProgramMC
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Of course we will share a guide on how to set it up :)

To add to @jackson2k2's comment: there's also a problem with the SCSI controller - for whatever reason, for me, the kernel times out waiting for an interrupt from it and enters a reset loop, trying to reset the controller, then wondering what the hell the state that the controller reports means.

@roytam1
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because it's a homebrew hackjob, it obviously will not be accepted in MAME, but here's the gist:

* Most of the infrastructure between the MIPS Magnum and the Jazz R3000 board that this build uses are the same.

* This also helped fix a bug with the Innotek G300 emulation that was already in MAME, including masking problems with DMA translation and a race condition within multithreading critical sections of the MCT-ADR DMA chip emulation.

* There is currently a hack in the PS/2 emulation to disable interrupts for a brief period of time after self reset. The keyboard controller firmware, which is emulated at a low level, appears to be different between IBM machines and Jazz boards, and this build will not work without that behavior. The Jazz firmware is currently undumped.

* MAME currently seems to have trouble syncing at 19200 baud for some reason-- that looks to be a bug within MAME, so the UART emulation is forced to run at 9600 baud and the debugger was patched.

* The CPU frequency had to be lowered from 50 to 25 MHz. Write buffering also needs to be disabled for branch conditionals and there's a hack in the address translation to disable a caching conditional.

* An interrupt in the I82357 EISA controller had to be disabled.

there's also a problem with the SCSI controller - for whatever reason, for me, the kernel times out waiting for an interrupt from it and enters a reset loop, trying to reset the controller, then wondering what the hell the state that the controller reports means.

but still, those problem can be raised in MAME or even providing them a fix, just like @Wack0 created some PRs to fix dolphin emulator when he was porting NT4 PPC to Wii.
https://github.com/dolphin-emu/dolphin/pulls?q=is%3Apr+author%3AWack0

@HBelusca
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I noticed that mipskd sends: boot -f mop(1)/ntoskrnl.exe over serial, first thing after you run it; probably as a command over serial to some ancient firmware. Do you recall anything about what mop(1) means here, or what the debugger might be waiting for?

This smells like something from pre-v1.2 ARC firmware specification.

@iProgramMC
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you remember what toolchain was used to compile this? I assume some kind of Microsoft C for MIPS, but it wouldn't surprise me if you used a different one. Was there ever a publicly released Microsoft C compiler for MIPS R3000?

Please sign in to comment.