Logical address (Logical Address)
Is generated by the program associated with the segment offset address portion.
For example, pointers in C programming you are doing, you can read the value of the pointer variable itself (& operation), in fact, this value is the logical address, it is relative to your current process data segment address, nothing to do with the absolute physical address. Only the Intel real mode, the logical address and physical address was the same (because there is no real mode segmentation or paging mechanism, Cpu does not automatically address translation); logic is the Intel protected mode program execution within the code segment limit long offset (assuming the code segment, data segment if exactly the same). Application programmers only need to deal with the logical address, while the segmentation and paging mechanism is completely transparent to you, only by system programmers involved. Although the application programmer can directly operate its own memory, it can only give you the operating system allocated memory segment operations.
Linear address (Linear Address)
Is a logical address to physical address translation between the middle layer. Code will produce a logical address, or a segment offset, coupled with the corresponding base of the segment to generate a linear address. If the paging mechanism is enabled, then the linear address can then by transformed to produce a physical address. If the paging mechanism is not enabled, then the linear address directly is the physical address. Intel 80386 linear address space capacity of 4G (2 ^ 32 that 32 of the address bus address).
Physical address (Physical Address)
Is that now the CPU external address bus addressing physical memory address signal, the end result is the address change the address. If the paging mechanism is enabled, then the linear address will be used in the page directory and page table entry converted into physical addresses. If the paging mechanism is not enabled, then the linear address directly to a physical address.
Virtual memory (Virtual Memory)
Refers to a computer showing a much larger memory than the actual possession of the amount of memory. Thus it allows programmers to compile and run the memory than the actual system has a much larger program. This has led many large projects with limited memory resources to the system to achieve.
Sometimes we have the logical address as the virtual address. Because the concept of virtual memory space is similar to the logical address and the actual physical memory is irrelevant.
Logical address and physical address of the "gap" is 0xC0000000, is due to the logical address -> linear address -> physical address mapping just bad this value. This value is specified by the operating system.
Logical address to physical address translation
Logical address to physical address conversion method is associated with architecture. In general there is segmentation, paging in two ways.
At the current x86 cpu, for example, sub-pages are supported. Memory Mangement Unit is responsible for the logical address to physical address from the conversion. Section identifies the logical address is the segment + offset form, MMU segment by querying the table, the logical address can be transformed into a linear address. If the cpu is not turned on paging, the linear address is the physical address; if the cpu on the paging feature, MMU page tables also need to check into the linear address to physical address:
----( Logical address linear address segment table )---> - (page table) -> physical address
Different logical addresses can be mapped to the same linear address; different linear addresses can be mapped to the same physical address; it is many to one relationship. In addition, the same linear address in the event after the feed may also be re-loaded to another physical address. So many to one mapping of this will change over time.
Original Address: http://my.oschina.net/alphajay/blog/5025