Professional Documents
Culture Documents
2.What are the conditions under which the EU enter into the WAIT mode?
The EU goes into the WAIT mode in the following three conditions:
- If an instruction requires an access to a memory location which is not present in the queue the
EU enters into the WAIT state.
- The EU enters into the WAIT mode when a JUMP instruction is executed. In such cases the
existing queue contents are removed the EU waits for more instructions
from the new address in the memory.
- Certain instructions can take quite some time to execute in such cases the EU again goes into
the WAIT state. For cases such as these the BIU waits till the EU is able
to extract some bytes from the queue.
3.Explain briefly how the register in the 8086 are grouped together?
The 8086 in total consists of 14 16 bit registers. They are grouped together in the following way:
- All the registers are divided into the following groups: Data, Pointers and Index group, segment
group and status and control flag group.
- The accumulator AX, base BX, count CX and data DX account for the data registers.
- The stack pointer SP, base pointer BP, source index SI, Destination index DI and the Instruction
painter IP are the pointer registers.
- The Extra segment, code segment and stack segment are in the segment group of registers
- A single 16 bit flag register is present in the Control flag group.
5.Briefly explain the logical address, base segment address and physical address.
- Logical address is contained in the 16-bit IP, BP, SP, BX, SI or DI. It is also known as the offset
- Whenever a compare operation is performed the result of such an operation reflects in one of
the six status flags CF, AF, OF, PF, SF and ZF.
-The CMP operation is also known as the subtraction method as it uses two`s complement for it.
- The result of a CMP operation is never saved but corresponding to the result of the instruction
the flag statuses may be changed or reset.
- The operands of CMP instruction may reside in the memory or can be a component of an
instruction.
8.Point out the major differences in Short label and Near label jump instructions.
The following steps occur when an interrupt occurs ( both for hardware and software )
- First thing the contents of the flag register the CS and IP are pushed into the stack.
- To disable the single steps and INTR interrupts the TF and IF are cleared.
- The program then jumps to the beginning or starting address of the ISS.
- When the IRET gets executed in the last line ( this occurs at the end of the ISS) the CS and IP
flag contents are popped from the stack and placed in the appropriate registers.
- Once all the flags are restored to their original condition the IF and TF are also restored to their
previous values.
11.List out the differences between Isolated I/O and Memory mapped I/O.
14.Briefly explain the three different types of control flags for the 8086.
- The 8086 has three control flags namely TF, IF and DF. All three of them can be user
programmed to suit their needs.
- The trap flag allows the cpu to run in a single stepping mode. This comes in very handy in
debugging and development purposes.
- The interrupt flag causes the INTR ( maskable interrupt ) to be enabled else it would remain
disabled. Whenever the cpu is reset so is IF reset / cleared.
- In string operations primarily the Direction flag is used. The STD instruction is responsible for
the setting of the DF.
- Stack pointer and base pointer are the two pointer registers whereas the Source index and
Destination index are the index group of registers.
- They are primarily used to store relative to segment registers the locations of offset addresses of
memory locations. They serve the purpose of being memory pointers.
- The source index and destination index are also used as general purpose register. In such cases
the SI and DI are implemented as source and destination index registers.
- In stacks, data areas might exist, to be able to access such data which contains the BP register.
- The two types of unconditional jumps are intersegment and intrasegment jumps.
- In the case of intrasegment jumps as the name suggest is a special type of jump in which the
address to which the jump is to be performed is present / lies in the same code segment from
where the jump is performed from. In order to perform this jump changes just need to be made in
the Instruction pointer.
- In the case of intersegment jumps the jump takes place from one segment to another. In order to
be able to make these kinds of jumps the changes need to be made in both the code segment and
the instruction pointer.