Week 4: Memory, Stacks and Computing Architectures Flashcards
What do we call storing data onto the stack?
Pushing
What do we call recalling data off of the stack?
Popping
What are hardware stacks made up of?
Shift registers
What are the different types of memory?
ROM, RAM and flash memory.
What are the trade-offs using RAM vs ROM?
RAM is a form of read-and-write memory that can be accessed without rewriting it.
ROM is read-only memory and by default isn’t to be changed because it holds hardware info like the BIOS.
Stacks
A data structure used for efficiently storing and recalling data.
It uses the principle of first in last off (FILO)
What are the two common computing architectures?
Von Neumann
Harvard
Polling and interrupts are two methods for the ___ to ___
CPU
Switch between different tasks
What type of memory is used in USB thumbs drives? Why shouldn’t we rely on this for critical storage?
Flash memory.
Damages the insulators in the thumb drive to write to it, meaning that it has a limited lifespan of around 30k writes.
What are the differences between Von Neumann and Harvard computing architectures?
Von Neumann stores the data and control bits in the CPU, but are separated in the Harvard architecture.
Processing speeds of Harvard are greater with more security, but Von Neumann is more flexible and makes use of a stack, therefore multitasking.
What is cache memory and what’s its primary role?
Cache memory is storing frequently used memory nearby in high-speed memory locations.
This means that the CPU can locate and decrease the access times which in turn increase the processing speed of the system.
What are 4 common examples of an interrupt?
Keyboard/mouse, clock, network packets and ALU errors.
Interrupt
(Giving food to crying baby)
The response to a device seeking attention from the CPU. This is where a current task is pushed onto the stack for another to be worked on.
Continues until the task is completed, then the routine handler tells where to return to.
Where is the BIOS stored?
In the ROM
When booting the OS, where will the BIOS be stored?
It will be loaded onto the RAM because it’s faster and is able to randomly access the parts of the BIOS that it needs to boot the computer