64 - Bit Utilization Backwards Compatibility Modes

Most 64-bit processors include various backwards compatibility modes, in which they can operate in a 32-bit mode to run programs that have not been recompiled for 64-bit operation. For example, all processors operating on the AMD64 specificiation include 2 modes:

  1. Long mode
    1. 64-bit mode
    2. Compatibility mode
  2. Legacy mode

Legacy mode, the simplest of the two, operates if the processor is not used in tandem with a 64-bit operating system. It essentially operates as a 32-bit processor, with the processor appearing x86 compatible to both the operating system and the applications. This mode cannot run 64-bit programs.

Long mode operates if the processor is used in tandem with a 64-bit operating system. Within long mode, there are two sub-modes. The operating system chooses which mode to operate in based on the program being run. The processor can freely toggle back and forth between modes based on the current thread that is occupying the processor, so multitasking between 64 and 32-bit programs is possible.

Within 64-bit mode, all of the features of 64-bit processing (e.g. larger RAM, greater precision, more SPIC registers, RIP-relative addressing, differing opcodes) are enabled. Within legacy mode and compatibility modes, none of these features are enabled.

How do compatibility mode and legacy mode differ?

From the application’s perspective, they don’t. Both modes appear the same as protected mode on an x86 system. The difference is that legacy mode applies to the operating system as a whole, while compatibility mode is a thread-specific selection.

Legacy and compatibility modes provide a performance equivalent to that of a 32-bit processor operating at the same clock speed.

The other primary 64-bit standard, IA-64, is also capable for operating in 32-bit mode, however there is a severe speed penalty.