Skip to content

Microprocessor Fundamentals

A microprocessor is a programmable VLSI/ULSI integrated circuit that implements the CPU functions: arithmetic and logic, control, registers and machine-instruction execution. External memory, I/O interfaces, clocking, reset and power circuitry are normally added to form a complete computer.

The preceding section develops CPU organization, registers and the instruction cycle. Here the emphasis is on the properties visible when selecting or programming a processor. A microprocessor accepts binary instructions and data, processes them under stored-program control and produces results and control signals.

CharacteristicMeaning and consequence
Word lengthNumber of bits naturally processed by the ALU and registers, commonly 8, 16, 32 or 64 bits. A longer word can represent a wider integer or address but may require more hardware and energy.
Clock speedClock cycles per second, measured in hertz. A higher frequency shortens a cycle, but does not by itself guarantee higher performance because instruction count, cycles per instruction, cache misses and pipeline stalls also matter.
Instruction setThe operations, data types, registers, instruction formats and addressing modes exposed to a programmer or compiler.
Address-bus widthWith nn independent address lines, at most 2n2^n addresses can be selected. The corresponding byte capacity is 2n2^n bytes only when each address denotes one byte.
Data-bus widthNumber of bits transferred in one bus transaction. A word wider than the external data bus may require several transfers.

Important microprocessor characteristics.

Do not equate word length, address width and data-bus width.: They may be equal in a simple processor, but they describe different properties and can have different numerical values.

An addressing mode tells the CPU where an operand is found or how its effective address (EA) is calculated. Let AA be an address field in the instruction, RR a selected register and M[x]M[x] the contents of memory at address xx.

ModeOperand or effective addressMain useExample
ImmediateOperand is the constant encoded in the instructionConstants; no extra operand-memory readMOV A, #05H
RegisterOperand is the contents of RRFast arithmetic on values already in the CPUADD A, B
DirectEA=A\mathrm{EA}=AFixed memory location or I/O registerLOAD R1, [2050H]
IndirectEA=R\mathrm{EA}=R or EA=M[A]\mathrm{EA}=M[A], according to the instruction setPointers and dynamically selected dataLOAD R1, [R2]
IndexedEA=A+Rindex\mathrm{EA}=A+R_{index}Arrays, tables and stringsLOAD R1, [TABLE+R2]

Common addressing modes.

Immediate and register modes do not need an effective memory address for the operand. Direct addressing needs one operand-memory access after instruction fetch; memory-indirect addressing may need an additional access to obtain the pointer. Exact syntax and whether an index is scaled by element size are instruction-set dependent.

Reduced Instruction Set Computer (RISC) designs emphasize a small, regular set of simple instructions, whereas Complex Instruction Set Computer (CISC) designs provide a larger set that may perform multi-step operations in one instruction.

FeatureRISC tendencyCISC tendency
Instruction setFewer, simpler and more regular instructionsMore numerous, specialized and complex instructions
Instruction formatOften fixed length with few formatsOften variable length with many formats
Memory accessUsually load/store: arithmetic uses registersInstructions may operate directly on memory
ExecutionMany instructions complete in one or a few cycles and pipeline regularlyComplex instructions may require several internal steps
Control hardwareSimpler hardwired decoding is commonMore complex decode; microprogrammed control is common historically
Code sizeMay need more simple instructionsA complex instruction may replace several simple ones
ExamplesARM and RISC-Vx86 family

Typical RISC–CISC comparison.

These are design tendencies, not absolute performance rules. A cache miss can make a RISC load take many cycles, and a modern CISC processor may decode a complex instruction into simple internal micro-operations. Performance must therefore be compared for a workload, not inferred from the acronym alone.

A microcontroller combines a CPU with program/data memory and peripherals such as timers, GPIO, serial interfaces and often ADCs on one chip. It is optimized for dedicated embedded control; a microprocessor is normally the CPU-centered choice for systems requiring large external memory and high general-purpose performance.

FeatureMicroprocessorMicrocontroller
On-chip integrationPrimarily CPU, cache and bus interfacesCPU, memory and I/O peripherals on one chip
External componentsMore external RAM, storage and controllers requiredFewer components required for a complete controller
Typical applicationPCs, workstations, servers and high-performance systemsAppliances, instruments, vehicles and embedded control
Cost and powerGenerally higher system cost and powerGenerally lower cost, power and board area
ExpansionLarge memory and rich external expansionLimited by on-chip resources, though external interfaces may be provided

Microprocessor versus microcontroller.

  • Microprocessor: CPU functions on a programmable chip; external memory and I/O complete the system.

  • Addressing mode: specifies an operand or computes its effective address; immediate, register, direct, indirect and indexed are the standard forms.

  • RISC: regular simple instructions and load/store organization; ARM and RISC-V are examples.

  • CISC: larger instruction repertoire and potentially multi-step instructions; x86 is the standard example.

  • Microcontroller: integrates CPU, memory and peripheral I/O for embedded control.