<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<blockquote
cite="mid:15f23015-a46d-48e8-9d65-***@z11g2000yqz.googlegroups.com"
type="cite">
<blockquote
cite="mid:***@J.de.Boyne.Pollard.localhost"
type="cite">
<blockquote
cite="mid:328bf1bd-eeec-41eb-b1b8-***@k36g2000yqn.googlegroups.com"
type="cite">
<p>NTVDM is such a weird animal. But it's much faster than full
emulation.</p>
</blockquote>
<p>Not really. NTVDM is fairly run of the mill when it comes to
Virtual DOS Machines that make use of v8086 mode. They all have a
"bop" mechanism of one sort or another. OS/2 VDMs (and VMBs) use the <code>HLT</code>
instruction to trap into the VDM manager, for example.</p>
</blockquote>
<p wrap="">I meant that using v86 mode (via NTVDM) is clearly much
faster than full emulation like QEMU or DOSBox.<br>
</p>
</blockquote>
<p>It's still not really a "weird animal", for the reasons already
explained.</p>
<blockquote
cite="mid:15f23015-a46d-48e8-9d65-***@z11g2000yqz.googlegroups.com"
type="cite">
<blockquote
cite="mid:***@J.de.Boyne.Pollard.localhost"
type="cite">
<p>The "paravirtualized" <code>COMMAND</code> in Windows NT won't
run
(unless it is carefully coded with alternative code paths, which I
highly doubt, given that there's no need to make the thing capable of
running outside of NTVDM) outside of the VDM that it is
"paravirtualized" for. Just as <code>DOSKRNL</code> in OS/2 won't run
as a standalone DOS operating system.</p>
</blockquote>
<p wrap="">I'm pretty sure XP on up still allow you to make a
bootable MS-DOS floppy. I think that the above-mentioned <code>COMMAND.COM</code>
is the one it uses. If you have proof otherwise, I'd be glad to hear
it. (And yes, 4DOS is superior, so there, back on topic, heh.)</p>
</blockquote>
<p>Proof is easy and obvious, and right in front of one's nose. Use
the <code>VER</code> command. The <code>COMMAND</code> in Windows NT
5 says:</p>
<blockquote type="cite">
<p>MS-DOS Version 5.00.500</p>
</blockquote>
<p>Do you see any mention of the string that you get from the
DOS-Windows ME <code>COMMAND</code> on such a floppy disc ("<a
href="
Loading Image...
">Windows Millennium
[Version 4.90.3000]</a>")? No, you don't. And the reason is the
obvious one: The <code>COMMAND</code> that is put onto a bootable
floppy disc is not the ("paravirtualized") Windows NT <code>COMMAND</code>.
The Windows NT <code>COMMAND</code> program image file doesn't even
contain such a version string. What's on the floppy disc is a <em>different
command interpreter</em>.<br>
</p>
<p>One can figure this out <em>simply by looking at the files</em> on
such a boot disc (which you can do <a
href="http://theeldergeek.com./create_ms-dos_startup_disk.htm">even
without expending the effort of making such a disc</a>). There are
files there that don't exist in a Windows NT 6 installation proper,
such as <code>KEYB.COM</code>. Clearly the format utility is
unpacking a dedicated set of files from an archive somewhere, not
copying across the files that Windows NT itself uses.<br>
</p>
<blockquote
cite="mid:15f23015-a46d-48e8-9d65-***@z11g2000yqz.googlegroups.com"
type="cite">
<p wrap=""></p>
<blockquote
cite="mid:***@J.de.Boyne.Pollard.localhost"
type="cite">
<p>I recently came across Thomas
R. Nicely's WWW page on Windows Vista's DPMI server. It's pretty
confused. (<a moz-do-not-send="true"
href="http://justlinux.com./forum/showthread.php?p=866737">These people</a>
have some quite sensible things to say on the matter of M. Nicely's
page.) And no wonder that it is, if this was how you explained things
to M. Nicely, as xe claims you did. (-:</p>
</blockquote>
<p>Those paltry comments from two misinformed Linux users are hardly
fair game, not even close.</p>
</blockquote>
<p>On the contrary, the people in that discussion thread are well
informed, and M. Nicely is not.</p>
<blockquote
cite="mid:15f23015-a46d-48e8-9d65-***@z11g2000yqz.googlegroups.com"
type="cite">
<blockquote
cite="mid:***@J.de.Boyne.Pollard.localhost"
type="cite">
<p>This
<code>DpmiLimit</code> setting that you mentioned is in fact
nothing
new. It's simply <em>undocumented</em> on Windows NT 6. OS/2 VDM's
have had a <em>documented</em> DPMI memory limit setting for almost
two decades. The setting is <code>DPMI_MEMORY_LIMIT</code>. You can
read on Usenet and the WWW hundreds of discussions of this, going back
to about 1994, and the reasons for tweaking it up and down. On an OS/2
system one can open up a VDM settings notebook, and obtain on-line help
describing the setting. </p>
</blockquote>
<p wrap="">No, it's definitely new. While everything wasn't perfect
in XP, it was somewhat acceptable. When Vista came around, no DOS gfx
support and a hardcoded 32 MB DPMI limit with no workaround made things
much worse.<br>
</p>
</blockquote>
<p>That's nonsense. Of course it has a workaround. It's the one
that's just been mentioned. "Undocumented" is not the same as "not
present". And of course it is not new. As just explained, OS/2
VDMs/VMBs have had such a setting for almost twenty years. DOS-Windows
9x had a <span class="Apple-style-span"
style="border-collapse: separate; color: rgb(0, 0, 0); font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; font-size: medium;"><span
class="Apple-style-span" style="font-family: monospace;">"<a
href="http://technet.microsoft.com/en-us/library/cc751101.aspx#XSLTsection127121120120">MS-DOS
Protected Mode (DPMI) Memory</a>"</span></span> setting for setting a
cap on DPMI memory, which defaulted to 16MiB. This limit is nothing
new at all. It's par for the course and run-of-the-mill. NTVDM isn't
"weird" or unusual or new here. It's doing exactly what other VDMs
have been doing for years.<br>
</p>
<blockquote
cite="mid:15f23015-a46d-48e8-9d65-***@z11g2000yqz.googlegroups.com"
type="cite">
<p wrap=""></p>
<blockquote
cite="mid:***@J.de.Boyne.Pollard.localhost"
type="cite">
<p>Raymond
Chen singles out DOS games as some of the particular offenders when it
comes to abusing DPMI, and <a moz-do-not-send="true"
href="http://faqs.org./faqs/os2-faq/dos-games/">there's a whole FAQ
for running DOS games under OS/2</a> that lists the various different <code>DPMI_MEMORY_LIMIT</code>
(and other) settings for getting such games to play nicely with the
operating system and not chew up memory unnecessarily, just because the
DPMI server in the VDM would otherwuse allow them to.</p>
</blockquote>
<p wrap="">There are a few buggy extenders, but some work okay.
However, Windows' own DPMI (0.9 only) is far from perfect, and the
Quake guys (even with CWS helping) had a hard time getting it to work
due to bugs. MS even refused to fix certain bugs in NT, so it never ran
there (at least, not as a DOS app).<br>
<br>
I have no problems with limits. It's just when they are insanely low or
arbitrarily set without workaround. I can't help but point out that 32
MB is barely 3% of 1 GB of RAM (which this laptop has). Why am I
restricted to 3%? If you think most DOS apps are buggier than Win32
apps by default, you're wrong.<br>
</p>
</blockquote>
<p>If you think that Win32 applications by default <em>go and allocate
all memory present in the system</em>, which is one of the bad
behaviours exhibited by extended DOS applications that this limit is
designed to ameliorate, then it is you that is wrong. And you're
restricted to 32MiB <em>only</em> if you don't explicitly do something
about it, just like OS/2 users are restricted to 64MiB (if memory
serves) only unless they do something about it. <br>
</p>
<p>You seem not to have realized, too, that this is a limit per NTVDM
instance, not a system-wide limit across all virtual DOS machines. The
idea that there's some system-wide restriction that means that you'll
only ever use 3% of your RAM is nonsense. Morever: Would you prefer
that every such buggy extended DOS application that you run consume
100% of available DPMI memory, with no cap at all on the virtual memory
providable by the DPMI server? That would be 2GiB consumed for every
such program run. Your virtual memory usage would exceed your laptop's
physical memory after running <em>one</em> such buggy pogram. <br>
</p>
<p>Every non-standalone DPMI host has this limit. OS/2 VDMs/VMBs do.
DOS-Windows 9x does. NTVDM does. It's there to protect the system
from runaway buggy extended DOS applications. The problem here really
is nothing more than that you're not used to having to
do this. DOS-Windows 9x users are. They know about the <span
class="Apple-style-span"
style="border-collapse: separate; color: rgb(0, 0, 0); font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; font-size: medium;"><span
class="Apple-style-span" style="font-family: monospace;">"<a
href="http://technet.microsoft.com/en-us/library/cc751101.aspx#XSLTsection127121120120">MS-DOS
Protected Mode (DPMI) Memory</a>"</span></span> setting. OS/2 users
are. They have <a href="http://faqs.org./faqs/os2-faq/dos-games/">a
whole FAQ</a>
devoted to tweaking these settings, as well as an application migration
database that is supplied with the operating system itself (<code>%_BOOT%:\OS2\INSTALL\DATABASE.DAT</code>)
that supplies the individualized VDM settings tweaks out of the box for
DOS applications that IBM/Microsoft knew about.<br>
</p>
<p>This is not weird and novel and scary, nor is it some sort of
mysterious conspiracy by Microsoft to prevent you from running gcc.
It's old hat and humdrum, and something that's been around so long that
people have actually <em>forgotten</em> about these things. <br>
</p>
<blockquote
cite="mid:15f23015-a46d-48e8-9d65-***@z11g2000yqz.googlegroups.com"
type="cite">
<blockquote
cite="mid:***@J.de.Boyne.Pollard.localhost"
type="cite">
<p>Again,
NTVDM isn't being "weird", at all. It's implementing a setting, and a
limit, that is par for the course in Virtual DOS Machines. Even the
default of 32MiB isn't unusual. The default for <code>DPMI_MEMORY_LIMIT</code>
in OS/2 VDMs was (in recent versions of OS/2, if memory serves) 64MiB.
If you read Raymond Chen's article all of the way to the end, there's
even an explanation of <em>why</em> such values are the defaults: It's
to cope with the <em>broken extended DOS programs</em> that measure
available DPMI memory in KiB using 16-bit integers. (NTVDM's default
assumes signed 16-bit integers. OS/2's VDM default assumes unsigned
16-bit integers.)</p>
</blockquote>
<p wrap="">The limit was not present in XP and its NTVDM. Besides,
GCC (esp. 4.x series) needs a fair bit of RAM, e.g. compiling C++ with
optimizations (e.g. Dungeon Crawl: Stone Soup). I clocked "gpp -O2" as
using over 120 MB at one point recently.</p>
<p>No, it's because Windows is transitioning. They barely (if at
all) test DOS apps, a "bug" (or mistake) crept it with Server 2003,
and nobody removed it. The registry workaround didn't even exist until
Vista SP1. With AMD64 not having v86 mode, they have the perfect excuse
to dump all 16-bit support. So I expect Windows 8 to not support
anything besides 64-bit. (PAE must not be viable to them.) :-(</p>
</blockquote>
<p>That's entirely backwards. The limit clearly exists to ameliorate a
problem that would have previously allowed runaway extended DOS
programs to gobble vast amounts of virtual memory. That's in part what
it's there for in OS/2 and DOS-Windows 9x, after all. This is clearly
something that is there to <em>fix</em> NTVDM problems. As such, it
gives lie to your idea that Microsoft is ignoring DOS applications.
(Microsoft expends a fair amount of effort in maintaining compatibility
with old applications, more indeed than other people would have it
spend. <a
href="http://blogs.msdn.com/oldnewthing/archive/2004/03/01/82103.aspx">Just
ask Raymond Chen</a>.) After all, if it were ignoring DOS
applications, it <em>wouldn't have changed NTVDM</em> so that buggy
extended DOS applications have reduced impact upon the system.</p>
<blockquote
cite="mid:15f23015-a46d-48e8-9d65-***@z11g2000yqz.googlegroups.com"
type="cite">
<blockquote
cite="mid:***@J.de.Boyne.Pollard.localhost"
type="cite">
<p>All
of these things — be they traps into the VM monitor from inside
the VDM, or DPMI server limits to control badly written DOS programs
— aren't
NTVDM being "weird" or unusual, or secret conspiracies by Microsoft
against people who think that compiling with gcc means that one is
compiling extended DOS programs. They're simple long-standing practice
for VDMs, and run-of-the-mill stuff for virtual machine technology that
goes back for decades.</p>
</blockquote>
<p wrap="">If it were configurable from the start, I'd agree.
However, Server 2003 is receiving no more service packs from MS, and it
<em>still</em> has the hardcoded (untweakable) DPMI limit. Even Vista
didn't get the fix until SP1, and yes, it was undocumented, so I had to
kinda nag one guy just to look it up for me. I even tested my brother's
Win7 laptop, and it's still broken by default (32 MB only), which is
ridiculous. Who the heck wants to have to edit the registry just to
make simple apps work? (Who knew that 16-bit was a dirty word?)<br>
</p>
</blockquote>
<p>Not configurable from the start?! It has been configurable, across
a range of VDMs, for <em>almost twenty years</em>. <span
class="Apple-style-span"
style="border-collapse: separate; color: rgb(0, 0, 0); font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; font-size: medium;"><span
class="Apple-style-span" style="font-family: monospace;"></span></span>
As stated earlier, the problem here is that you're simply not used to
having to tweak VDM DPMI settings differently for different DOS
applications, according to their bugs and idiosyncrasies. OS/2 users
are, and DOS-Windows 9x users are. Welcome to the reality of DOS
applications in VDMs. You've almost finally caught up with the
mid-1990s. (-:<br>
</p>
<p><span class="Apple-style-span"
style="border-collapse: separate; color: rgb(0, 0, 0); font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; font-size: medium;"><span
class="Apple-style-span" style="font-family: monospace;"></span></span></p>
</body>
</html>