An empirical comparison of candidate DOS kernels (98SE, ME, FreeDOS)

Last modified: 2023-05-28 08:44

Scope of comparison

Only the kernel and the default COMMAND.COM were examined, and only as far as could be determined from processing a typical CONFIG.SYS and AUTOEXEC.BAT configuration followed by Universal Standard Protected Mode Operability Test D [1].  A broad evaluation of the effects of the different candidates on the operability and stability of popular applications was not done.

Control variables

Each candidate was installed onto the same hard disk partition on the same PC with the same BIOS setup, with either FORMAT /S C: or FORMAT C: followed by SYS C: from a prepared boot floppy.

The following driver versions were loaded where applicable:

The following MSDOS.SYS file was installed: [2]

[Options]
SystemReg=0
DisableLog=1
Logo=0

Unwanted drivers that MS-DOS might autoload were purged from the disk.  (C.f. The Windows 98 Config.txt file about DOS=AUTO and Contents of the Windows Msdos.sys File about DBLSpace and DRVSpace.)

Independent variables

Kernel and shell versions

Windows 98 SE *Windows ME **FreeDOS
alias MS-DOS 7.1alias MS-DOS 8.0is free
Windows 98 [Version 4.10.2222]
Revision A
DOS is in HMA
Windows Millennium [Version 4.90.3000]
Revision A
DOS is in HMA
FreeCom version 0.84-pre2 XMS_Swap [Aug 28 2006 00:29:00]
DOS version 7.10
FreeDOS kernel 2041 (build 2041 OEM:0xfd) [compiled Feb  7 2012]
222390  1999-04-23 22:22  IO.SYS116736  2005-04-18 17:54  IO.SYS45494  2012-02-07 13:52  KERNEL.SYS

* Patch KB311561 (MS-DOS Does Not Properly Process Hard Disk Hardware Errors) was not applied.  The patched kernel issues the same version string, but its size and date are [222670  2001-12-01 08:37  IO.SYS].

** Unsupported mod based on a boot floppy version of the kernel [3].  Before modding, the binary was different from the one included in KB311561, had the same size but was dated later.  ???

Config files

For each candidate, a baseline CONFIG.SYS and AUTOEXEC.BAT were tweaked as needed to achieve the following to the extent reasonable:

  1. Relocate the EBDA [4].
  2. Enable XMS and hardware UMBs.
  3. Load all overhead and drivers in the UMA or HMA.
  4. Specify desired (generous) limits for DOS resources.
  5. Enable basic idle power management.
  6. Load UIDE.SYS, SHSUCDX.COM, DOSLFNMS.COM, RDISK.COM, and CTMOUSE.EXE.

Extraneous details have been omitted for brevity.

CONFIG.SYS

Windows 98 SEWindows MEFreeDOS
DEVICE=C:\LOCAL\UMBPCI\UMBPCI.SYS
DEVICE=C:\LOCAL\UIDE\XMGR.SYS /W
DEVICEHIGH=C:\LOCAL\UIDE\UIDE.SYS /S1024 /H
DOS=HIGH,UMB,AUTO
SHELL=C:\COMMAND.COM C:\ /E:2048 /P
BUFFERSHIGH=30
FCBSHIGH=4
FILESHIGH=40
STACKSHIGH=9,256
LASTDRIVEHIGH=E
DEVICE=C:\LOCAL\JEMM\MOVEXBDA.EXE
DEVICE=C:\LOCAL\UMBPCI\UMBPCI.SYS
DEVICEHIGH=C:\LOCAL\UIDE\UIDE.SYS /S1024 /H
DOS=HIGH,UMB,AUTO
SHELL=C:\COMMAND.COM C:\ /E:2048 /P
BUFFERSHIGH=30
FCBSHIGH=4
FILESHIGH=40
STACKSHIGH=9,256
LASTDRIVEHIGH=E
DEVICE=C:\LOCAL\UMBPCI\UMBPCI.SYS
DEVICE=C:\LOCAL\UIDE\XMGR.SYS /W
DEVICEHIGH=C:\LOCAL\UIDE\UIDE.SYS /S1024 /H
DOS=HIGH,UMB
SHELLHIGH=C:\COMMAND.COM C:\ /E:2048 /P
BUFFERSHIGH=30
FILESHIGH=40
STACKSHIGH=9,256
LASTDRIVEHIGH=E
IDLEHALT=1
SWITCHES=/E:1024
Basis for comparison.
The EBDA is relocated by default.
DOS=AUTO is needed to move DRIVEDATA to the UMA.
Microsoft's XMM is integral to the kernel and is always loaded, even with DOS=NOAUTO.
SWITCHES=/E:1024 has no effect.
MOVEXBDA fails silently if it is loaded high.
DOS=AUTO is needed to move DRIVEDATA to the UMA.
DOS=[NO]AUTO is unsupported.
SHELLHIGH is added.
FCBSHIGH is unsupported because FCBs are emulated from file handles (FILES).
IDLEHALT is FreeDOS-specific.

AUTOEXEC.BAT

Windows 98 SEWindows MEFreeDOS
LH C:\LOCAL\BIN\FDAPM.COM APMDOS
LH C:\LOCAL\BIN\SHSUCDX.COM /C /D:UDVD1
LH C:\LOCAL\DOSLFN\DOSLFNMS.COM
LH C:\LOCAL\UIDE\RDISK.COM /S1024 /:E
LH C:\LOCAL\BIN\CTMOUSE.EXE
LH C:\LOCAL\BIN\FDAPM.COM APMDOS
LH C:\LOCAL\BIN\SHSUCDX.COM /C /D:UDVD1
LH C:\LOCAL\DOSLFN\DOSLFNMS.COM
LH C:\LOCAL\UIDE\RDISK.COM /S1024 /:E
LH C:\LOCAL\BIN\CTMOUSE.EXE
LH C:\LOCAL\BIN\SHSUCDX.COM /C /D:UDVD1
LH C:\LOCAL\DOSLFN\DOSLFNMS.COM
LH C:\LOCAL\UIDE\RDISK.COM /S1024 /:E
LH C:\LOCAL\BIN\CTMOUSE.EXE
Basis for comparison.No change. FDAPM.COM is unnecessary.

Differences in memory use

Output from MEM (v1.11) /DEBUG /A:

Windows 98 SEWindows MEFreeDOS
Conventional Memory Detail:

Segment        Total           Name           Type
-------  ----------------  ------------  -------------
  0000      1,024    (1K)                interrupt vector table
  0040        768    (1K)                BIOS data area
  0070      6,544    (6K)  IO            system data
                             NUL         system device driver
                             CON         system device driver
                             AUX         system device driver
                             PRN         system device driver
                             CLOCK$      system device driver
                             A: - C:     system device driver
                             COM1        system device driver
                             LPT1        system device driver
                             LPT2        system device driver
                             LPT3        system device driver
                             CONFIG$     system device driver
                             COM2        system device driver
                             COM3        system device driver
                             COM4        system device driver
  0209      2,128    (2K)  DOS           system data
  020b      1,024    (1K)    EBDA        data area
  024c        544    (1K)    SECTORBUF    data area
  026f        512    (1K)    BUFFERS     BUFFERS=30,0
  028f         64    (0K)  DOS           system code
  0294         80    (0K)  COMMAND       data area
  029a        240    (0K)  MEM           environment
  02aa     55,248   (54K)  MEM           program
  1028    589,152  (575K)                free

Upper Memory Detail:

Segment        Total           Name           Type
-------  ----------------  ------------  -------------
  a000    199,280  (195K)                reserved
  d0a7     23,424   (23K)  DOS           system data
  d0a9        912    (1K)    UIDE        device driver
                               UDVD1     installed DEVICE=UIDE    
  d0e3        464    (0K)    DRIVEDATA    data area
  d101      2,080    (2K)    FILES       FILES=40 (35 in this block)
  d184        256    (0K)    FCBS        data area
  d195     16,080   (16K)    BUFFERS     BUFFERS=30,0
  d583        448    (0K)    LASTDRV     LASTDRIVE=E
  d5a0      3,072    (3K)    STACKS      STACKS=9,256
  d660      5,712    (6K)  COMMAND       program
  d7c6         64    (0K)                free
  d7cb      3,088    (3K)  COMMAND       environment
  d88d        192    (0K)                free
  d89a        912    (1K)  FDAPM         program
  d8d4      6,208    (6K)  SHSUCDX       program
  da59     11,648   (11K)  DOSLFNMS      program
  dd32        752    (1K)  RDISK         program
                             E:          installed DEVICE=RDISK
  dd62      3,088    (3K)  CTMOUSE       program
  de24      7,600    (7K)                free

Memory Type         Total      Used       Free
----------------  --------   --------   --------
Conventional          640K        11K       629K
Upper                  61K        53K         8K
Reserved              323K       323K         0K
Extended (XMS)   3,467,520K 2,097,941K 1,369,579K
----------------  --------   --------   --------
Total memory     3,468,544K 2,098,328K 1,370,216K

Total under 1 MB      701K        64K       637K

Memory accessible using Int 15h         0K (      0 bytes)
Largest executable program size       629K (644,416 bytes)
Largest free upper memory block         7K (  7,616 bytes)
Available space in High Memory Area     6K (  6,128 bytes)
Windows is resident in the high memory area.
Conventional Memory Detail:

Segment        Total           Name           Type
-------  ----------------  ------------  -------------
  0000      1,024    (1K)                interrupt vector table
  0040        768    (1K)                BIOS data area
  0070     10,512   (10K)  IO            system data
                             NUL         system device driver
                             CON         system device driver
                             AUX         system device driver
                             PRN         system device driver
                             CLOCK$      system device driver
                             A: - C:     system device driver
                             COM1        system device driver
                             LPT1        system device driver
                             LPT2        system device driver
                             LPT3        system device driver
                             COM2        system device driver
                             COM3        system device driver
                             COM4        system device driver
                             XMSXXXX0    system device driver
  0301      2,416    (2K)  DOS           system data
  0303      1,136    (1K)    MOVEXBDA    device driver
                               MOVXBDA#  installed DEVICE=MOVEXBDA
  034b        160    (0K)    UMBPCI      device driver
                               UMBPCIXX  installed DEVICE=UMBPCI  
  0356        544    (1K)    SECTORBUF    data area
  0379        512    (1K)    BUFFERS     BUFFERS=30,0
  0399         64    (0K)  DOS           system code
  039e         80    (0K)  COMMAND       data area
  03a4        256    (0K)  MEM           environment
  03b5     55,248   (54K)  MEM           program
  1133    584,880  (571K)                free

Upper Memory Detail:

Segment        Total           Name           Type
-------  ----------------  ------------  -------------
  a000    196,608  (192K)                reserved
  d000     23,424   (23K)  DOS           system data
  d002        912    (1K)    UIDE        device driver
                               UDVD1     installed DEVICE=UIDE    
  d03c        464    (0K)    DRIVEDATA    data area
  d05a      2,080    (2K)    FILES       FILES=40 (35 in this block)
  d0dd        256    (0K)    FCBS        data area
  d0ee     16,080   (16K)    BUFFERS     BUFFERS=30,0
  d4dc        448    (0K)    LASTDRV     LASTDRIVE=E
  d4f9      3,072    (3K)    STACKS      STACKS=9,256
  d5b9      5,584    (5K)  COMMAND       program
  d717         64    (0K)                free
  d71c      3,088    (3K)  COMMAND       environment
  d7de        192    (0K)                free
  d7eb        912    (1K)  FDAPM         program
  d825        208    (0K)                free
  d833      6,208    (6K)  SHSUCDX       program
  d9b8     11,648   (11K)  DOSLFNMS      program
  dc91        752    (1K)  RDISK         program
                             E:          installed DEVICE=RDISK
  dcc1      3,088    (3K)  CTMOUSE       program
  dd83     10,176   (10K)                free

Memory Type         Total      Used       Free
----------------  --------   --------   --------
Conventional          640K        15K       625K
Upper                  64K        54K        10K
Reserved              320K       320K         0K
Extended (XMS)   3,467,520K 2,097,941K 1,369,579K
----------------  --------   --------   --------
Total memory     3,468,544K 2,098,330K 1,370,214K

Total under 1 MB      704K        69K       635K

Memory accessible using Int 15h         0K (      0 bytes)
Largest executable program size       625K (640,144 bytes)
Largest free upper memory block        10K ( 10,192 bytes)
Available space in High Memory Area     5K (  5,232 bytes)
Windows is resident in the high memory area.
Conventional Memory Detail:

Segment        Total           Name           Type
-------  ----------------  ------------  -------------
  0000      1,024    (1K)                interrupt vector table
  0040        768    (1K)                BIOS data area
  0070      8,400    (8K)  IO            system data
                             NUL         system device driver
                             CON         system device driver
                             PRN         system device driver
                             AUX         system device driver
                             LPT1        system device driver
                             LPT2        system device driver
                             LPT3        system device driver
                             COM1        system device driver
                             COM2        system device driver
                             COM3        system device driver
                             COM4        system device driver
                             CLOCK$      system device driver
                             A: - C:     system device driver
  027d      1,248    (1K)  DOS           system data
  027f        192    (0K)    FILES       FILES=40 (3 in this block)
  028c      1,024    (1K)    EBDA        data area
  02cc      3,008    (3K)  COMMAND       program
  0389        272    (0K)  MEM           environment
  039b     55,248   (54K)  MEM           program
  1119    585,296  (572K)                free

