GATE 2006 Computer Science and Information Technology (CS) Questions with Solutions

GATE 2006

191 questions

MCQ 1911-mark 191

Questions 76–80 of 191

Q76Addressing Modes1 markMCQ−0.33 if wrong
Which of the following statements about relative addressing mode is FALSE?

Q77ALU Data Path and Control Unit1 markMCQ−0.33 if wrong
The data path shown in the figure computes the number of 1s in the 32-bit input word corresponding to an unsigned even integer stored in the shift register.
The unsigned counter, initially zero, is incremented if the most significant bit of the shift register is 1.

ShiftRegister k-bitCounter Output increment reset_counter load_output shift_left
The microprogram for the control is shown in the table below with missing control words for microinstructions I1,I2,…InI_1, I_2, \ldots I_n.
MicroinstructionReset CounterShift leftLoad outputBEGIN100I1???::::In???END001\begin{array}{|l|c|c|c|} \hline \textbf {Microinstruction} & \textbf{Reset Counter}& \textbf{Shift left} & \textbf{Load output} \\\hline \text{BEGIN} & \text{1} & \text{0} & \text{0} \\\hline \text{I1}& \text{$?$} & \text{$?$} & \text{$?$} \\\hline \text{:} & \text{:} & \text{:} & \text{:} \\\hline \text{In} & \text{$?$} & \text{$?$} & \text{$?$} \\\hline \text{END} & \text{0} & \text{0} & \text{1} \\\hline \end{array}
The counter width (k), the number of missing microinstructions (n), and the control word for microinstructions I1,I2,…InI_1, I_2, \ldots I_n are, respectively,

Q78Cache Memory1 markMCQ−0.33 if wrong
A computer system has a level-1 instruction cache (1-cache), a level-1 data cache (D-cache) and a level-2 cache (L2-cache) with the following specifications:
Capacity Mapping MethodBlock SizeI-Cache4K wordsDirect mapping4 wordsD-Cache4K words2 -way set associative mapping4 wordsL2-Cache64K words4-way set associative mapping16 words\begin{array}{|l|c|c|c|} \hline \text {} & \textbf{Capacity }& \textbf{Mapping Method} & \textbf{Block Size}\\\hline \text{$I$-Cache} & \text{$4K$ words}& \text{Direct mapping} & \text{$4$ words} \\\hline \text{$D$-Cache} & \text{$4K$ words}& \text{$2$ -way set associative mapping} & \text{$4$ words}\\\hline \text{$L2$-Cache} & \text{$64K$ words}& \text{$4$-way set associative mapping} & \text{$16$ words} \\\hline \end{array}
The length of the physical address of a word in the main memory is 30 bits. The capacity of the tag memory in the I-cache, D-cache and L2-cache is, respectively,

Q79Cache Memory1 markMCQ−0.33 if wrong
A cache line is 64 bytes. The main memory has latency 32 ns and bandwidth 1 GBytes/s. The time required to fetch the entire cache line from the main memory is:

Q80Cache Memory1 markMCQ−0.33 if wrong
A CPU has a 32 KB direct mapped cache with 128-byte block size. Suppose A is a twodimensional array of size 512x512 with elements that occupy 8-bytes each. Consider the following two C code segments, P1 and P2.
 P1:
for (i=0; i<512; i++) {
   for (j=0; j<512; j++) {
      x += A[i][j];
   }
}
P2:
for (i=0; i<512; i++) {
   for (j=0; j<512; j++) {
      x += A[j][i];
   }
}
P1 and P2 are executed independently with the same initial state, namely, the array A is not in the cache and i, j, x are in registers. Let the number of cache misses experienced by P1 be M1 and that for P2 be M2 .

The value of ratio M1M2\frac{M1}{M2} is: