Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Discuss MS-DOS, Windows 1, 2 and 3.
Post Reply
roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

We know last working version is Windows 3.0, and we know Real Mode is still available until Build 43e, but do Build 26 and Build 34e Real Mode work on real 8086/8088?

Fanta Shokata
User avatar
Posts: 323
Joined: Sat Oct 10, 2020 12:48 pm
Location: Tricity, Poland

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by Fanta Shokata »

I think it will work, but I'm not 100% sure about that.
We stand with Ukraine

astrohound
User avatar
Posts: 44
Joined: Wed Aug 25, 2021 9:09 pm
Location: SE Europe

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by astrohound »

Windows 3.1.026 does install (and works) in RM.
Image

I also tried 027 and 34f but the installers didn't work.

roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

astrohound wrote:
Fri May 13, 2022 11:49 pm
Windows 3.1.026 does install (and works) in RM.
Image

I also tried 027 and 34f but the installers didn't work.
I'm not talking about Real Mode kernel.exe running on something newer than 8086/8088, but Real Mode kernel.exe running on real or precisely emulated 8086/8088.

astrohound
User avatar
Posts: 44
Joined: Wed Aug 25, 2021 9:09 pm
Location: SE Europe

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by astrohound »

roytam1 wrote:
Sat May 14, 2022 10:05 am
Real Mode kernel.exe running on real or precisely emulated 8086/8088.
That was a real mode kernel running under 80186 emulation. About precision... I can't guarantee it's precise. DOSBox-X is hit and miss sometimes. Although it's often much more reliable for this than DOSBox.

astrohound
User avatar
Posts: 44
Joined: Wed Aug 25, 2021 9:09 pm
Location: SE Europe

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by astrohound »

And this is on the real machine (again 80186):
Image

roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

astrohound wrote:
Sat May 14, 2022 2:17 pm
And this is on the real machine (again 80186):
Image
thats great, but 80186 is NOT 8086/8088.

quote from wikipedia:

A few new instructions were introduced with the 80186 (referred to as the 8086-2 instruction set in some datasheets): enter/leave (replacing several instructions when handling stack frames), pusha/popa (push/pop all general registers), bound (check array index against bounds), and ins/outs (input/output of string). A useful immediate mode was added for the push, imul, and multi-bit shift instructions. These instructions were also included in the contemporary 80286 and in successor chips. (The instruction set of the 80286 is superset of the 80186's, plus new instructions for protected mode.)

astrohound
User avatar
Posts: 44
Joined: Wed Aug 25, 2021 9:09 pm
Location: SE Europe

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by astrohound »

So? Windows 3.x in real mode doesn't use 80186 instructions. So, the only practical difference is the speed, which is a twice faster. So, if it works on 80186, it will work on 8086 too, just slower.

But ok. No need for snark, just ignore my answer and wait for someone else with 8088/8086 to answer.

Lucas Brooks
Posts: 773
Joined: Sat Oct 20, 2018 11:37 am
Contact:

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by Lucas Brooks »

There are emulators out there :^), FYI.

winnt32
Permanently Banned
Posts: 158
Joined: Thu Mar 02, 2017 2:40 pm

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by winnt32 »

not sure if this is a question that needs to be asked. if it didn't work it would be rather useless

roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

winnt32 wrote:
Sun May 15, 2022 4:06 pm
not sure if this is a question that needs to be asked. if it didn't work it would be rather useless
maybe thats why MS removed it in Build 43e.

Fanta Shokata
User avatar
Posts: 323
Joined: Sat Oct 10, 2020 12:48 pm
Location: Tricity, Poland

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by Fanta Shokata »

roytam1 wrote:
Mon May 16, 2022 2:00 am
winnt32 wrote:
Sun May 15, 2022 4:06 pm
not sure if this is a question that needs to be asked. if it didn't work it would be rather useless
maybe thats why MS removed it in Build 43e.
Real Mode was removed from that build mostly because it was intended for compatibility with Windows 1.x/2.x applications, and that 8086/8088 processors were now aged at that time.
We stand with Ukraine

vbdasc
Posts: 350
Joined: Fri Apr 30, 2010 6:14 pm

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by vbdasc »

Lucas Brooks wrote:
Sun May 15, 2022 6:38 am
There are emulators out there :^), FYI.
Yes, indeed. I just looked at the source code of PCE, and can say that when the CPU type in this emulator is set to 8088 or 8086, the 80186 new instructions are disabled. And PCE is known as a very accurate emulator, so if this beta works on PCE with CPU set to 8088, then it's 99+ percent certain that it also worked on real 8088 PC.

roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

vbdasc wrote:
Tue May 17, 2022 12:01 pm
Lucas Brooks wrote:
Sun May 15, 2022 6:38 am
There are emulators out there :^), FYI.
Yes, indeed. I just looked at the source code of PCE, and can say that when the CPU type in this emulator is set to 8088 or 8086, the 80186 new instructions are disabled. And PCE is known as a very accurate emulator, so if this beta works on PCE with CPU set to 8088, then it's 99+ percent certain that it also worked on real 8088 PC.
yeah so my guess is correct:
Image

vbdasc
Posts: 350
Joined: Fri Apr 30, 2010 6:14 pm

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by vbdasc »

So, does it work? What is that DOS prompt in the upper left corner of the screen?

roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

vbdasc wrote:
Tue May 17, 2022 4:40 pm
So, does it work? What is that DOS prompt in the upper left corner of the screen?
it hits undefined instructions and back to DOS without changing back screen.

vbdasc
Posts: 350
Joined: Fri Apr 30, 2010 6:14 pm

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by vbdasc »

Hmmm... interesting. It seems this version of Windows uses instructions such as "PUSH imm8", "PUSH imm16" and "SAL reg/mem, imm8", which are present in 80186/80188 and later, but not in 8086/8088. And due to 80186/80188 CPUs being generally rare in PCs, this means that Windows 3.1 real mode effectively requires... 80286. Weird and unexpected, as far I'm concerned. Still, real mode could be useful for running Windows 1.x/2.x software, but this benefit is only marginal. No wonder that final Windows 3.1 dropped real mode, then.

Even more weird, it seems that there is a bug in PCE. Judging by its (latest) source code, it doesn't seem to support the instruction "SAL reg/mem, imm8" at all, even if the CPU is set to "80186", probably due to reading Intel's buggy 80186/80286 manuals too literally.

P.S. To prove that there is indeed a bug in PCE, could you try again running this Windows with CPU set to "80186"? It should crash again due to unknown instruction, but this time, only "C0 74" a.k.a. SAL should show up in the log.

xelloss
User avatar
Donator
Posts: 400
Joined: Sun Aug 18, 2013 7:26 pm
Location: Edinburgh, Scotland

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by xelloss »

roytam1 wrote:
Tue May 17, 2022 5:27 pm
it hits undefined instructions and back to DOS without changing back screen.
Huh. One has to wonder why they compiled their code with 80186 instructions enabled.
I guess that while Windows had different kernels for real mode, 286, and 386+ machines, the rest of the code was shared, so keeping real mode compatible with 8088/8086 machines meant that ALL the other modules (starting with GDI and USER -- which is probably where this version fails -- but also including all drivers, libraries and programs) had to target the 8086. Maybe they didn't want to bother with that any more.

roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

xelloss wrote:
Sat May 21, 2022 9:49 am
roytam1 wrote:
Tue May 17, 2022 5:27 pm
it hits undefined instructions and back to DOS without changing back screen.
Huh. One has to wonder why they compiled their code with 80186 instructions enabled.
I guess that while Windows had different kernels for real mode, 286, and 386+ machines, the rest of the code was shared, so keeping real mode compatible with 8088/8086 machines meant that ALL the other modules (starting with GDI and USER -- which is probably where this version fails -- but also including all drivers, libraries and programs) had to target the 8086. Maybe they didn't want to bother with that any more.
winfile from build 26 works on 8086/8088, and later winmine from 43e doesn't.
so they started to use 80186 instructions everywhere in later builds.

Battler
User avatar
Donator
Posts: 2117
Joined: Sat Aug 19, 2006 8:13 am
Location: Slovenia, Central Europe.
Contact:

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by Battler »

You guys could have simply tried it on 86Box's 808x emulation which is currently among the most precise there is, based on reenigne's xtce which is in turn based on reenigne's extensive probing of the real hardware. And I can assure you, any 186+ instructions are disabled when emulating the 808x on 86Box - they have to, anyway, because otherwise, some of them would conflict with undocumented instruction aliases that we do emulate.
Main developer of the 86Box emulator.
Join the 86Box Discord server, a nice community for true enthusiasts and 86Box supports!

The anime channel is on the Ring of Lightning Discord server.

Check out our SoftHistory Forum for quality discussion about older software.

roytam1
Posts: 735
Joined: Mon Nov 03, 2008 6:15 am

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by roytam1 »

Battler wrote:
Fri Jun 03, 2022 5:26 pm
You guys could have simply tried it on 86Box's 808x emulation which is currently among the most precise there is, based on reenigne's xtce which is in turn based on reenigne's extensive probing of the real hardware. And I can assure you, any 186+ instructions are disabled when emulating the 808x on 86Box - they have to, anyway, because otherwise, some of them would conflict with undocumented instruction aliases that we do emulate.
but I wonder if there is an option to enable 80186 instructions in 86box 8086/8088 emulation?

kzez1986
Posts: 1
Joined: Wed Mar 22, 2023 9:28 pm

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by kzez1986 »

I accidentally found Windows 3.1.034f running in real mode on 8088 cpu: https://www.youtube.com/watch?v=9PNyXFdrlkw

xelloss
User avatar
Donator
Posts: 400
Joined: Sun Aug 18, 2013 7:26 pm
Location: Edinburgh, Scotland

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by xelloss »

kzez1986 wrote:
Wed Mar 22, 2023 9:31 pm
I accidentally found Windows 3.1.034f running in real mode on 8088 cpu: https://www.youtube.com/watch?v=9PNyXFdrlkw
Not sure what machine that is, but the processor appears to be a NEC V20, which seems to understand the new 80186 instructions.

Cigaryno
Posts: 20
Joined: Sun Jul 30, 2023 1:18 pm

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by Cigaryno »

The final build of Windows 3.1 to support the 8088/8086 real mode is 034f. This build and earlier should work fine in real mode.
Last edited by Cigaryno on Sun Aug 06, 2023 5:24 pm, edited 1 time in total.

vbdasc
Posts: 350
Joined: Fri Apr 30, 2010 6:14 pm

Re: Does Windows 3.1 Beta Real Mode work on real 8086/8088?

Post by vbdasc »

Cigaryno wrote:
Sun Aug 06, 2023 5:20 pm
The final build of Windows 3.1 to support the 8088/8086 real mode is 034f. This build and earlier should work fine in real mode.
Of course, but the question was if these betas worked on 8086/8088 CPUs. Note that support for 8086/8088 and support for real mode are two different things. Former implies latter, but not vice versa, as demonstrated by this thread.

Post Reply