Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Extended memory
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{no footnotes|date=June 2016}} {{Use dmy dates|date=May 2019|cs1-dates=y}} [[File:IBM PC Memory areas.svg|thumb|Extended memory is located above 1 MB, includes the [[high memory area]], and ends at 16 MB on the [[Intel 286]] and at 4 GB on the [[Intel 386|Intel 386DX]] and later.]] In [[DOS memory management]], '''extended memory''' refers to [[computer memory|memory]] above the first [[megabyte]] (2<sup>20</sup> bytes) of [[address space]] in an [[IBM PC]] or compatible with an [[Intel 80286|80286]] or later [[central processing unit|processor]]. The term is mainly used under the [[DOS]] and [[Microsoft Windows|Windows]] [[operating system]]s. DOS programs, running in [[real mode]] or [[virtual x86 mode]], cannot directly access this memory, but are able to do so through an [[application programming interface]] (API) called the ''[[#XMS|Extended Memory Specification]]'' (XMS). This API is implemented by a [[device driver|driver]] (such as [[HIMEM.SYS]]) or the operating system kernel, which takes care of [[memory management]] and copying memory between [[conventional memory|conventional]] and extended memory, by temporarily switching the processor into [[protected mode]]. In this context, the term "extended memory" may refer to either the whole of the extended memory or only the portion available through this API. Extended memory can also be accessed directly by DOS programs running in protected mode using [[Virtual Control Program Interface|VCPI]] or [[DOS Protected Mode Interface|DPMI]], two (different and incompatible) methods of using protected mode under DOS. Extended memory should not be confused with [[expanded memory]] (EMS), an earlier method for expanding the IBM PC's memory capacity beyond 640 kB (655,360 bytes) using an [[expansion card]] with [[Bank switching|bank switched]] memory modules. Because of the available support for expanded memory in popular applications, device drivers were developed that emulated expanded memory using extended memory. Later two additional methods were developed allowing direct access to small portions of additional memory above 640 KB from real mode. One of these is referred to as the [[high memory area]] (HMA), consisting of the first nearly 64 KB of extended memory, and the other is referred to as the [[upper memory area]] (UMA; also referred to as upper memory blocks or UMBs), located in the address range between 640 KB and 1 MB which the IBM PC designates for hardware adapters and ROM. ==Overview== On [[x86]]-based PCs, extended memory is only available with an [[Intel 80286]] processor or higher, such as the [[IBM PC AT]].<ref name="Mendelson_1989">{{cite magazine |title=A Slot Full of RAM |date=1989-12-12 |author-last=Mendelson |author-first=Edward |author-link=Edward Mendelson |magazine=[[PC Magazine]] |publisher=[[Ziff Davis Publishing Co.]] |volume=8 |number=21 |pages=169β |url=https://books.google.com/books?id=5CmkZ3THZtwC&pg=PT170 |access-date=2020-02-08 |url-status=live |archive-url=https://web.archive.org/web/20200208221014/https://books.google.de/books?id=5CmkZ3THZtwC&lpg=PT171&pg=PT170&redir_esc=y |archive-date=2020-02-08}}</ref> Only these chips can directly address more than 1 megabyte of [[random-access memory|RAM]]. The earlier [[Intel 8086|8086]]/[[Intel 8088|8088]] processors can make use of more than 1 MB of RAM if one employs [[bank switching|special hardware]] to make selectable parts of it appear at addresses below 1 MB. On a 286 or better PC equipped with more than 640 kB of RAM, the additional memory would generally be re-mapped above the 1 MB boundary, since the IBM PC architecture reserves addresses between 640 kB and 1 MB for system ROM and peripherals. Extended memory is not accessible in [[real mode]] (except for a small portion called the [[high memory area]]). Only applications executing in [[protected mode]] can use extended memory directly. A supervising protected-mode [[operating system]] such as [[Microsoft Windows]] manages application programs' access to memory. The processor makes this memory available through the [[Global Descriptor Table]] (GDT) and one or more [[Local Descriptor Table]]s (LDTs). The memory is "protected" in the sense that memory segments assigned a local descriptor cannot be accessed by another program because that program uses a different LDT, and memory segments assigned a global descriptor can have their access rights restricted, causing a processor [[Exception handling|exception]] (e.g., a [[general protection fault]] or GPF) on violation. This prevents programs running in protected mode from interfering with each other's memory.<ref name="FOLDOC">{{foldoc|extended+memory}}</ref> Extended memory went unused at first because no software ran in the 80286's protected mode. By contrast, the industry quickly adopted 1985's [[expanded memory]] standard, which works with all PCs regardless of processor.{{r|Mendelson_1989}} A protected-mode operating system such as Microsoft Windows can also run real-mode programs and provide expanded memory to them. The [[DOS Protected Mode Interface]] (DPMI) is Microsoft's prescribed method for a [[DOS]] program to access extended memory under a [[computer multitasking|multitasking]] environment.<ref name="FOLDOC" /> == {{anchor|XMS}}''Extended Memory Specification'' (XMS) == The '''''Extended Memory Specification''''' ('''XMS''') is the specification describing the use of [[IBM PC]] extended memory in [[real mode]] for storing data (but not for running executable code in it). Memory is made available by '''extended memory manager''' ('''XMM''') software such as [[HIMEM.SYS]]. The XMM functions are accessible by direct calls to a variable address that can be found through [[software interrupt]] 2Fh function 4310h. XMS version 2.0, released in July 1988, allowed for up to 64 MB of memory.<ref name=XMS2>[[Microsoft]], [[Lotus Software|Lotus]], [[Intel]], and [[AST Research]] (1988-07-19). [http://www.phatcode.net/res/219/files/xms20.txt ''eXtended Memory Specification (XMS), version 2.0'']</ref> With XMS version 3.0 this increased to 4 GB (2<sup>32</sup> bytes).<ref name=XMS3>Microsoft, Lotus, Intel, and AST Research (January 1991). [http://www.phatcode.net/res/219/files/xms30.txt ''eXtended Memory Specification (XMS), version 3.0'']</ref> The difference is a direct result of the sizes of the values used to report the amounts of total and unallocated (free) extended memory in 1 KB (1024-byte) units: XMS 2.0 uses 16-bit unsigned integers, capable of representing a maximum of (65535 * 1 KB) = 64 MB, while XMS 3.0 adds new alternate functions that use 32-bit unsigned integers, capable of representing (4 G * 1 KB) = 4 TB (4 terabytes) but limited by the specification to 4 GB.<ref name=XMS2/><ref name=XMS3/> (4 GB is the address range of the 80386 and the 80486, the only 32-bit Intel x86 CPUs that existed when XMS 3.0 was published in 1991.) XMS 3.0 retains the original XMS 2.0 API functions with their original 64 MB limit but adds new "super extended memory" functions that support 4 GB of extended memory (minus the first 1 MB) and can be called only with a 32-bit CPU (since these "super" functions use 32-bit CPU registers to pass values).<ref name=XMS3/> To differentiate between the possibly different amount of memory that might be available to applications, depending on which version of the specification they were developed to, the latter may be referred to as '''super extended memory''' ('''SXMS'''). The extended memory manager is also responsible for managing allocations in the [[high memory area]] (HMA) and the [[upper memory area]] (UMA; also referred to as upper memory blocks or UMBs). In practice the upper memory area will be provided by the [[expanded memory]] manager (EMM), after which DOS will try to allocate them all and manage them itself.{{clarify |reason= How? Does DOS manage and allocate UMBs as though they were conventional memory?|date=September 2024}}{{fact|date=September 2024}} ==See also== * [[DOS memory management]] * [[Conventional memory]] * [[Expanded memory]] (EMS) * [[High memory area]] (HMA) * [[Upper memory area]] (UMA) * [[Global EMM Import Specification]] (GEMMIS) * [[Unreal mode]] ==References== ; Specifications {{reflist}} <!-- These references are now in the {reflist} as a result of <ref> tags in the "Extended Memory Specification (XMS)" section * [[Microsoft]], [[Lotus Software|Lotus]], [[Intel]], and [[AST Research]] (1988-07-19). [http://www.phatcode.net/res/219/files/xms20.txt ''eXtended Memory Specification (XMS), version 2.0'']. * Microsoft, Lotus, Intel, and AST Research (January 1991). [http://www.phatcode.net/res/219/files/xms30.txt ''eXtended Memory Specification (XMS), version 3.0'']. --> ; Microsoft Knowledge Base * [https://jeffpar.github.io/kbarchive/kb/037/Q37242/ ''A General Tutorial on the Various Forms of Memory''] * [https://jeffpar.github.io/kbarchive/kb/095/Q95555/ ''Overview of Memory-Management Functionality in MS-DOS''] * [https://jeffpar.github.io/kbarchive/kb/121/Q121008/ ''Microsoft Diagnostic Utility: Definition of SXMS''] ==External links== * [http://www.phatcode.net/articles.php?id=219 Extended Memory (XMS) Specification] {{DEFAULTSORT:Extended Memory}} [[Category:X86 memory management]] [[Category:DOS memory management]] [[Category:Memory expansion]]
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)
Pages transcluded onto the current version of this page
(
help
)
:
Template:Anchor
(
edit
)
Template:Cite magazine
(
edit
)
Template:Clarify
(
edit
)
Template:Fact
(
edit
)
Template:Foldoc
(
edit
)
Template:No footnotes
(
edit
)
Template:R
(
edit
)
Template:Reflist
(
edit
)
Template:Use dmy dates
(
edit
)