$\require{cancel}$
Some Basic Computer Organization
- This is 1.2 - 1.4 of the book.
- Book definitions:
- A CPU is the central processing unit.
- This is the device we studied in Architecture.
- This is the device that executes instructions.
- A Processor is a chip that contains one or more CPUs
- A Core is the basic computational unit of a CPU.
- Multicore is a device that contains multiple cores.
- Multiprocessor is a device that contains multiple processors.
- Today most processors are multicore.
- But most computers are not multiprocessor.
- But the OS can make it look like
- A single core is actually multiple cores
- A multiprocessor and a multicore machine are the same.
- So we tend to get sloppy with these terms.
- It is probably easier to think in terms of a single core/CPU until we need to do otherwise.
- A bus is a communications device
- There are many different busses in a system.
- Inside a CPU is a bus that connects the components (pc, alu, cu, ir, mmu, registers).
- There may be one or more system busses that connect higher level components (keybord/mouse, monitor, memory, disks).
- This depends on the hardware.
- The devices mentioned above have a device controller
- This is the hardware interface to the device.
- It is connected to the bus.
- There is a defined protocol on how to interact with that device.
- For example (totally made up by me)
- Put a 32 bit address on the address line
- Put a 1 on the read line for 4ns
- 32 bits of data will be placed on the data line 5ns later.
- Place a 0 on the read line.
- These most likely have a primitive/simple cpu and a hard coded os!
- A device driver is a program that understands how to control a device.
- These are typically subroutines of the kernel.
- These provide the OS with a uniform interface to the devices.
- On unix/linux everything is a "file".
- Device drivers allow the OS to be extended to add new devices.
- The device driver may have to allow for complex/parallel devices
- The book gives the example of a USB hub, which might have multiple devices.
- So they may have to deal with parallel access and device synchronization.
- We discussed the memory hierarchy in Architecture.
- Figure 1.6 has a more detailed version of this.
- volatile memory is memory that is erased when the power is turned off
- non-volatile memory is not.
- Think hard drive, optical disk, tapes, ...
- But also ROM
- We can now discuss "computers"
- A single core general purpose computer is extremely rare.
- My exceedingly low cost phone has
- 2x2.2 GHz Cortex A76
- 6x2.0 GHz Cortex A55
- And a GPU (Mali-G57 MC2)
- This is a multiprocessor system.
- There are two basic types of multiprocessors
- Symmetric Multiprocessors (SMP)
- All processors share the same memory.
- See figure 1.8
- Generally most high level OSs support SMP
- (linux run top, press 1)
- Non Uniform memory access (NUMA)
- Each processor has its own memory.
- See figure 1.10
- The os needs to control memory access.
- A multiprocessor system is usually in a single "box".
- Connecting multiple "boxes" together forms a distributed system or a cluster
- This allows
- High availability
- Fault tolerance and recovery.
- High performance computing.
- The os can be as little as
- Individual OS on the computers.
- A program that does the communications, data movement and computations.
- Or a tightly coupled distributed OS that looks like a single interface.