1 CE 454 Computer Architecture Lecture 6 Ahmed Ezzat The Digital Logic, Ch-3.3, 3.4,

Slides:



Advertisements
Similar presentations
Chapter 5 Internal Memory
Advertisements

Computer Organization and Architecture
Computer Science 210 Computer Organization Clocks and Memory Elements.
CPS3340 COMPUTER ARCHITECTURE Fall Semester, /23/2013 Lecture 7: Computer Clock & Memory Elements Instructor: Ashraf Yaseen DEPARTMENT OF MATH &
Module 12.  In Module 9, 10, 11, you have been introduced to examples of combinational logic circuits whereby the outputs are entirely dependent on the.
1 Lecture 20 Sequential Circuits: Latches. 2 Overview °Circuits require memory to store intermediate data °Sequential circuits use a periodic signal to.
DH2T 34 Computer Architecture 1 LO2 Lesson Two CPU and Buses.
ENGIN112 L30: Random Access Memory November 14, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 30 Random Access Memory (RAM)
Registers –Flip-flops are available in a variety of configurations. A simple one with two independent D flip-flops with clear and preset signals is illustrated.
Registers  Flip-flops are available in a variety of configurations. A simple one with two independent D flip-flops with clear and preset signals is illustrated.
University College Cork IRELAND Hardware Concepts An understanding of computer hardware is a vital prerequisite for the study of operating systems.
CS 151 Digital Systems Design Lecture 30 Random Access Memory (RAM)
TECH CH03 System Buses Computer Components Computer Function
I/O Subsystem Organization and Interfacing Cs 147 Peter Nguyen
Informationsteknologi Friday, October 19, 2007Computer Architecture I - Class 81 Today’s class Digital Logic.
COMPUTER ARCHITECTURE & OPERATIONS I Instructor: Hao Ji.
1 EE365 Read-only memories Static read/write memories Dynamic read/write memories.
Tanenbaum, Structured Computer Organization, Fifth Edition, (c) 2006 Pearson Education, Inc. All rights reserved The Digital Logic Level.
Fall 2007 L16: Memory Elements LECTURE 16: Clocks Sequential circuit design The basic memory element: a latch Flip Flops.
Basic Computer Organization CH-4 Richard Gomez 6/14/01 Computer Science Quote: John Von Neumann If people do not believe that mathematics is simple, it.
Sequential circuits part 2: implementation, analysis & design All illustrations  , Jones & Bartlett Publishers LLC, (
CS-334: Computer Architecture
Higher Computing Computer Systems S. McCrossan 1 Higher Grade Computing Studies 2. Computer Structure Computer Structure The traditional diagram of a computer...
Introduction to Computing: Lecture 4
CHAPTER 3 TOP LEVEL VIEW OF COMPUTER FUNCTION AND INTERCONNECTION
Top Level View of Computer Function and Interconnection.
Memory and Storage Dr. Rebhi S. Baraka
Chapter 3 Internal Memory. Objectives  To describe the types of memory used for the main memory  To discuss about errors and error corrections in the.
CPEN Digital System Design
SEQUENTIAL CIRCUITS Component Design and Use. Register with Parallel Load  Register: Group of Flip-Flops  Ex: D Flip-Flops  Holds a Word of Data 
EEE440 Computer Architecture
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Logic Circuits II.
ECEG-3202 Computer Architecture and Organization Chapter 3 Top Level View of Computer Function and Interconnection.
Dr Mohamed Menacer College of Computer Science and Engineering, Taibah University CE-321: Computer.
Semiconductor Memory Types
Synchronous Sequential Logic A digital system has combinational logic as well as sequential logic. The latter includes storage elements. feedback path.
Digital Circuits Introduction Memory information storage a collection of cells store binary information RAM – Random-Access Memory read operation.
1 KU College of Engineering Elec 204: Digital Systems Design Lecture 22 Memory Definitions Memory ─ A collection of storage cells together with the necessary.
07/11/2005 Register File Design and Memory Design Presentation E CSE : Introduction to Computer Architecture Slides by Gojko Babić.
CS151 Introduction to Digital Design Chapter 5: Sequential Circuits 5-1 : Sequential Circuit Definition 5-2: Latches 1Created by: Ms.Amany AlSaleh.
Chapter 3 System Buses.  Hardwired systems are inflexible  General purpose hardware can do different tasks, given correct control signals  Instead.
REGISTER TRANSFER LANGUAGE (RTL) INTRODUCTION TO REGISTER Registers1.
Memory Systems 3/17/ Memory Classes Main Memory Invariably comprises solid state semiconductor devices Interfaces directly with the three bus architecture.
CS 1410 Intro to Computer Tecnology Computer Hardware1.
3/19/  Differentiate the class of memory  List the type of main memory  Explain memory architecture and operation  Draw memory map  Design.
Computer Architecture Chapter (5): Internal Memory
Computer Architecture. Top level of Computer A top level of computer consists of CPU, memory, an I/O components, with one or more modules of each type.
Chapter 5 - Internal Memory 5.1 Semiconductor Main Memory 5.2 Error Correction 5.3 Advanced DRAM Organization.
William Stallings Computer Organization and Architecture 7th Edition
Memory Units Memories store data in units from one to eight bits. The most common unit is the byte, which by definition is 8 bits. Computer memories are.
Chapter 3 Top Level View of Computer Function and Interconnection
ECE Digital logic Lecture 16: Synchronous Sequential Logic
Chapter 11 Sequential Circuits.
William Stallings Computer Organization and Architecture 7th Edition
ECEG-3202 Computer Architecture and Organization
William Stallings Computer Organization and Architecture
Presentation transcript:

1 CE 454 Computer Architecture Lecture 6 Ahmed Ezzat The Digital Logic, Ch-3.3, 3.4,

CE 454Ahmed Ezzat 2 Outline Memory – Latches – Flip-Flops – Registers – Memory Organization – RAMs and ROMs CPU and Buses – CPU Chips – Computer Buses – Bus Width – Bus Clocking – Bus Arbitration – Drawing Conventions Reading Assignment: Ch 3.5, 3.6

CE 454Ahmed Ezzat 3 Memory So far we saw only memory-less digital functions But we need to store the program, the data and the intermediate values used by an application running on a processor We know from ISA that there are registers and memory – where does data in “ADD R4, R6” reside? – What are these R4, R6 “registers”? – how do they work? How are they constructed? – will explain using gates in a way similar to combinational logic

CE 454Ahmed Ezzat 4 Memory Are made from sequential circuits – But require feedback: new “state” = F(current state, inputs) Require timing to be taken into account – will assume non-zero gate delay – will introduce the concept of “clock” New state: a boolean function which depends on – inputs from  T earlier – state from  T earlier

CE 454Ahmed Ezzat 5 Memory: Set-Reset (SR) Latches A Set-Reset (SR) Latch – Q and Q’ are fed back as inputs making it sequential A bi-stable circuit that stores binary values – Q=1, Q=0 is a “1” state – Q=0, Q=1 is a “0” state Can only be in one of these states – output change requires S and R to be applied – if S=R=0 then Q remains unchanged — —

CE 454Ahmed Ezzat 6 Memory: Set-Reset (SR) Latches S=R=1 leads to an unstable state. The output Q may “oscillate” before settling down to either 1 or 0. if S=R=0 then Q remains unchanged

CE 454Ahmed Ezzat 7 Memory: Set-Reset (SR) Latches Summary SR inputs and the resulting state – SR = 10  Q=1, Q’=0 (“1” state) when SR goes to 00 state remains the same: Q=1, Q’=0 – SR = 01  Q=0, Q’=1 (“0” state) when SR goes to 00 state remains the same: Q=0, Q’=1 – SR = 00 then Q remains unchanged – SR = 11 is not allowed electronically unstable state... Can only be in a state such that – Q’ = NOT Q – output change requires either S=1 or R=1 to be applied Once input is removed the latch “remembers” – stays in the same state

CE 454Ahmed Ezzat 8 Memory: Set-Reset (SR) Latches Time Diagram In an SR latch output Q follows input changes Note the delay (lag) between input changes and output changes Q Q S R tt tt 2t2t 2t2t

CE 454Ahmed Ezzat 9 Memory: Set-Reset (SR) Latches Problems with SR Latches Combinational functions take time to settle – output may vary for a while before going to correct value If S,R change then Q will change – with many levels of gates the change propagates for a while may not “settle” in time We assume that  T is the delay of a NOR gate How long we need to wait for R or S to be stable at 1 so as – Q is stable at 0 – Q is stable at 1, respectively

CE 454Ahmed Ezzat 10 Memory: Set-Reset (SR) Latches Problems with SR Latches How to make sure changes to registers occur – when desired; once per cycle ! Modify the latch – incorporate a clock signal as one of the inputs Will design a computer with many latches How to make sure things happen when required? Consider a basic arithmetic operation – Take data from 2 registers – Run through the ALU – Store to another register – Need to make sure these three steps occur at the right time Solution: generate and distribute a special signal called clock – keeps time: acts as a conductor for an orchestra or a drummer in a band – To ensure change occur: when desired only once per clock cycle

CE 454Ahmed Ezzat 11 Memory: Clocked SR Latches Q only changes when the Clock is a 1. If Clock is 0, neither S or R reach the NOR gates.

CE 454Ahmed Ezzat 12 Memory: Clocked SR Latches Still We have Problems Undefined state (S=R=1) Latency of Inputs/clock – Inputs can change as long as clock is (still) high One half of the clock cycle – That’s too long A solution - The D-latch Then we can play with duty cycle to limit when high – percent of clock cycle that is “1” – generate a very narrow “1” clock pulse but it is hard, especially at 2 GigaHertz – “sample” input (D) only when clock is “1”

CE 454Ahmed Ezzat 13 Memory: Clocked D Latches Avoid S=R=1; only one input If D is a 1 when the clock becomes 1, the circuit will remember the value 1 (Q=1). If D is a 0 when the clock becomes 1, the circuit will remember the value 0 (Q=0).

CE 454Ahmed Ezzat 14 Memory: Clocked D Latches Narrow Clock Pulse (~5 nsec)

CE 454Ahmed Ezzat 15 Memory: Flip-Flop (Master/Slave) Q D C

CE 454Ahmed Ezzat 16 Memory: D Latches vs Flip-Flop (a): is a D latch whose state is loaded when clock is 1 (b): is a D latch whose state is loaded when clock is 0 (c): is a F/F change state on the rising edge of the clock pulse (d): is a F/F change state on the falling edge of the clock pulse Some latches and F/Fs provide also Q as output, and Set and Reset as additional inputs 

CE 454Ahmed Ezzat 17 Memory: Registers 8-Bit Register We can use 8 D Latches to create an 8 bit memory. We have 8 inputs that we want to store, all are written at the same time. All 8 latches use the same clock. clock  D Latch D0D0 D1D1 D3D3 D4D4 D5D5 D6D6 D2D2 D7D7 Q0Q0 Q1Q1 Q3Q3 Q4Q4 Q5Q5 Q6Q6 Q2Q2 Q7Q7

CE 454Ahmed Ezzat 18 Memory: Registers Register Notations Notationally registers are referred to as one unit instead of addressing each storage element individually. A Data_in[7:0] Data_out[7:0] Clock

CE 454Ahmed Ezzat 19 Memory: Memory Organization Random Access Memory (RAM) Access time – from address to data out Constant access time – independent of address – unlike tape or disk Semiconductor memory: – RAM – ROM Many bits on one IC Each bit is a “latch” Depending on type get – Static (SRAM) – Dynamic (DRAM) Speed Capacity Cost Speed, cost, size relationship:

CE 454Ahmed Ezzat 20 Memory: Memory Organization Logic diagram for 4 x 3 Memory 4 rows of clocked D latches, each is a 3 bits. 3 input data lines (I 0.. I 2 ) 2 input address lines (A 0, A 1 ) 3 output lines (Q 1.. Q 2 ) CS (clock) line RD (READ/Write) line OE (output enable) line For Read, input lines are not used. For Write, output lines are not used

CE 454Ahmed Ezzat 21 Memory: Memory Organization Noninverting Buffer A tri-state device: 0, 1, none Output equal input (short circuit), or none (open circuit) A side effect it functions as amplifier, I.e., in addition to its switching properties Inverting Buffer Sam as noninverting, with short circuit when control input is low (amplifier effect)

CE 454Ahmed Ezzat 22 Memory: Memory Chips Memory IC is typically organized as a cell matrix – NxN At each position is a single cell To get wider output - replicate the matrix – 128Mbx8b IC may have 8 blocks (individual NxN matrices) Memory is built out of multiple chips – 256MB DIMM may have Mx8b ICs Eight are read (written) at once delivering 64b of data

CE 454Ahmed Ezzat 23 Memory: RAMs and ROMs RAMs –Static – F/F –Dynamic – transistor + capacitor –Synchronous ROMs –PROM –EPROM –EEPROM –Flash EPROM – disk replacement potential

CE 454Ahmed Ezzat 24 CPU CHIPs and Buses: CPU Chips From an internal (to the computer system) point of view, I/O is functionally similar to memory There are two operations read/write I/O module may control more than one device. The interfaces to each external devices is referred to as port, and each port is given a unique address External data path for input output data with external devices I/O module may be able to send interrupt signals to the CPU

CE 454Ahmed Ezzat 25 CPU CHIPs and Buses: Computer Buses Memory to processor Processor to memory I/O to processor Processor to I/O I/O to and from Memory (DMA)

CE 454Ahmed Ezzat 26 CPU CHIPs and Buses: Computer Buses Data Exchange Memory to processor Processor to memory I/O to processor Processor to I/O I/O to and from Memory (DMA)

CE 454Ahmed Ezzat 27 CPU CHIPs and Buses: Computer Buses Binary 0 Binary 1 Leading edge Trailing edge Time gap Time Signal as a function of time All lines 0 Not all lines necessarily 0All lines 0 Group of lines Cause and effect dependency Clock Timing Diagram

CE 454Ahmed Ezzat 28 CPU CHIPs and Buses: Computer Buses Bus Types Dedicated – Physical: Connected to a subset of modules – Functional: Data bus, Address Bus Multiplexed: Time multiplexing Address Data Time

CE 454Ahmed Ezzat 29 CPU CHIPs and Buses: Computer Buses Bus Configuration

CE 454Ahmed Ezzat 30 CPU CHIPs and Buses: Bus Width Address lines – Increases over time Data lines – Decrease bus cycle (bus skew) – Increase data lines Multiplexed: to allow very wide buses

CE 454Ahmed Ezzat 31 CPU CHIPs and Buses: Bus Clocking Synchronous Buses

CE 454Ahmed Ezzat 32 CPU CHIPs and Buses: Bus Clocking Asynchronous Buses

CE 454Ahmed Ezzat 33 CPU CHIPs and Buses: Bus Arbitration One device is designated as master, which may initiate a data transfer with some other device (slave) More than one module (e.g. CPU and DMA controller ) may need control of the bus Only one module may control bus at one time Needs some form of arbitration l Centralised Arbitration  Single hardware device controlling bus access (Bus Controller or Arbiter)  May be a separate module or part of CPU or separate l Distributed Arbitration  Each module may claim the bus  Control logic on all modules

CE 454Ahmed Ezzat 34 CPU CHIPs and Buses: Bus Arbitration Centralized

CE 454Ahmed Ezzat 35 CPU CHIPs and Buses: Bus Arbitration Decentralized

CE 454Ahmed Ezzat 36 CPU CHIPs and Buses Drawing Conventions Thick lines are buses - multiple bits wide Dotted line is clock Dashed lines are control signals

CE 454Ahmed Ezzat 37

CE 454Ahmed Ezzat 38 PCI Bus Peripheral Component Interconnect Start development 1990 Became standard 1995 Used in: – Sun Workstations – Apple Macintosh – Wintel PCs – Compaq Alpha Server The same peripheral I/O cards may be plugged into many different computers