Computer Science Engineering (CSE) Exam  >  Computer Science Engineering (CSE) Questions  >  Which of the following addressing modes are s... Start Learning for Free
Which of the following addressing modes are suitable for program relocation at run time?
I. Absolute addressing
II. Based addressing
III. Relative addressing
IV. Indirect addressing
  • a)
    I and IV
  • b)
    I and II
  • c)
    II and III
  • d)
    I, II and IV
Correct answer is option 'C'. Can you explain this answer?
Verified Answer
Which of the following addressing modes are suitable for program reloc...
Answer: C
A displacement type addressing should be preferred. So, I is not the answer.
Indirect Addressing leads to extra memory reference which is not preferable at run time. So, IV is not the answer.
View all questions of this test
Most Upvoted Answer
Which of the following addressing modes are suitable for program reloc...
Program Relocation at Run Time

Program relocation at run time refers to the ability of a program to be loaded into different memory locations when executed. This is often required in operating systems and virtual memory systems to allow multiple programs to run concurrently without interfering with each other's memory space.

Addressing Modes for Program Relocation

There are several addressing modes that can be used to achieve program relocation at run time. These modes allow the program to specify memory addresses in a flexible manner, making it possible to load the program into different memory locations. The suitable addressing modes for program relocation at run time are:

I. Absolute Addressing:
- Absolute addressing refers to specifying a fixed memory address directly in the instruction.
- This addressing mode is not suitable for program relocation at run time because the program is tied to a specific memory location.
- If the program is loaded into a different memory location, the absolute addresses in the program will be incorrect.

II. Based Addressing:
- Based addressing, also known as base-relative addressing, involves specifying a base address and an offset.
- The base address is typically stored in a register or memory location and is added to the offset to calculate the final memory address.
- This addressing mode is suitable for program relocation at run time because the base address can be adjusted to reflect the program's current memory location.
- By changing the base address, the program can be loaded into different memory locations without affecting the correctness of the addresses.

III. Relative Addressing:
- Relative addressing involves specifying a memory address relative to the program counter or some other reference point.
- This addressing mode is suitable for program relocation at run time because the relative addresses can be adjusted based on the program's current memory location.
- By adjusting the reference point, the program can be loaded into different memory locations without affecting the correctness of the addresses.

IV. Indirect Addressing:
- Indirect addressing involves specifying a memory address indirectly through a pointer or index.
- This addressing mode is suitable for program relocation at run time because the pointer or index can be adjusted to reflect the program's current memory location.
- By changing the pointer or index, the program can be loaded into different memory locations without affecting the correctness of the addresses.

Conclusion

In summary, the suitable addressing modes for program relocation at run time are based addressing, relative addressing, and indirect addressing. These addressing modes allow the program to specify memory addresses in a flexible manner, making it possible to load the program into different memory locations without affecting the correctness of the addresses. Absolute addressing, on the other hand, is not suitable for program relocation at run time as it ties the program to a specific memory location.
Explore Courses for Computer Science Engineering (CSE) exam

Top Courses for Computer Science Engineering (CSE)

Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer?
Question Description
Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer? for Computer Science Engineering (CSE) 2025 is part of Computer Science Engineering (CSE) preparation. The Question and answers have been prepared according to the Computer Science Engineering (CSE) exam syllabus. Information about Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer? covers all topics & solutions for Computer Science Engineering (CSE) 2025 Exam. Find important definitions, questions, meanings, examples, exercises and tests below for Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer?.
Solutions for Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer? in English & in Hindi are available as part of our courses for Computer Science Engineering (CSE). Download more important topics, notes, lectures and mock test series for Computer Science Engineering (CSE) Exam by signing up for free.
Here you can find the meaning of Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer? defined & explained in the simplest way possible. Besides giving the explanation of Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer?, a detailed solution for Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer? has been provided alongside types of Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer? theory, EduRev gives you an ample number of questions to practice Which of the following addressing modes are suitable for program relocation at run time?I. Absolute addressingII. Based addressingIII. Relative addressingIV. Indirect addressinga)I and IVb)I and IIc)II and IIId)I, II and IVCorrect answer is option 'C'. Can you explain this answer? tests, examples and also practice Computer Science Engineering (CSE) tests.
Explore Courses for Computer Science Engineering (CSE) exam

Top Courses for Computer Science Engineering (CSE)

Explore Courses
Signup for Free!
Signup to see your scores go up within 7 days! Learn & Practice with 1000+ FREE Notes, Videos & Tests.
10M+ students study on EduRev