Fundamentals of Computer Organization and Architecture Flashcards
Fetch Execute Cycle
A continuous process carried out by the processor when running programs
Two Types of Main Memory
RAM - Random Access Memory
- Temporary Storage and is volatile
ROM - Read Only Memory
- Generally only used for storing a limited number of instructions eg BIOS settings. Non-volatile memory.
Buses
Data Bus - transfers data from the processor to and from memory, and to and from the I/O Controllers. The data bus is bi-directional/two way
Address Bus - Is used to specify a physical address in memory so that the data bus can access it. The address bus only goes in one direction - from the processor into the memory
Control Bus - Controls the flow of data between the processor and other parts of the computer. The control bus is bi-directional and sends control signals to registers, the data and address buses.
Von Neumann Architectures
How Von Neumann architecture simply works is the instructions and data that comprise a program are both stored in the main memory and must pass through the same bus (data bus) in and out of memory.
Most modern PC’s use this technique.
https://bit.ly/2t6C1Up
Harvard Architecture
The main difference is that separate buses are used for data instructions, both which address different parts of the memory.
https://bit.ly/2HQB5c2
The advantage of the Harvard architecture is that the instructions and data are handled more quickly as they do not share the same bus.
Harvard architecture is widely adopted on embedded computer systems such as mobile phones, burglar alarms etc where there is a specific use rather than being used within general purpose PCs.
Many such devices use a technique called Digital Signal Processing (DSP). The Idea of DSP is to take continuous real world data eg audio or video data, and then compress it to enable faster processing. Chips optimised for DSP generally have lower power requirements, making them ideal for applications eg mobile phones where power consumption is critical.
Control Unit
Part of the processor that manages the execution of instructions.
Register
A small section of temporary storage that is part of the processor. It stores data or control instructions during the fetch-decode-execute cycle
Status Register - Keeps track of the status of various parts of the computer - for example, if an overflow error has occurred during an arithmetic operation.
Interrupt register - Is a type of status register. It stored details of any signals that have been received by the processor from other components attached to it, for example, the I/O controller for the printer
There are four registers that are used by the processor as part of the fetch-execute cycle
The current Instruction Register (CIR) stores the instruction that is currently being executed by the processor
The program counter (PC) stored the memory location of the next instruction that will be needed by the processor
The Memory Buffer Register (MBR) also known as the Memory Data Register (MDR) holds the data that has just been read from or is about to be written to main memory
The memory address register (MAR) stored the memory location where data in the MBR is about to be written to or read from.
Fetch Decode Execute Cycle
Fetch
The address from PC is copied into MAR
Increment PC by one.
The address is then sent along the address bus to the main memory.
The contents of the address can now be transferred via the data bus into the MBR.
Transfer contents of MBR into CIR
Decode
The instruction in the CIR is now decoded by the decode unit
Execute
Factors affecting processor performance
Clock Speed - Indicates how fast each instruction will be executed.
Bus Width - The number of bits that can be sent down a bus in one go.
Word Length - Computer systems may have a word length of 32 or 64 bits indicating that 64 bits of data can be handled in one pulse of the clock. Word length and bus width are closely related in that a system with a 64-bit word length will need 64 bit buses
Multiple Cores
Cache memory - Caching is a technique where instructions and data that are needed frequently, are placed into a temporary area of memory that is separate from main memory. The advantage of this is that the cache can be accessed much more quickly than main memory, so programs run faster. The key to this is ensuring that the most commonly used functions or data used in a program are placed into the cache.
Interrupts
A signal sent by a device or program to the processor requesting its attention.
Since the fetch-decode-execute cycle is always in use, if an error was to occur or a device wants the computer to do something else then we need some way to grab the processor’s attention. The way to do this is to send an interrupt.
An interrupt is an additional step to the fetch-execute cycle. Now fetch, decode, execute and check for interrupt.
Interrupt service routine (ISR) - Calls the routine required to handle an interrupt.
To correct the interrupt, the processor places what it was currently doing onto a system stack, and using the ISR.
Priorities - A method for assigning importance to interrupts in order to process them in the right order.
Sometimes, the program that has interrupted the running of the processor is itself stopped by another interrupt. In this case, the processor will either place details of its current task onto a stack or it will assess the priority of the interrupts and decide which one needs to be serviced first. Assigning different interrupts to different priority levels means that the really important signals, such as a signal indicating that the power supply is able to be lost, get dealt with first.
Vectored Interrupt Mechanism
Details about how to deal with each interrupt are stored in a section of RAM. The start
address of each of these sequences of instructions is stored in a list so that, when an
interrupt occurs, the processor can use this list to find the code needed to deal with the
interrupt.
CMP r1, #10
10 - Addressing Mode - the way in which the operand is interpreted
CMP - Operation Code/opcode
r1 - Operands - A value or memory address that forms part of an assembly language instruction
CMP r1, #10 means compare the value in register 1 with the value of 10
CMP r1, #10 ‘comment’
Immediate and Direct addressing
Direct address - Using a direct address mode tells the CPU which address contains the data you want to access. So LDR r1, 100 would copy the data held in memory location 100 into register 1
Immediate address - Rather than loading the contents of a memory address, the immediate address method loads tha data directly. Therefore, the operand would have to be the actual number that you wish to use. A comand such as MOV r1, #10 would move the value 10 into register 1
Types of Operation Code
PG 284 probably already mention in exam though.
Charge Coupled Device (CCD)
In digital cameras, it is a sensor that records the amount of light received and convert it into a digital value.
Complementary Metal Oxide Semiconductor (CMOS) is an alternative technology that performs the same functions as a CCD.