1/34
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
CPU
central processing unit
The purpose of the CPU is to carry out the set of instructions given to the processor from a program
constantly process data and instructions in a fetch-decode-execute cycle
stored program concept
machine code instructions stored in main memory are fetched and executed serially by a processor
general purpose registers
additional registers in the CPU used for memory or data when needed, multipurpose, used for most instructions, used to hold results
specific purpose registers
used for certain instructions, specialised for specific task, hold status of a program
program counter
program counter holds the address of the next instruction to be executed; after content of PC is copied to MAR it is incremented by 1
MAR
Memory Address Register
holds address of current instruction
MDR
memory data register
holds data of the current instruction to be executed; memory buffer register
CIR
current instruction register
it recieves data from MDR; instructed and decoded and executed in this register
IX
index register
used in index addressing
used for loops, dumps, array index
status register
holds status of different processes, used by ALU to make decisions
control unit
brain of computer
maintain synchronisation of instructions w. the help of timing signals generated by system clock
decoding and execution of instructions
contains IAS, PC, CIR
ALU
arithmetic and logic unit
decision making is performed by this unit
contains accumulator register
memory unit
stores data permanently in secondary storage, fetches data from RAM towards CPU for execution
contains MAR and MDR
system clock
the system clock synchronises the entire fetch-execute cycle
overclocking
overclocking allows you to run your processor at higher clock speeds than originally intended
IAS/cache
Immediate Access Store, holds the data needed straightaway by the control unit
data bus
bidirectional bus
carries data/instructions
bus width is important as it defines amount of data a bus can carry
address bus
unidirectional
carries addresses
control bus
carries instructions to other components of computer
bidirectional
also used to carry timing signals
interrupts
signals generated from software or hardware to stop the process of processor for certain period of time
software interrupts
signal to the processor initiated by software
buffer is full
divide by zero
stack overflow
user input
hardware interrupt
printer out of paper
user presses key on keyboard
power failure
hardware failure
how interrupt is executed
at the end of FDE cycle, we check for interrupts
if interrupt has higher priority:
values of current instruction (PC along with other registers) are stored in STACK (memory)
load interrupt in the PC w. the help of ISR
interrupt is executed
check for further interrupts, if no interrupt, then previous instructions are loaded back to PC
assembly language
low-level programming language that communicates directly with the computer’s hardware. directly deals with registers; execution is faster
addressing modes
how we (assembly language) accesses our own memory
opcode
represents a specific instruction for the processor to perform
operand
the value on which the instruction is performed
instruction list
set of instructions (opcode+operand) that a microprocessor can understand and execute
immediate addressing
no memory is involved
operand acts as a value that is copied to accumulator
direct addressing
operand holds an address, contents of given address copied to ACC
indirect addressing
content of given address acts as a second address, contents of second address is copied to ACC
index addressing
we create a new address by adding given address to the value stored in Index Register, contents of new address is copied to ACC
relative addressing
memory is related from base address
if base address is not given it is considered 0
base address is stored in a register called base register
macros
set of instructions that performs specific task, they are also called subroutines, they can be called multiple times, less chances of errors that are fully tested
directives
they are instructions for the assembler, they are not programming code, just provide info to the assembler (starting address, space for variable, external file included)