Recent Changes - Search:

Recently Written


edit SideBar


(short description for newcomers and users)

1.  User info

1.1  DOS and memory

Old DOS versions had a limit of memory, one could only use 640 KiO conventional memory. But, also and even DOS is much more modern then some years ago: It can support all of your RAM ! If you have 1 GiO you can access 1 GiO under DOS.

So if someone is developing a program which needs much memory, the preferred way to do is using the dos protected mode interface (DPMI) to get access of all memory in your computer. There are two versions, one for 16-Bit, which is outdated, and the standard one for 32-Bit processors.

1.2  “need DPMI server” / DPMI vs “DOS Extender”

There are many DPMI hosts. Very popular are CWSDPMI (older) and HDPMI / HX-DOS Extender (better) at the moment. Note: DPMI host = DPMI kernel = DPMI provider = DPMI driver = DPMI server . The word “host” is probably the safest and least confusing one.

2.  Advanced DPMI / DOS extender info for developers

Here you will find best of all DOS Extenders and DPMI hosts. But why do you need DPMI? Most of modern programs use DPMI to access all of memory (RAM) instead of only 640 KiO. It brings a significant performance benefit compared to real mode with XMS or EMS.

2.1  Most recommended up-to-date products

HX-DOS Extender - DOS extender with Win32 emulation, see also HX-DOS, provides HDPMI32 - very good DPMI host with “DOS API translation” / “TrueDPMI” and almost complete DPMI 1.0 implementation. Ideal for “raw DPMI” development in ASM.

DOS/32A Extender


Project page:

By Narech Koumar / Supernar Systems , “WATCOM”-style extender, no Win32 emulation, but small and efficient standalone executables, usable with [Open]Watcom, CC386, VirtualPASCAL, and TMT-PASCAL (not with DJGPP and Free-BASIC/PASCAL), with a small trick also with FASM. Applications are run in Ring0, except an external Ring3 DPMI host is used, and paging won’t be enabled, except brought by an external (paging) DPMI host or (always based on paging) EMM386. Not very active recently, but very mature in its category (nothing to fix ;-) ), and author is accessible in case of problems or bugs.


While it is compact, fast and supports large RAM (2 or 4 GiO ?? ), it suffers from some design flaws cloned from DOS/4GW (it was designed as a drop-in replacement of this), and has the bad habit (there are “some” reasons for this, thus) to ignore an existing DPMI host under DOS, versions 9.xx not only always prefer VCPI over DPMI, but in real mode also install its own DPMI kernel (bypassing the existing one) on top of XMS if present. To make DOS/32A cooperate with HDPMI32, either no XMS, or EMM386 with NOVCPI hack are needed.

Source code

DOS/32A is written completely in assembly (the extender itself, utils are in C ), compiles with TASM using IDEAL mode, and its source is very nice and well commented. The old version 7.1 (don’t use the SB-tool from this version !! ) comes with full documentation and examples.

2.2  List of other notable extenders, including historical ones

PharLap 286/386/TNT extender

By PharLap … reportedly the very first 16-bit and 32-bit DOS extenders (first based on “raw PM” / VCPI, later (1990) moved to DPMI) … commercial, expensive.


By Rational Systems , used mostly with WATCOM compiler, very popular from cca 1990 to 1995, used in many famous DOS games, later (in 1995) the company renamed to Trenberry , and stopped the development, nevertheless company page still exists and product reportedly still “available”, and since 2002 bundled with OpenWATCOM compiler (free of cost, but no source). DOS/4G supports DLL’s (LE-format) while DOS4/GW doesn’t.


By Tran , the “original” variant, open source, liberal license.


OS/2 related …


Based on PMODE, used to be a commercial product, now freeware, but still closed source. Binds to LE executables, designed for use with WATCOM compiler. See also:


WATCOM-like / LE extender by M. Devore , supporting DOS-specific DLL’s in LE-format. In 2000 development stopped and product including sources was released into public domain. Obsoleted by DOS/32A and HX .


The official, but now slightly outdated DPMI host for DGJPP, FreePASCAL and FreeBASIC. Latest “stable” (it is quite stable) version is r7 from 2010, previous (also stable) was r5 from 2000, there were several r5 updates, latest from 2008 August fixing some bugs (??) and enabling SSE . Be warned from old (<5) buggy versions of CWSDPMI, distributed with FPC 1.0.10 and many other DPMI programs. CWSDPMI r5 has a memory limit of cca 512 MiO (more should not crash but can’t be accessed) and does swap by default (idea originates from cca 1990 when GCC (relying on swap by design) had to self-compile in DOS on very low memory machines), this can be deactivated, but programs have NO good way to detect whether it is active or not. The safest way to prevent from running programs on obsolete and buggy (can crash on new machines or new code) or swapping-enabled CWSDPMI is to use HDPMI32 and make it resident.



DPMIONE - DPMI host which is the only one that supports both 16-bit and 32-bit programs (“clients”), also full DPMI 1.0, and uncommitted memory).

It isn’t under active development, but if you find errors or have questions, you may contact the author Bob Smith directly.


From the homepage:

WDosX is a free 32 bit DOS extender. The most recent final version is 0.97 which you can download from this page. Supported memory allocation schemes are:

  • RAW (BIOS INT 0×15)
  • XMS
  • VCPI
  • DPMI

While running under WDosX your program has access to a fair subset of DPMI 0.9 functions as well as an extended DOS INT 21 API. WDosX comes with some libraries, example programs and a full screen debugger. It features a true flat (zero based) memory model and support for DLLs as well as executable compression.

WdosX provides a minimal Win32 API emulation (like HX-DOS, but now far behind it), should be compatible (besides PE) with both WATCOM/LE and DGJPP/COFF executables, but seems no longer under development since year 2000, with some minor fixes in 2005, latest version is 0.97 Final .


By Daniel Borca , similar to WDOSX, a “full” extender (the DPMI host is hard-merged with the “extender”/loader). Comes in 3 variants:


The extender (the 3 variants of it) itself compiles with NASM, the tools (the “stub binding” code) with DJGPP. Former page: (dead)


By Tomasz Grysztar , abandoned, released 2011. “HDOS released” 2011-Dec-19

3.  Drivers (using Protected Mode in DOS)

And what about drivers? There is an old DR-DOS interface DPMS which isn’t used in many drivers. Another way is using of the new JEMM driver. It doesn’t only include both memory managers HIMEM and EMM386 in one file, but also provides the possibility of writing protected mode drivers for DOS. JEMM is under a liberal open source license so it is possible to provide it with your driver. For more info see MemoryManagers? under Jemm Loadable Modules.

4.  See also

Edit - History - Print - Recent Changes - Search
Page last modified on August 14, 2016, at 09:35 AM