Section 11.5: Protection (Frame 5)                     [prev][home][next]

Fig. 11.5.2 shows the combination of base address register and field length register. The base address register contains an actual memory address, but the field length register contains the maximum length of the program's memory region in words. For Job A, this would be 1100 since Job A starts at (real) address 2500 and ends at 3599, which is 1100 words.


Fig. 11.5.2: Base address register for relocation; Field length register for protection

Every logical memory address that Job A generates while executing instructions is added to the base address and the new value is copied into the real MAR. At the same time, that logical address is compared to the value in the field length register, and if the result is negative, a memory protection error is signaled and the memory operation never completes. Further, Job A is halted in its tracks and a nasty error message is printed out by the operating system.