microsoft

x86-64 is an extension of the x86 instruction set. It supports vastly larger virtual and physical address spaces than are possible on x86, thereby allowing programmers to conveniently work with much larger data sets. x86-64 also provides 64-bit general purpose registers and numerous other enhancements. The original specification was created by AMD, and has been implemented by AMD, Intel, VIA, and others. It is fully backwards compatible with 32-bit code. Because the full 32-bit instruction set remains implemented in hardware without any intervening emulation, existing 32-bit x86 executables run with no compatibility or performance penalties, although existing applications that are recoded to take advantage of new features of the processor design may see significant performance increases.

AMD later introduced AMD64 as the architecture's marketing name; Intel used the names IA-32e and EM64T before finally settling on the name Intel 64 for their implementation. x86-64 is still used by many in the industry as a vendor-neutral term, as is x64.

The x86-64 specification is distinct from the Intel Itanium (formerly IA-64) architecture, which is not compatible on the native instruction set level with either the x86 or x86-64 architectures.

Architectural features

The primary defining characteristic of AMD64 is the availability of 64-bit general-purpose processor registers, i.e. rax, rbx etc., 64-bit integer arithmetic and logical operations, and 64-bit virtual addresses. The designers took the opportunity to make other improvements as well. The most significant changes include:

Virtual address space details

Operating system limits

The operating system can also limit the virtual address space. Details, where applicable, are given in the "Operating system compatibility and characteristics" section.

Physical address space details

Current AMD64 implementations support a physical address space of up to 248 bytes of RAM, or 256 TB,. A larger amount of installed RAM allows the operating system to keep more of the workload's pageable data and code in RAM, which can improve performance, though various workloads will have different points of diminishing returns.

The upper limit on RAM that can be used in a given x86-64 system depends on a variety of factors and can be far less than that implemented by the processor. For example, as of June 2010, there are no known motherboards for x86-64 processors that support 256 TB of RAM. The operating system may place additional limits on the amount of RAM that is usable or supported. Details on this point are given in the "Operating system compatibility and characteristics" section of this article.

Operating modes

Operating mode Operating system required Compiled-application rebuild required Default address size Default operand size Register extensions Typical GPR width
Long mode 64-bit mode OS with 64-bit support, or bootloader for 64-bit OS Yes 64 32 Yes 64
Compatibility mode No 32 32 No 32
16 16 16
Legacy mode Protected mode Legacy 16-bit or 32-bit OS; or bootloader for 16, 32, or 64-bit OS No 32 32 No 32
16 16 16
Virtual 8086 mode Legacy 16-bit or 32-bit OS 16 16 16
Real mode Legacy 16-bit OS; or bootloader for 16, 32, or 64 bit OS

Long mode

The architecture's intended primary mode of operation; it is a combination of the processor's native 64-bit mode and a combined 32-bit and 16-bit compatibility mode. It is used by 64-bit operating systems. Under a 64-bit operating system, 64-bit programs run under 64-bit mode, and 32-bit and 16-bit protected mode applications (that do not need to use either real mode or virtual 8086 mode in order to execute at any time) run under compatibility mode. Real-mode programs and programs that use virtual 8086 mode at any time cannot be run in long mode unless they are emulated.

Since the basic instruction set is the same, there is almost no performance penalty for executing protected mode x86 code. This is unlike Intel's IA-64, where differences in the underlying ISA means that running 32-bit code must be done either in emulation of x86 (making the process slower) or with a dedicated x86 core. However, on the x86-64 platform, many x86 applications could benefit from a 64-bit recompile, due to the additional registers in 64-bit code and guaranteed SSE2-based FPU support, which a compiler can use for optimization. However, applications that regularly handle integers wider than 32 bits, such as cryptographic algorithms, will need a rewrite of the code handling the huge integers in order to take advantage of the 64-bit registers.

Legacy mode

The mode used by 16-bit (protected mode or real mode) and 32-bit operating systems. In this mode, the processor acts just like an x86 processor, and only 16-bit or 32-bit code can be executed. Legacy mode allows for a maximum of 32 bit virtual addressing which limits the virtual address space to 4 GB. 64-bit programs cannot be run from legacy mode.

Operating system compatibility and characteristics

The following operating systems and releases support the x86-64 architecture in long mode.

DOS

It is possible to enter long mode under DOS without a DOS extender, but the user must return to real mode in order to call BIOS or DOS interrupts.

It may also be possible to enter long mode with a DOS extender similar to DOS/4GW, but more complex since x86-64 lacks virtual 8086 mode. DOS itself is not aware of that, and no benefits should be expected unless running DOS in an emulation with an adequate virtualization driver backend, for example: the mass storage interface.

Windows

x86-64 editions of Microsoft Windows client and server, Windows XP Professional x64 Edition and Windows Server 2003 x64 Edition were released in March 2005. Internally they are actually the same build (5.2.3790.1830 SP1), as they share the same source base and operating system binaries, so even system updates are released in unified packages, much in the manner as Windows 2000 Professional and Server editions for x86. Windows Vista, which also has many different editions, was released in January 2007. Windows for x86-64 has the following characteristics:

Industry naming conventions

Since AMD64 and Intel 64 are substantially similar, many software and hardware products use one vendor-neutral term to indicate their compatibility with both implementations. AMD's original designation for this processor architecture, "x86-64", is still sometimes used for this purpose, as is the variant "x86_64". Other companies, such as Microsoft and Sun Microsystems, use the contraction "x64" in marketing material.

The term IA-64 refers to the Itanium processor, and should not be confused with x86-64, as it is a completely different instruction set.

Many operating systems and products, especially those that introduced x86-64 support prior to Intel's entry into the market, use the term "AMD64" or "amd64" to refer to both AMD64 and Intel 64. x86-64 versions of Windows use the AMD64 moniker internally to designate various components which use or are compatible with this architecture. For example, the system folder on a Windows x86-64 Edition installation CD-ROM is named "AMD64", in contrast to "i386" in 32-bit versions.

See also

External links


Smallwikipedialogo
Wikipedia
This page uses Creative Commons Licensed content from Wikipedia (view authors).