All 31
All 31
The 8086 microprocessor supports several types of instructions, which can be grouped into
various categories like data transfer, arithmetic, logical, control, and string instructions. Here are
some examples:
MOV destination, source: Copies data from the source to the destination.
o Example: MOV AX, BX (Moves the content of BX into AX)
PUSH operand: Pushes the operand onto the stack.
POP operand: Pops the top value from the stack into the operand.
o Example: POP AX (Pops the top value from the stack into AX)
Arithmetic Instructions:
ADD destination, source: Adds the source operand to the destination operand.
SUB destination, source: Subtracts the source operand from the destination operand.
Logical Instructions:
Control Instructions:
o Example: NOP
String Instructions:
Control instructions manage the flow of execution in the program. These are essential for
controlling loops, function calls, and halting the processor.
NOP (No Operation): This instruction does nothing but consumes time and can be used
for debugging or timing operations.
o Example: NOP
HLT (Halt): Halts the execution of the program. It is used to stop the execution of the
program when the processor reaches a halt condition.
o Example: HLT
JMP (Jump): This instruction causes the program to jump to a specific address without
any condition. It is an unconditional jump.
CALL (Call Subroutine): This instruction calls a subroutine. The return address is pushed
onto the stack, and control is transferred to the subroutine.
LOOP (Loop): This instruction is used for repeating a block of code a specified number of
times. It uses the CX register as the counter, decrementing it on each loop.
INT (Interrupt): This instruction is used to generate a software interrupt, allowing the
processor to handle exceptional conditions or external events.
IRET (Interrupt Return): This instruction is used to return from an interrupt service
routine. It restores the flags and the return address from the stack.
The addressing modes in 8086 define how operands are specified for the instructions. 8086
supports several addressing modes, including the following:
Register Addressing Mode: The operand is located in a register. This is one of the fastest
modes because the data is already in the register.
Direct Addressing Mode: The operand is located at a specific memory address provided
in the instruction.
o Example: MOV AX, [5000h] (Move the data at memory location 0x5000 into AX)
Indirect Addressing Mode: The effective address of the operand is stored in a register,
like SI (Source Index), DI (Destination Index), or BP (Base Pointer).
o Example: MOV AX, [BX] (Move the data pointed to by BX into AX)
Register Indirect Addressing Mode: The effective address is the contents of a register,
like [BX], [SI], or [DI].
o Example: MOV AX, [SI] (Move the data at the address in SI into AX)
Indexed Addressing Mode: The operand's effective address is the sum of a base register
and an index register.
o Example: MOV AX, [BX + SI] (Move data from the memory address calculated by
adding BX and SI into AX)
o Example: MOV AX, [BX + 10] (Move data from memory address BX + 10 into AX)
o Example: JMP 0x10 (Jump to the address 0x10 relative to the current instruction
pointer)
o Example: MOV AX, [BX + SI + 8] (Moves the data at the address obtained by
adding BX, SI, and 8 into AX)
4 Write the difference between 8087 Intel-co processor and 8086 microprocessors.
The 8087 Intel co-processor and the 8086 microprocessor are two different components designed
by Intel for specific purposes in computing. Here’s a comparison highlighting their key
differences:
1. Purpose:
2. Functionality:
8086 Microprocessor: It performs general-purpose tasks like executing instructions for program
control, arithmetic, and logic operations using 16-bit data paths.
8087 Co-processor: It accelerates floating-point calculations and is dedicated to handling
floating-point arithmetic and mathematical functions such as trigonometry, logarithms, and
exponential calculations.
3. Architecture:
8086 Microprocessor: It has a 16-bit architecture, meaning it can process 16 bits of data at a
time. It supports a 20-bit address bus, which allows it to access up to 1 MB of memory.
8087 Co-processor: It is also built for 16-bit operations, but it does not function as a standalone
processor. It connects directly to the 8086 microprocessor and works to speed up mathematical
computations, particularly those requiring floating-point arithmetic.
4. Data Types:
8086 Microprocessor: It primarily deals with integer data types (such as byte, word, and double
word).
8087 Co-processor: It specializes in floating-point data types and provides instructions to handle
these types efficiently.
5. Clock Speed:
8086 Microprocessor: The clock speeds typically range from 5 MHz to 10 MHz.
8087 Co-processor: It runs at the same clock speed as the 8086 processor, but it performs
specific operations faster when used in conjunction with the 8086.
6. Instruction Set:
8086 Microprocessor: It has a general-purpose instruction set, which is designed for arithmetic,
data transfer, control, and logic operations.
8087 Co-processor: It has a specialized instruction set for performing floating-point arithmetic
and mathematical operations, including functions like sin, cos, tan, square root, and others.
7. Integration:
8086 Microprocessor: It operates independently and does not require an additional processor
for standard operations.
8087 Co-processor: It requires the 8086 or compatible processor to work. It is typically used to
enhance the performance of the system in applications requiring heavy mathematical
computation.
8. Usage:
9. Compatibility:
8086 Microprocessor: It can operate without the 8087 co-processor, handling both integer and
basic floating-point operations with software routines.
8087 Co-processor: It needs to be paired with the 8086 to function, as it does not work
independently.
5 What are the function of Ready, ALE, HOLD, and RESET pins of 8086
microprocessor?
The 8086 microprocessor has several control pins that serve various functions in managing the
operation and communication with external devices. Below are the functions of the Ready, ALE,
HOLD, and RESET pins of the 8086 microprocessor:
Function: The READY pin is used to synchronize the operation of the 8086 with slower
peripheral devices or memory.
Explanation: When the 8086 accesses memory or I/O devices, it may need to wait for the device
to respond, especially if the device is slower than the CPU. The READY pin allows the CPU to
pause the bus cycle until the peripheral is ready for data transfer.
Operation:
o When READY is low (0), the 8086 waits for the device to be ready.
o When READY is high (1), the 8086 proceeds with the next operation.
Usage: It is used in systems where the memory or I/O devices are slower than the 8086 CPU and
need extra time to respond.
Function: The HOLD pin is used to request the control of the system's buses from the 8086 by an
external device (such as a DMA controller).
Explanation: When the external device needs access to the system buses (for direct memory
access or other purposes), it can assert the HOLD signal to gain control of the bus.
Operation:
o When HOLD is asserted (low), the 8086 will release the buses and allow the external
device to take control.
o The 8086 then asserts the HLDA (Hold Acknowledge) pin to confirm the release of the
bus.
Usage: The HOLD pin is primarily used in systems that implement Direct Memory Access (DMA),
where peripheral devices directly transfer data to or from memory without involving the CPU.
Function: The RESET pin is used to reset the 8086 microprocessor and initialize it to a known
starting state.
Explanation: When the RESET pin is activated, it forces the 8086 into a reset condition, clearing
internal registers and preparing the microprocessor for normal operation.
Operation:
o When RESET is asserted (low), the 8086 stops executing instructions and initializes
internal registers, flags, and control lines.
o The CPU starts execution from a predefined memory address (0xFFFF0, the reset
vector).
o Once RESET is de-asserted (high), the 8086 begins normal execution from the reset
vector.
Usage: The RESET pin is commonly used during system power-up or when there is a need to
recover from an error condition by restarting the CPU.
6 Discuss the 80X86 family of CPU’s
The 80x86 family of CPUs (often referred to as the x86 family) is a series of microprocessors
developed by Intel that forms the foundation for most modern personal computers and servers.
The family traces its roots back to the Intel 8086 processor and has evolved through several
generations with increased performance, capabilities, and compatibility. Here's a detailed
discussion on the 80x86 family of CPUs, from the early 8086 to the modern processors:
Architecture: Similar to the 8086 but with an 8-bit external data bus, which made it cheaper and
easier to interface with existing 8-bit hardware.
Significance: The 8088 was widely used in the IBM PC (originally released in 1981), which helped
establish the x86 architecture as the dominant CPU architecture for personal computers.
Architecture: 32-bit processor with a 32-bit data bus and a 32-bit address bus, allowing access
to 4 GB of memory.
Operating Mode: Protected mode was enhanced with virtual memory and paging, allowing
processes to have their own separate memory spaces and providing protection against crashes.
Significance: The 80386 was the first 32-bit microprocessor in the x86 family. It allowed for
more powerful operating systems (like Windows/NT and Unix) to run, making it a key part of
the personal computer and workstation market.
Architecture: 32-bit processor with an integrated math coprocessor, improving performance for
complex mathematical calculations.
Performance Improvements: The 80486 introduced a pipeline for instruction execution,
increasing overall performance. It also featured an on-chip cache, which helped speed up
memory access times.
Significance: The 80486 was widely used in personal computers and workstations, providing
higher processing speeds and better handling of multitasking. It also introduced the use of
integrated cache memory, which is a standard feature in modern processors.
Architecture: 64-bit internal architecture with dual pipelines (superscalar architecture), allowing
it to process multiple instructions simultaneously.
Features: The Pentium introduced features like MMX (Multimedia Extensions) for handling
multimedia applications and branch prediction for improved performance.
Significance: The Pentium was a significant milestone, as it was the first widely marketed
superscalar processor in the x86 family, meaning it could execute more than one instruction per
clock cycle. It was popular in both personal computers and workstations, supporting the rise of
multimedia and graphics applications.
Architecture: Similar to the Pentium but aimed at the high-performance market, with more
advanced features such as dynamic execution, out-of-order execution, and larger L2 cache.
Significance: The Pentium Pro was targeted at servers and high-end workstations, providing
better performance and efficiency. It introduced concepts like out-of-order execution that
would become common in future processors.
Architecture: Enhanced the Pentium with the introduction of the MMX technology for
multimedia applications, including faster video processing and 3D rendering.
Significance: The MMX extensions were designed to speed up multimedia and signal processing
tasks, including video and audio processing, making the Pentium MMX suitable for media-
intensive applications.
9. Pentium II, Pentium III, and Pentium 4 (1997–2004)
Architecture: These processors continued to evolve, with new features like SSE (Streaming
SIMD Extensions) for multimedia processing, hyper-threading (for simultaneous multi-threading
in later models), and improved clock speeds.
Significance: The Pentium II, III, and 4 processors were key to Intel’s dominance in personal
computing during the late 1990s and early 2000s. They provided increasing levels of
performance and supported new technologies like faster bus speeds, larger caches, and more
advanced vector instructions.
Architecture: With the launch of the Core series, Intel shifted to a more efficient and power-
conscious architecture, introducing dual-core and multi-core processors to improve multitasking
and performance per watt. The architecture also supported new instruction sets like SSE2, SSE3,
SSE4, and AVX (Advanced Vector Extensions) for vector processing.
Significance: The Core series, including Core i3, i5, i7, and i9 processors, has been Intel's flagship
offering for desktops, laptops, and servers, offering much higher performance and energy
efficiency compared to earlier processors. It also introduced 64-bit processing as a standard.
Architecture: The latest Intel processors are based on a refined 64-bit architecture and built
using cutting-edge manufacturing processes (like 10nm and 7nm). These processors offer
multiple cores, simultaneous multi-threading (Hyper-Threading), and support for Intel Turbo
Boost, overclocking, AVX-512, and other advanced features.
Significance: These processors are widely used in modern workstations, servers, and high-end
consumer PCs. They deliver massive performance boosts for workloads such as gaming, content
creation, 3D rendering, and scientific computations.
The 8085, 8086, and 8088 are all microprocessors developed by Intel, each with distinct
architectural features, data paths, and application domains. Below is a detailed comparison of the
8085, 8086, and 8088 microprocessors based on various factors:
1. General Overview
8085:
o Introduced in 1976, the Intel 8085 is an 8-bit microprocessor.
o It is part of the 5th generation of microprocessors and is backward compatible with the
8080.
o Commonly used in embedded systems, control systems, and simple computing tasks.
8086:
8088:
o Also introduced in 1979, the Intel 8088 is a 16-bit microprocessor, similar to the 8086
but with an 8-bit external data bus.
o It has a 20-bit address bus (like the 8086), allowing it to access 1 MB of memory.
o It was widely used in the IBM PC and compatible systems due to its cost-effectiveness
and compatibility with 8-bit buses.
2. Data Bus
8085:
8086:
o 16-bit data bus: Can transfer 16 bits of data at a time, offering better performance
compared to the 8085.
8088:
o 8-bit data bus: Similar to the 8085, but it is still a 16-bit architecture internally, and its
external bus width is reduced to 8 bits, which affects its data transfer speed.
3. Address Bus
8085:
8088:
o 20-bit address bus: Can also address up to 1 MB of memory, like the 8086.
4. Clock Speed
8085:
8086:
8088:
o Typical clock speeds are similar to the 8086, usually around 5 MHz to 8 MHz.
5. Instruction Set
8085:
o The instruction set of the 8085 is smaller and simpler compared to the 8086 and 8088.
o It supports operations like arithmetic, logic, data transfer, control, and branching.
8086:
o The 8086 has a more complex and richer instruction set, supporting 16-bit operations.
o It includes additional instructions for handling 16-bit data and memory access.
8088:
o The instruction set is almost identical to the 8086, but the 8088 processes data in an 8-
bit manner externally due to its 8-bit external data bus.
o This reduces the throughput in certain applications compared to the 8086.
6. Registers
8085:
o It has 5 registers (B, C, D, E, H, L), a 16-bit stack pointer, and a program counter.
o It uses accumulator-based operations with 8-bit registers.
8086:
o It has 16-bit registers (AX, BX, CX, DX, SI, DI, BP, SP) and an accumulator and flag
registers for status and control.
o Uses segment registers for memory segmentation (CS, DS, SS, ES).
8088:
o The 8088 has the same register structure as the 8086 but works with an 8-bit external
data bus.
7. Memory Segmentation
8085:
o No segmentation: Memory is flat and accessed directly using the address bus.
8086:
8088:
o Similar to the 8086, the 8088 also supports memory segmentation with the same
structure of segment registers.
8086:
8088:
o Similar to the 8086, but due to the 8-bit external data bus, its performance is slightly
lower compared to the 8086.
8085:
o No multiplexing of address and data bus; it has separate lines for both.
8086:
o The 8086 uses multiplexed address and data buses. The same set of pins is used for
both address and data, requiring external latches to separate the address and data
phases.
8088:
o Like the 8086, the 8088 also uses multiplexed buses for address and data.
10. Applications
8085:
8086:
o Used in early personal computers, servers, and workstations.
o Its 16-bit architecture made it suitable for more demanding tasks and larger applications
compared to the 8085.
8088:
o Widely used in the IBM PC (and compatible systems) because of its cost-effective 8-bit
external data bus.
o Suitable for general-purpose personal computing and low-cost workstations.
8085:
o Lower cost due to its simpler architecture (8-bit) and reduced memory addressing
capabilities.
o Simpler to implement in smaller systems.
8086:
o Higher cost due to the more complex 16-bit architecture and additional features like
memory segmentation.
o Suitable for systems requiring more processing power.
8088:
o Moderate cost: It’s cheaper than the 8086 because of its 8-bit external data bus, making
it suitable for lower-cost applications.
o Balanced in terms of performance and cost.
An interrupt is a mechanism that temporarily halts the CPU's current execution to give attention
to an urgent task. There are two types of interrupts: hardware interrupts and software
interrupts.
Hardware Interrupt:
Definition: A hardware interrupt is an external signal generated by hardware devices (like
keyboards, printers, or timers) to get the CPU's attention.
Example: When a device like a keyboard needs input, it sends a signal to the CPU to interrupt its
current process and handle the input.
Software Interrupt:
Definition: A software interrupt is generated by the software program itself when the program
needs to invoke a specific routine or system call (e.g., for I/O operations or accessing OS
services).
Example: A program calling an operating system function for disk read/write uses a software
interrupt to invoke that system service.
Hardware Interrupts:
1. INTR (Interrupt Request): A general-purpose interrupt for any device requesting the CPU's
attention.
2. INTA (Interrupt Acknowledge): Sent by the 8086 to acknowledge the interrupt request.
3. TRAP: A non-maskable interrupt used for emergency situations, such as system failure or
hardware malfunction.
4. RST 7.5, RST 6.5, RST 5.5: These are specific hardware interrupt lines with higher priority for
real-time responses.
5. NMI (Non-Maskable Interrupt): An interrupt that cannot be masked and is typically used for
critical errors, like hardware failures.
Software Interrupts:
1. INT n: The INT instruction is used to trigger software interrupts. n is the interrupt number that
determines which interrupt service routine (ISR) to invoke.
2. INTO (Interrupt on Overflow): A software interrupt triggered when an overflow condition
occurs.
3. INT 21h: A common interrupt for accessing DOS services in early Intel-based PCs.
Directives in assembly language are special instructions that provide the assembler with
information on how to process the program. They don't generate machine code but control the
assembly process.
Types of Directives:
1.
2.
3.
Segment Directives:
4.
5.
Control Directives:
6.
Purpose of Directives:
Definition: In immediate operand instructions, the operand (data value) is explicitly given in the
instruction itself.
Example: MOV A, 5 (The value 5 is directly moved to the accumulator).
Key Difference:
a) Pass by Value:
Description: In this method, the actual value of the argument is copied to the function. The
function cannot modify the original value.
Example:
b) Pass by Reference:
Description: In this method, the memory address (reference) of the argument is passed to the
function. The function can modify the original value.
Example:
c) Pass by Value-Returned:
Description: The function receives the value of the argument, and it can return a modified value
back to the caller. The original argument is not modified.
Example:
d) Pass by Name:
Description: This is a more complex method where the actual expression or variable name is
passed to the function. The function evaluates the expression or variable every time it is used.
Example: