Discussion
A relocatable program is one that
Answer: D
Correct answer: can be loaded and run at any address in memory
A relocatable program can be placed anywhere in memory, because its addresses are expressed relative to a starting point rather than as absolute values. The loader or the hardware supplies the actual base. The alternative is absolute code, produced by binding addresses at compile time. It must be loaded at one fixed address, and moving it requires recompilation - workable only where a single program owns the machine. Relocation may happen at load time, when the loader adjusts every address once, after which the program cannot move; or at execution time, when a base register is added to each address by hardware, and the program can be moved simply by changing the register. Only execution-time binding permits swapping and compaction, since both require a running process to change location. It is what every general-purpose system uses, and paging is its general form, with a page table in place of a single register.
Post your comment
Please log in or register to post a comment.
Examination Categories
- SSC Exams
- Banking Exams
- Teaching Exams
- Civil Services Exams
- Railways Exams
- Engineering Recruitment Exams
- Defence Exams
- State Government Exams
- Police Exams
- Insurance Exams
- Nursing Exams
- Other Government Exams
- NRA CET
- PG Entrance Exams
- Campus Placement
- MBA Entrance Exams
- CUET and UG Entrance
- Judiciary Exams
- Regulatory Body Exams
- Software Development