An object file is linked to generate an ELF file and its virtual address is determined. For example, the virtual address of .text is 0x8048000. When the ELF file is going to be mapped to virtual space, another ELF has already been mapped to this address. What the operating system should do? Why the virtual address of ELF can be determined before it is mapped to virtual space.
Each process gets its own private virtual address space — that's the point of it being virtual; it doesn't have to correspond to where the program is actually located in physical RAM. So there's no conflict of addresses between programs running in different processes. They can all be mapped to that address, each in its own private address space.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With