Computer Science, asked by bpgaikwad8144, 1 year ago

How 20 bit physical address is generated in 8086?

Answers

Answered by Akanksha0623
79

Answer:

8086 has a concept of Memory Segmentation. It is a method where the whole memory is segmented (divided) into smaller parts called segments. These segments are

• Code Segment (CS)

• Stack Segment (SS)

• Data Segment (DS)

• Extra Segment (ES)

Each Segment has a corresponding 16-bit Segment Register which holds the Base Address (starting Address) of the Segment. At any given time, 8086 can address 16-bit x 64KB = 256 KB of memory chunk out of 1MB.

8086 has 20bit address line. So the maximum value of address that can be addressed by 8086 is 2^20 = 1MB. So 8086 can address the locations ranging between 00000 H to FFFFF H. This 1MB memory is divided into 16 logical segments, each with a memory of 64KB.

To locate any adress in the memory bank, it needs the Physical address of that memory location. It cannot get the 20-bit Physical adress using the 8086 Address Line or 16-bit Segment Registers alone.

In order to access memory location, you cannot pass 20-bit address directly to the processor. You need to tell the 16-bit address with respect to the segment. This 16-bit address with respect to the part (segment of 64KB) of the memory bank is called the offset.

So, Physical Address = Base Address + Offset.

Suppose the Data Segment holds the Base Aaddress as 1000h and the data you need is present in the 0020h memory location (Offset) of the Data Segment. The calculation of the actual address is done as follows.

1. Left shift the 16-bit address present in the segment register by 4-bits

0001 0000 0000 0000 (0000)

2. Add the 16-bit offset address to this shifted base address

0001 0000 0000 0000 0000

+ 0000 0000 0010 0000

--------------------------------------

0001 0000 0000 0010 0000

So the actual address turns out to be 10020h.

At any point of time we can change the base address of the segment registers and use the memory locations in those segments using the offset.

Hope it helps you

Mark it as Brainliest

Answered by shilpa85475
0

Explanation:

8086 has an idea of Memory Segmentation.

It is a way wherein the complete reminiscence is segmented (divided) into smaller elements known as segments.

Each Segment has a corresponding sixteen-bit Segment Register which holds the Base Address (beginning Address) of the Segment.

At any given time, 8086 can deal with sixteen-bit x 64KB = 256 KB of reminiscence bite out of 1MB. 8086 has a 20 bit deal with the line.

So the most cost of dealing with that may be addressed through 8086 is 2^20 = 1MB.

So 8086 can deal with places ranging from 00000 H to FFFFF H.

This 1MB reminiscence is split into sixteen logical segments, every with a reminiscence of 64KB.

To discover any address withinside the reminiscence financial institution, it desires the Physical deal with of that reminiscence location.

It can not get the 20-bit Physical address by the use of the 8086 Address Line or sixteen-bit Segment Registers alone.

In order to get the right of entry to reminiscence location, you can not skip a 20-bit deal without delay to the processor.

You want to inform the sixteen-bit deal with recognition to the section.

This sixteen-bit deal with recognize to the part (section of 64KB) of the reminiscence financial institution is known as the offset. So, Physical Address = Base Address + Offset. Suppose the Data Segment holds the Base address as 1000h and the statistics you want are gift withinside the 0020h reminiscence location (Offset) of the Data Segment.

The calculation of the real deal is performed as follows.

1. Left shift the sixteen-bit deal with gift withinside the section sign in through 4-bits 0001 0000 0000 0000 (0000) 2. Add the sixteen-bit offset deal with to this shifted base to deal with 0001 0000 0000 0000 0000 + 0000 0000 0010 0000 -------------------------------------- 0001 0000 0000 0010 0000 So the real deal with seems to be 10020h.

At any factor of time, we are able to alternate the bottom deal with of the section registers and use the reminiscence places in the one's segments the use of the offset.

Similar questions