What is a Relocation Register

The address generated by the CPU is a logical address which is not known to the Main Memory. The Physical memory or the Main Memory knows only the Physical address.

Therefore the address generated by the CPU(Logical Address) is compared with a Limit Register and if the value is low, It is added to the value in Relocation Register to yield a Physical Address.

In simple,

1) CPU generates Logical address(say 345)

2) 345 is compared with value in Limit Register.

3) If 345 > Limit Register then TRAP

4) If 345 < Limit Register then value is added with Relocation Register(say 300) to get physical address. ie: 345+300 = 645(Physical address)

Therefore if CPU can generate logical address in the range 0 to 345, then the corresponding physical address can range from R+0 to R+345 where R is the value in Relocation Register.

So, the address a user sees and the address a RAM sees to access a data are different.


Relocation is a base register which hold the smallest physical address and the limit register is the range of logical address or size of range.