Presentation is loading. Please wait.

Presentation is loading. Please wait.

Cristian Hill. 6.1 Mocking Mr. Rohol is fun Introduction The CPU performs most of the calculations on the PC The CPU is a single chip on the motherboard.

Similar presentations


Presentation on theme: "Cristian Hill. 6.1 Mocking Mr. Rohol is fun Introduction The CPU performs most of the calculations on the PC The CPU is a single chip on the motherboard."— Presentation transcript:

1 Cristian Hill

2 6.1

3 Mocking Mr. Rohol is fun

4 Introduction The CPU performs most of the calculations on the PC The CPU is a single chip on the motherboard The motherboard houses the CPU,RAM, cache, memory, and data bus as well as connectors to other I/O devices

5 The CPU Houses the… Control Unit (CU) Program Counter Instruction Register Memory Address Register (MAR) A decoder Arithmetic Logic Unit (ALU) Accumulator

6 Cache Decoder Program Counter Instruction Register (IR) Accumulator Control Unit (CU) Memory Address Register (MAR) Arithmetic Logic Unit (ALU) RAM ROM Memory (Address) Bus Data Bus

7 Memory RAM and ROM RAM is where current data and executing program instructions are stored. ROM Stores permanent operating system instructions Such as the boot code and other instructions required to operate the computer

8 RAM Has address and contents per each location The instructions and data are stored as contents Instructions are made of 2 parts, the opcode and the operand The contents are transferred into the CPU via the data and memory address bus RAM is a volatile storage area It needs power to maintain is state

9 ROM Information stored in ROM cannot be changed The boot code starts automatically when the computer starts Code that operates for each interrupt is stored the ROM in fixed positions

10 6.1.1/2

11 Cache Decoder Program Counter Instruction Register (IR) Accumulator Control Unit (CU) Memory Address Register (MAR) Arithmetic Logic Unit (ALU) RAM ROM Memory (Address) Bus Data Bus

12 The Control Unit Registers The Program Counter The Instructions Register The Memory Address Register

13 Program Counter Holds the address of the next instructions in the program sequence It is assumed to be the next instruction and is automatically incremented That is unless the executing instruction modifies the contents via a jump or branch instruction Automatic incrementing is a fundamental part of the design(architecture) of the chip

14 Instruction Register Holds the Opcode for the instruction that is about to be executed E.g. ADD, MULT, STORE

15 Memory Address Register And the Accumulator Memory Address Register Located in the CU Holds the operand of the data or the location to be written Accumulator: Located in the ALU Holds the ongoing total of any calculations

16 The Book Likes to Jump Around

17 The Instructions Stored as machine code (binary) Ready to be executed directly by the hadware Compilation converts source code into machine code, line by line

18 Machine Code Made of the opcode and the operand Can be writen in assembler language that uses a mnemonic system Operands can be refered to by normal variable type names 1:1 ratio between machine code and assembler

19

20 6.1.3

21 The Basics Interrupts are how the processor handles the demands of its processing time 2 types, hardware and software It is when the processor stops what it is doing to complete another request When detected current states of resisters are stored(PUSHED) onto a stack, the interrupt is executed, then processor returns to its prior state(POPPING)

22 Hardware Interrupts Linked to the physical architecture of the computer Allows the device to communicate and gain the attention of the processer when it wants to send or receive data Errors would be a good example of this Code to execute is stored in fixed positions starting from a fixed memory position

23 Software Interrupts Similar to hardware interrupts except condition that needs responding to is generated by the processor When an EVENT or EXCEPTION occurs that requires handling, software designed for it is executed An offset position is required to access the interrupt software

24 Retrieve code for interrupt B + O Load into processor and execute Interrupt Register Offset (O) Interrupt Base B Interrupt 1 Interrupt 3 Interrupt 2

25 6.1.4

26 The Fundamentals A bus is a set of parallel wires that allow bits to be transmitted over one of the single wires. Are ex/interally connected to the CPU and the I/O ports 2 main types within the CPU: Data Bus and Memory Bus

27 Data Bus Moves data within the processor Is internally located E.G. STO Y - the contents of the accumulator are shipped to the contents part of memory address Y…via the Data Bus

