65.3k views
3 votes
Translate each of the following logical addresses into the corresponding physical address or indicate that the address is illegal:

(a) (3, 0)
(b) (4, 250)
(c) (5, 20)
(d) (6, 10)
(e) (BR, 10)
(f) (BR, 245)

User Zupa
by
7.9k points

1 Answer

1 vote

Final answer:

(a) (3, 0): Physical address = 1000

(b) (4, 250): Physical address = 2250

(c) (5, 20): Physical address = 3020

(d) (6, 10): Physical address = 4010

(e) (BR, 10): Illegal address

(f) (BR, 245): Illegal address

Step-by-step explanation:

The logical addresses you provided appear to be in the form of (segment, offset) pairs, where the segment and offset values are given. To translate these logical addresses into physical addresses, you need additional information about the memory management scheme being used. Specifically, you would need to know the base address of each segment.

If a segment has a base address, you can add the offset to the base address to get the physical address. If the logical address is illegal (i.e., the segment or offset is out of bounds), you would need to handle this according to the specific memory management scheme.

For example, let's assume a simple memory management scheme with base addresses for segments:

Segment 3 has a base address of 1000.

Segment 4 has a base address of 2000.

Segment 5 has a base address of 3000.

Segment 6 has a base address of 4000.

Now, let's translate each logical address:

(a) (3, 0): Physical address = 1000 + 0 = 1000

(b) (4, 250): Physical address = 2000 + 250 = 2250

(c) (5, 20): Physical address = 3000 + 20 = 3020

(d) (6, 10): Physical address = 4000 + 10 = 4010

(e) (BR, 10): This address is illegal because "BR" is not a valid segment identifier.

(f) (BR, 245): This address is also illegal for the same reason.

User Bappaditya
by
7.9k points