Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider a computer system with the following properties: Each word of memory holds the standard 1 byte (8 bits) of information. The computer architecture uses

Consider a computer system with the following properties:

  • Each word of memory holds the standard 1 byte (8 bits) of information.
  • The computer architecture uses 24 bits to specify memory addresses and 8 bits for the opcode.
  • The memory uses a single level cache, each cache line holds 512 bytes in the cache.
  • The total size of the cache is 1 MB.
  • The cache is a two-way set-associative cache.

Answer each of the following questions about the system:

1. What is the maximum memory size supported by this computer architecture?

2. How many cache sets are there in the cache?  (Hint: In a two-way set-associative cache, each set maps to 2 cache lines.  And you were given the total cache size, and the size of each line).

3. For a set associative cache, a memory reference is broken up into 3 fields as described by our text:

tag (s - (d+w))            set (d)                 word (w)

How long is each field?  Some hints: The number of bits needed to identify the set d depends on the number of sets there are (previous question).  The word size w is a function of how big a cache line is.  And finally, the total number of bits is the same as the memory address size in bits s, so the combination of all 3 fields has to add up to the number of bits in the memory address.

4.  Assume the cache is filled with the following data:


cache way 1cache way 2
Line NumberValid BitTagDataValid BitTagData
...





00...00011100...01...110...00...
...





00...01000110...01...000...10...
00...01001010...00...100...00...
...





In this table, ... represents a sequence of zero(s)

Given the following memory references, identify each of them as a cache hit (write H in the blank) or a cache miss (write M in the blank).

Hints: The valid bit indicates a cache entry that is not actually valid anymore for some reason (maybe cache invalidated because of write in other core/cache for example).  So if a reference resolves to a line that is not valid, it is still a miss.  Make sure you correctly identify the line and tag when determining a hit or miss here.

Reference 1

TagLineWord Offset
00...0000...010011100100

Reference 2

TagLineWord Offset
10...0000...010010110110

Reference 3

TagLineWord Offset
10...0100...000111110011

Reference 4

TagLineWord Offset
10...0000...000110110110

Reference 5

TagLineWord Offset
10...0100...010000100010

Step by Step Solution

3.45 Rating (152 Votes )

There are 3 Steps involved in it

Step: 1

Answer Step by step solution Step 1 The memory holds the standard 1 byte 8 bits of information Step ... blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Computer Networking A Top-Down Approach

Authors: James F. Kurose, Keith W. Ross

5th edition

136079679, 978-0136079675

More Books

Students also viewed these Computer Network questions

Question

describe the distinct effects of positive emotions;

Answered: 1 week ago