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

GATE 2013

80 questions

MCQ 801-mark 38 · 2-mark 42

Questions 21–25 of 80

Q21Memory Chip Design2 marksMCQ−0.67 if wrong
A RAM chip has a capacity of 1024 words of 8 bits each (1K x 8). The number of 2 x 4 decoders with enable line needed to construct a 16K x 16 RAM from 1K x 8 RAM is

Q22Cache Memory1 markMCQ−0.33 if wrong
In a k-way set associative cache, the cache is divided into v sets, each of which consists of k lines. The lines of a set are placed in sequence one after another. The lines in set s are sequenced before the lines in set (s+1). The main memory blocks are numbered 0 onwards. The main memory block numbered j must be mapped to any one of the cache lines from

Q23Secondary Storage2 marksMCQ−0.67 if wrong
Consider a hard disk with 16 recording surfaces (0-15) having 16384 cylinders (0-16383) and each cylinder contains 64 sectors (0-63). Data storage capacity in each sector is 512 bytes. Data are organized cylinder-wise and the addressing format is (cylinder no., surface no., sector no.). A file of size 42797 KB is stored in the disk and the starting disk location of the file is (1200, 9, 40). What is the cylinder number of the last sector of the file, if it is stored in a contiguous manner?

Q24Pipeline Processor2 marksMCQ−0.67 if wrong
Consider an instruction pipeline with five stages without any branch prediction: Fetch Instruction (FI), Decode Instruction (DI), Fetch Operand (FO), Execute Instruction (EI) and Write Operand (WO). The stage delays for FI, DI, FO, EI and WO are 5 ns, 7 ns, 10 ns, 8 ns and 6 ns, respectively. There are intermediate storage buffers after each stage and the delay of each buffer is 1 ns. A program consisting of 12 instructions I1, I2, I3,..., I12 is executed in this pipelined processor. Instruction I4 is the only branch instruction and its branch target is I9. If the branch is taken during the execution of this program, the time (in ns) needed to complete the program is

Q25Function2 marksMCQ−0.67 if wrong
What is the return value of f(p,p), if the value of p is initialized to 5 before the call? Note that the first parameter is passed by reference, whereas the second parameter is passed by value.
 int f (int &x, int c) {
  c = c - 1;
  if (c==0) return 1;
   x = x + 1;
return f(x,c) * x;
}