Upper Memory Detail:

Segment        Total           Name           Type
-------  ----------------  ------------  -------------
  a000    199,280  (195K)                reserved
  d0a7      9,344    (9K)  DOS           system data
  d0a9      4,624    (5K)    UIDE        device driver
                               UDVD1     installed DEVICE=UIDE
  d1cb      1,904    (2K)    FILES       FILES=40 (32 in this block)
  d243        448    (0K)    LASTDRV     LASTDRIVE=E
  d260      2,304    (2K)    STACKS      data area
  d2f0      2,048    (2K)  COMMAND       environment
  d371        192    (0K)                free
  d37e      6,208    (6K)  SHSUCDX       program
  d503     11,648   (11K)  DOSLFNMS      program
  d7dc        752    (1K)  RDISK         program
                             E:          installed DEVICE=RDISK
  d80c      3,088    (3K)  CTMOUSE       program
  d8ce     29,456   (29K)                free

Memory Type         Total      Used       Free
----------------  --------   --------   --------
Conventional          640K        14K       626K
Upper                  61K        32K        29K
Reserved              323K       323K         0K
Extended (XMS)   3,467,520K 2,098,041K 1,369,479K
----------------  --------   --------   --------
Total memory     3,468,544K 2,098,410K 1,370,134K

Total under 1 MB      701K        46K       655K

Memory accessible using Int 15h         0K (      0 bytes)
Largest executable program size       626K (640,560 bytes)
Largest free upper memory block        29K ( 29,472 bytes)
Available space in High Memory Area    10K (  9,927 bytes)
FreeDOS is resident in the high memory area.
Basis for comparison. XMM overhead moved from UMA to conventional memory.
UMBPCI loaded code in conventional memory to "extend HIMEM.SYS."
COMMAND.COM resident portion moved from UMA to conventional memory.
100 KiB XMS was allocated for shell swapping.
BUFFERS moved from UMA to HMA.
About 4 KB of UIDE moved from HMA to UMA *
FDAPM is unnecessary.
Net savings of 18 KiB under 1 MB.

* This happened because the FreeDOS kernel does not make HMA space available to drivers loaded in CONFIG.SYS.  One can work around this limitation using DEVLOAD to load UIDE.SYS in AUTOEXEC.BAT, at which time the HMA is available.

Conclusions

Notes

[1] DOS/4GW v1.95 and v1.97 (as used by the original DOOM and DUKE3D executables, respectively) have bugs that cause serious crashes and hangs if large amounts of XMS memory are provided by an XMM working alone like in the test configuration here.  The games used in testing had their extenders replaced by the DOS/32A standard stub.

[2] 98SE flashes a splash screen during boot unless Logo=0 is in MSDOS.SYS.  ME (as patched) does not flash a splash screen during boot and ignores Logo=1 in MSDOS.SYS.

[3] The official Windows ME kernel does not permit booting in DOS mode.  For this test, IO.SYS and COMMAND.COM from an "MS-DOS startup disk" created by Windows XP 32-bit were fixed with the 75 → EB patch.  Installation was accomplished with a "deversioned" 98SE SYS.COM.

[4] Relocating the EBDA is necessary if one wants to expand conventional memory into segment A000 using an EMM as is discussed in the JEMM README.  It is unhelpful for the configuration used in this test, but it was worthwhile to establish that all three candidates allow it.  98SE relocates the EBDA by default.  FreeDOS relocates it only if asked.  ME won't relocate it no matter what, but this was worked around using the utility MOVEXBDA that comes with JEMM.

More notes

FreeDOS:  (1) The implementation of CONFIG.SYS menus is completely different and a vast improvement over that of MS-DOS.  (2) At one time, the FreeDOS roadmap said "Tightly integrated protected mode support will begin with version 1.2," but it is yet to happen.

Only 98SE has the CONFIG$ device driver.  Wikipedia identifies it in passing as the "real mode PnP manager."  Sounds potentially useful for something other than the well-publicized denial of service attacks, but that is as much as I could find on it.  (Docs, anybody?)

MS-DOS 6.22 and earlier do not support FAT32.


KB
Home