Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

In a pipelined processor, each TLB entry consists of 32 bits of data and 36 bits

ID: 3840181 • Letter: I

Question

In a pipelined processor, each TLB entry consists of 32 bits of data and 36 bits of tag. The page size used by the processor is 16 kB and the block size is 64 B. Each of the L1 caches consists of 32 kB of data and are 2-way set-associative; the L2 cache is 512 kB large and is 4-way set-associative; and, the L3 cache has 8 MB and is 8-way set-associative. All read/write caches employ write back and write allocate strategies. The clock frequency is 3 GHz. Accessing a block from L2 consumes 10 ns, from L3 takes 20 ns, and from main memory 30 ns.

a.Calculate the numbers of tag, index and offset bits in each cache.

b.Calculate the execution time of a program that involves completion of 3 millioninstructions,40% of which are load or store. The instruction cache has a hit rate of 99%,data cache 85%, L2 cache 70%,and L3 cache 50%.

Explanation / Answer

given :

Lenght of tag=36 bits.

Since block size of each cache is 64, offset remains same for L1,L2 and L3

offset =2^6

6 bits to represent offset field.

In cache L1:

32 KB of data,

As it is a 2 way set associative - 2*64 =168 bytes is the block size of L1;

therefore 32KB/128B=256B=2^8 ->8 bits for set

tag field=(36-(8+4))=24

For L2:

Lenght of offset=6

As it is for way set associative = 4*64=256 bytes

therefore 512KB/256B=2K=2^12->11 bits for set field

tag=(36-(6+11))=19

for L3:

Lenght of offset=6

Lenght of set field=8MB/512B=16KB=2^4*2^10=14 bits

tag=(36-6-14)=16

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote