Most of us are aware that IBM’s OS/2 has excellent compatibility with DOS and Windows 3.x programs, to the point where OS/2 just ships with an entire installation of Windows 3.x built-in that you can run multiple instances of. In fact, to this day, ArcaOS, the current incarnation of the maintained and slightly modernised OS/2 codebase, still comes with an entire copy of Windows 3.x, making ArcaOS one of the very best ways to run DOS and Windows 3.x programs on a modern machine, without resorting to VMware or VirtualBox.
Peter Hofmann took a look at one of the earlier versions of OS/2 – version 2.1 from 1993 – to see how its DOS compatibility actually works, or more specifically, the feature “DOS from drive A:”.
You can insert a bootable DOS floppy and then run that DOS in a new window.
Since this is called “DOS from drive A:”, surely this is something DOS-specific, right? Maybe only supports MS-DOS or even only PC DOS?
Far from it, apparently.
↫ Peter Hofmann
Hofmann wrote a little test program using nothing but BIOS system calls, meaning it doesn’t use any DOS system calls. This “real mode BIOS program” can run from the bootsector, if you wanted to, so after combining his test program with a floppy disk boot record, you end up with a bootable floppy that runs the test program, for instance in QEMU. After a bit of work, the test program on the bootable floppy will work just fine using OS/2’s “DOS from drive A:” feature, even though it shouldn’t.
What this seems to imply is that this functionality in OS/2 2.1 looks a lot like a hypervisor, or as Hofmann puts it, “basically a builtin QEMU that anybody with a 386 could use”. That’s pretty advanced for the time, and raises a whole bunch of questions about just how much you can do with this.