Lecture 24: 12/3/2002CS170 Fall CS170 Computer Organization and Architecture I Ayman Abdel-Hamid Department of Computer Science Old Dominion University Lecture 24: 12/3/2002
CS170 Fall Outline Appendix B Example on Memory Elements More on Combinatorial Logic
Lecture 24: 12/3/2002CS170 Fall Example on Memory Elements Problem B.23 (See handout) Design a 3-bit counter using D latches and gates As exercise, try to solve B.24
Lecture 24: 12/3/2002CS170 Fall More on Combinatorial Logic 1/4 ROMread-only memory A set of locations that can be read The contents of these locations are fixed, usually at the time the ROM is created PROM, EPROM A set of input address lines (just as a PLA), say M of these.; there are 2 M addresses and these point to 2 M distinct words A set of output lines (just as a PLA) say N, giving a word of N bits Contrast a ROM and a PLA
Lecture 24: 12/3/2002CS170 Fall More on Combinatorial Logic 2/4 Don’t Cares Situations where we do not care what the value of some output is, either because another output is TRUE or because a subset of input combinations determines the values of the outputs. Two types of Don’t cares Output: don’t care about the value of an output for some input combination (appear as X in the output portion of truth table) Input: Output depends on only some of the inputs (appear as X in the input portion of the truth table)
Lecture 24: 12/3/2002CS170 Fall More on Combinatorial Logic 3/4 InputsOutputs ABCDEF If A or C is true, output D is true, whatever the value of B If A or B is true, output E is true, whatever value of C Output F is true if exactly one of the inputs is true. We don’t care about the value of F, whenever D and E are both true. Truth table without don’t cares InputsOutputs ABCDEF X 10011X 10111X 11011X 11111X Truth table with output don’t cares InputsOutputs ABCDEF X1111X 1XX11X Simplified truth table Input/Output don’t cares
Lecture 24: 12/3/2002CS170 Fall More on Combinatorial Logic 4/4 If A or C is true, output D is true, whatever the value of B If A or B is true, output E is true, whatever value of C Output F is true if exactly one of the inputs is true. We don’t care about the value of F, whenever D and E are both true. Truth table without don’t cares InputsOutputs ABCDEF X 10011X 10111X 11011X 11111X Truth table with output don’t cares InputsOutputs ABCDEF X1111X 1XX11X Simplified truth table Input/Output don’t cares How many product terms for original truth table? How many product terms for simplified truth table?