3
2.1 1. 4 (1 byte = 8 bit ; 16*8/32 = 4) 2. I,J 3. A[I][J] 2.2 1. Tag = address/16 Index = add%16 address tag index H/M 3 0 3 M 180 11 4 M 43 2 11 M 2 0 2 M 191 11 15 M 88 5 8 M 190 11 14 M 14 0 14 M 181 11 5 M 44 2 12 M 186 11 10 M 253 15 13 M

Computer Organization and Design CH6

  • Upload
    zach

  • View
    233

  • Download
    7

Embed Size (px)

DESCRIPTION

Solution for chapter 6

Citation preview

  • 2.1

    1. 4 (1 byte = 8 bit ; 16*8/32 = 4)

    2. I,J

    3. A[I][J]

    2.2

    1. Tag = address/16

    Index = add%16

    address tag index H/M

    3 0 3 M

    180 11 4 M

    43 2 11 M

    2 0 2 M

    191 11 15 M

    88 5 8 M

    190 11 14 M

    14 0 14 M

    181 11 5 M

    44 2 12 M

    186 11 10 M

    253 15 13 M

  • 2.4

    1. 8 (offset 32 byte = 8 word )

    2. 32

    3. 1+( 22/(8*32)) = 1.086

    4.

    M/M Block Address : Address DIV/32

    Tag : M.M Block Address DIV/32

    Index: M.M Block Address MOD/32

    Address M.M Block

    Address

    tag index Replace? Hit?

    0 0 0 0 N N

    4 0 0 0 N Y

    16 0 0 0 N Y

    132 4 0 4 N N

    232 7 0 7 N N

    160 5 0 5 N N

    1024 32 1 0 Y N

    30 0 0 0 N Y

    140 4 0 4 N Y

    3100 96 3 0 Y N

    180 5 0 5 N Y

    2180 68 2 4 Y N

    3

    5. 5 5/12 = 0.417

    6.

  • 2.6

    1. P1 : 1/0.66n = 1.52GHz P2 = 1.11GHz

    2. AMAT for P1 = 0.66 + (8%*70) = 6.26ns 6.26n/0.66n =9.48 cycles

    AMAT for P2 = 5.1ns 5.1n/0.9 = 5.67 cycles

    3. CPI for P1 = 1+1.36*0.08*70/0.66 = 12.54

    CPI for P2 = 1+1.36*0.06*70/0.9 = 7.36

    P2 faster

    4. AMAT = 0.66+0.08*5.62+0.08*0.95*70 = 6.43 ns

    Cycles = 6.43/0.66 = 9.74 worst

    5. CPI = 1+(1.36*0.08*5.62/0.66)+(1.36*0.08*0.95*70/0.66) = 12.89

    6.

    P1 AMAT 0.66 ns + 0.08 * 70 ns = 6.26 ns

    P2 AMAT 0.90 ns + 0.06 * (5.62 ns + 0.95 * 70 ns) = 5.23 ns

    For P1 to match P2s performance:

    5.23 = 0.66 ns + MR * 70 ns

    MR = 6.5%