1
Total bits = .
- We have bits:
- tag field: bits
- block field: bits
- offset field (word field): bits
title: Correct answers.2
Total bits =
- blocks
- Format of address:
- tag field: bits
- word field: bits
- Anywhere, as blocks can be placed in any location of the cache.
title: Correct answers.3
Total bits =
-
Memory size: words Block size: words Cache size: blocks Number of sets: sets
We have bits to work with:
- set field: bits
- word field: bits
- tag field: bits
4
-
Show main memory address format
We have bits to work with:
- word field: bits
- block field: bits
- tag field: bits
-
Compute hit ratio for a program that loops times from locations to in memory.
We know we have blocks in cache, and at least blocks in main memory.
Block and block will have a clash and both go to block (for pass 1).
Pass 2 will equal pass 3, 4, …
-
Compute the effective access time for this program.
title: TA working5
-
Direct-mapped cache
- Word field: bits
- Block field: bits
- Tag field: bits
-
Associative cache
- Word field: bits
- Tag field: bits
-
4-way set associative cache
- Set field: bits
- Word field: bits
- Tag field: bits
title: TA working6
In a direct-mapped cache, there is only one location we can write to so the victim block is already decided.
title: Correct answer.