Architecture II Flashcards
What are the 4 systems of memory?
- Primary (system) = registers, cache, main memory, virtual; directly accessible by CPU
- secondary (online) = spinning hard-drives; data must be transferred to main memory when needed
- Tertiary (near-line) = tape libraries, optical jukebox; can be bought online quickly
- offline = optical disk, flash drive, external HDD; disconnected and used for backup purposes or transportation
- as you go down the levels the cost and speed decreases but size increases
What is computer memory?
- temporary storage area that holds data and program instructions that CPU needs
- consists of many storage cells, each of which can store 1 bit
- each storage location holds one word (8-bit computers hold 8 bits in location, 16 bit ones store 16 bits)
- impractical to assign distinct addresses to individual bit locations therefore addresses refer to byte location
What is RAM?
- Primary memory
- set of memory chips made of millions of transistors and capacitors
- directly accessed by CPU
- read/write
- volatile
- holds data/application programs from input devices or storages
Difference between SRAM and DRAM
SRAM; -bits stored in transistors -fast, retains state -complex construction, expensive -used for registers, cache, buffers in I/O devices, RAM in embedded systems DRAM -bits stored as charge -slower, discharges after sometime -structural simplicity, cheaper -used for bulk of PC main memory, large memory units
SRAM and DRAM implementation
- SRAM = 3 bit words, 2 bit addresses, combines; decoder, registers and clock switch
- DRAM = uses capacitors, new electronic component, store charge, same addressing as other RAMS
Difference between SIMM and DIMM
SIMM -Single in line memory module -32 bit bus width DIMM -Dual in line memory module -64-bit bus width -predominant type of memory module in 2018
What is DDR?
- Type of DRAM
- transfers data on both rising and falling edges of clock signal
- various versions with each becoming faster, more efficient, increasing in capacity and lowering in power consumption
What is ECC RAM?
- error correcting ram
- used in applications where high confidence needed (in-memory databases, popular servers, government, financial etc)
- has extra chip on the DIMM which store extra copies or checksums of the data
- not commonly used as regular DRAM is good
What is Virtual memory
You know
What is ROM?
- persistent state (non-volatile)
- used to store firmware and BIOS
- can be written to (Morden ones)
- limited number of write/erase cycles
Types of ROM
- Mask ROM = contents programmed using photolithography by manufacturer
- Programmable ROM = empty of data when the chip is manufactured; programmed by user. Cannot be erased when programmed
- erasable ROM = like PROM but the chip can be removed from computer and program erased
- Electrically EPROM = like EPROM but electricity is used to erase and reprogram selected contents
- flash memory
What is the principle of locality?
- temporal locality = values tend to be accessed repeatedly at nearby times
- sequential locality = same sequences tend to be re-accessed in same orders
- spatial locality = values nearby in memory tend to be accessed together
- applies to both instructions and data
What are the levels of cache memory?
- L1 includes three different sections; instruction (Harvard) cache, data cache, translation lookaside buffer cache virtual memory page tables
- L2 is shared, also L3 is a thing
- cache nowadays is located on CPU
What is a cache line
- cache memory is made of cache lines
- block = copies of several contiguous words from memory
- tag = address or other ID describing which memory is copied in the block
- dirty bit = logging whether the block data is modified
What is hit/miss?
What is the victim?
- requested data is found/not found
- hit/miss rate = factor of time data is found/not found (max 1)
- hit time = time required to access requested data
- miss penalty = time required to process a miss
- cached data to be thrown out to make room for new data
What is hashing?
- hash function maps a big datum to a smaller one
- not usually possible to recover original from the hash data
3 types of hashing algorithms?
Direct = always read and or store address and block in the same place; easy fast and cheap, different values produce same hash Associative = store tag at any available line; can cache all the best addresses at once, cost/complexity of digital logic is high Hybrid = hash address to subset of lines in cache memory then use associative rules inside these subset
What is special about cache write?
- similar to reading from cache but victim cant just be thrown away, needs to be written to memory
- write through = copy to RAM and unset diary bit shortly after cache write (uses lots of bus bandwidth)
- write back = write the RAM only when victimised (slower at the time)
What is the layout of a disk drive?
- each surface is divided into a number of concentric tracks
- track has same width as head and a number of sectors
- adjacent sectors and tracks are separated by gaps
- data transferred to and from disk in sectors
- each sector has a unique address
- data is accessed in a random-access manner
What affects a disk drives performance?
- access time spit into; seek time (time it takes for arm to position over desired track) and rotational delay (time it takes for desired sector to position itself under head)
- transfer time = time it takes to read/write data
What is RAID
- redundant array of independent discs
- method to make hard discs more resilient to failure
- use multiple discs as redundant backup and or speed up
- various architectures including; RAID1 (simple backup of complete disc), RAID5 (file striping, allows access to many parts of files at the same time
What is I/O?
- any transfer of data to or from the CPU/memory combo is considered I/O
- if CPU is brain then I/O is nervous system
How do we ensure a node can send a message to another node
The node must
- announce who its for
- announce the type of message
- announce the data
- ensure the above signals don’t collide with signals being sent by other nodes
Advantages and disadvantages of the bus
- easy to add new devices
- low cost due to shared wires
- bottleneck; performance of the system limited by the bus
- performance limited by physical factors (wire length, number of connections)