28 Memory Bus Moves memory addresses (the location) Used in tandem with a control bus to synchronize the activity of the CPU Each wire matches to an individual bit in the address or the contents of a memory location Bus determines the amount of memory that can be addressed E.G. 32-bit computer needs a 32 bits wide memory bus to enable all 2 32 memory addresses

29 The Role of Cache A speed up mechanism RAM memory made of faster than normal memory chips Stores the most recently accessed memory addresses and their contents CPU first looks to the Cache for addresses CPURAMCache

30 Updating Cache 2 main algorithms: write-back – only updates changes write-through – updates data in cache and main memory. Slower but safer.

31 Exercises!!! Describe the function of… the accumulator the instruction register the interrupt register the program counter

32 6.2

33 Record data by magnetizing the binary code on the surface of a disk. Data area is reusable Allows for both sequential and direct access file organization. Built with multiple platters which use both the top and bottom surfaces to read/write data. (Except for the top and bottom platter) Hard Disk

34

35 Disk is flexible and housed in a plastic case. Operates on the same principle of a hard disk. Has a single platter and is a convenient storage method. Advantages- Cheap, Reasonable capacity for text based storage Disadvantages- Slow access, limited storage, disk is easily damaged. Floppy Disk

36 Allows data to be read from CD-ROMs Data cannot be altered, only read by a laser beam shining on the surface. Binary bit pattern is encoded at the time of production (writing) by a stamping process. The plastic surface is stamped with pit areas and land areas Pit areas absorb more laser light. Land Areas reflect more light. Changes between pit to land or visa versa represent binary ones and zeros. Optical Disk Drive

37 Erasable optical disk that allows data to be read and written many times in a fashion much like the hard disk. Magneto-Optical Disks

38 RAID- Redundant Array of Independent Disks Allows large amounts of storage that can be quickly accessed. Provides a range of protective features. Data written to a RAID disk is spread across a set of disks. Improves performance by taking advantage of parallel access across many disks. RAID

39 Can be combined with disk mirroring which provides a fault tolerance feature. Disk mirroring- Data is written to multiple disks. Vital if the system needs continuous access. RAID

40 6.2.1

41 The Block size determines the # of bytes that are read and written in a single physical read or write operation on a hard disk. The Blocking Factor is usually more than one disk sector and is also known as cluster size. Blocking

42 A disk surface is divided into a # of circular tracks which are divided into sectors. Hard Disk Capacity is determined by the # of tracks per surface, # of sectors per track, and the # of bits or bytes per sector. Sectors

43 A floppy disk has a single platter with a top and bottom surface. A high density floppy has 160 tracks on 2 sides with 9 sectors per track and 512 bytes per sector. Capacity = # of surfaces X # of tracks X # sectors per track X bytes per sector Capacity = 2 surfaces X 160 tracks X 9 Sectors per track X 512 Bytes per sector =1,474,560 bytes Finding Capacity

44 Data can be stored around the tracks in the sectors. Direct access is possible by specifying the require track and sector. In this way data is retrieved without reference to other related data. This is in contrast to sequential access. Data stored downwards in cylinders can be retrieved using a parallel technique utilizing multiple read /write heads. Accessing Data

45 Data is read and written to a disk sector by the use of read and write heads that are located on an arm. The heads can be fixed or moveable. Fixed read/write arms can read many sectors at one time down the cylinder in a parallel operation. A moveable arm has one set of read/write heads which move across the surface of the disk. Read/Write Heads

46 6.2.2

47 Made of two components- Seek Time and Latency Time Seek Time - Occurs while the read/write arms seek the desired track Latency Time – Occurs as the head write arm waits for the desired sector on the track to spin around Disk Access Time

48 Access time can be specified as a relationship. Access time = track seek wait time + sector wait latency time Data on disks is accessed in times measured in terms of milliseconds. Slower than the processing speeds of CPUs. I/O is still slow and does not match the speed improvement of processors. Disk Access Time

49 Exercises Outline how a disk drive operates Outline the role of the disk drive heads Define the term disk sector Defint the term cylinder Define the term latency or rotational delay Define the term seek time How does seek time differ from access time Describe the access time to a hard disk with reference to the latency and seek times

50


Download ppt "Cristian Hill. 6.1 Mocking Mr. Rohol is fun Introduction The CPU performs most of the calculations on the PC The CPU is a single chip on the motherboard."

Similar presentations


Ads by Google