CSEE 4823 Advanced Logic Design Handout: Lecture #9 10/4/16 Prof. - - PDF document

csee 4823 advanced logic design
SMART_READER_LITE
LIVE PREVIEW

CSEE 4823 Advanced Logic Design Handout: Lecture #9 10/4/16 Prof. - - PDF document

CSEE 4823 Advanced Logic Design Handout: Lecture #9 10/4/16 Prof. Steven M. Nowick nowick@cs.columbia.edu Department of Computer Science (and Elect. Eng.) Columbia University New York, NY, USA Ripple-Carry Adders (RCA] 1 Basic Building


slide-1
SLIDE 1

1

CSEE 4823 Advanced Logic Design Handout: Lecture #9

10/4/16

  • Prof. Steven M. Nowick

nowick@cs.columbia.edu

Department of Computer Science (and Elect. Eng.) Columbia University New York, NY, USA

Ripple-Carry Adders (RCA]

slide-2
SLIDE 2

2

#3

Basic Building Blocks: Half Adder (HA)

Purpose: add two 1-bit operands with no carry-in

xi yi si cout

xi yi si cout 0 0 0 0 0 1 1 0 1 0 1 0 1 1 0 1 Truth Table xi yi xi yi cout si cout = xi yi si = xi XOR yi #4

Basic Building Blocks: Full Adder (FA)

Purpose: add two 1-bit operands with carry-in

xi yi si cout

cin xi yi si cout 0 0 0 0 0 0 0 1 1 0 0 1 0 1 0 0 1 1 0 1 Truth Table xi yi xi yi cin si cout = xi yi + xi cin + yi cin = MAJORITY Function si = xi XOR yi XOR cin = ODD PARITY Function

cin

1 0 0 1 0 1 0 1 0 1 1 1 0 0 1 1 1 1 1 1 xi cin yi cin cout

slide-3
SLIDE 3

3

#5

Ripple-Carry Adder (RCA): 8-Bit Example

Purpose: add two N-bit operands

x0 y0 FA cin s0 x2 y2 FA s2 c2 x4 y4 FA s4 c4 x6 y6 FA s6 c6 x3 y3 FA s3 c3 x1 y1 FA s1 c1 x5 y5 FA s5 c5 x7 y7 FA s7 c7 cout X Y cin cout S

Top-level block view: Detailed structural view:

8 8 8

#6

Ripple-Carry Adder (RCA): Simulations

Example #1: best-case = no carry chain (all carries are 0)

x0 y0 FA cin s0 x2 y2 FA s2 c2 x4 y4 FA s4 c4 x6 y6 FA s6 c6 x3 y3 FA s3 c3 x1 y1 FA s1 c1 x5 y5 FA s5 c5 x7 y7 FA s7 c7 cout

Addition: 00110010 = 49 + 00000100 = 4 00110110 = 53

slide-4
SLIDE 4

4

#7

Ripple-Carry Adder (RCA): Simulations

Example #2: worst-case = longest carry chain (all carries are 1)

x0 y0 FA cin s0 x2 y2 FA s2 c2 x4 y4 FA s4 c4 x6 y6 FA s6 c6 x3 y3 FA s3 c3 x1 y1 FA s1 c1 x5 y5 FA s5 c5 x7 y7 FA s7 c7 cout

Addition: 00000001 = 1 + 11111111 = -1 (2s Complement Representation) 00000000 = 0