Showing posts with label gate. Show all posts
Showing posts with label gate. Show all posts

Sunday, February 12, 2012

GATE 2012 CS/IT Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download GATE 2012 CSE Question Paper.

Written by

GATE 2012 - CS/IT - Answer Key & Solutions


Please refer GATE 2012 CS/IT Official Answer Key for the official answer key published by IIT Madras.


GATE 2012 Answer Key & Solutions for Computer Science and Information Technology.

Download the GATE 2012 CS question paper here.

Key by ACE Engineering Academy
Key by Gate Forum
Key by Engineers Institute of India


GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html

GATE Previous Years Question Papers can be accessed @ http://www.codeblocks.info/p/gate-computer-sciencecs-previous.html

Information courtesy: IITB Gate 2013 Website.
Written by

Wednesday, February 8, 2012

GATE CS 2008 Questions 71-73 Solution

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html

Consider a machine with a 2-way set associative data cache of size 64 Kbytes and block size 16 bytes. The cache is managed using 32 bit virtual addresses and the page size is 4 Kbytes. A program to be run on this machine begins as follows:

double ARR [1024] [1024] ;
int i, j ;
/* Initialize array ARR to 0.0 * /
for (i= 0;i< 1024; i++)
  for (j= 0; j< 1024; j++)
    ARR[i] [j ]=0.0;

The size of double is 8 Bytes. Array ARR is located in memory starting at the beginning of virtual page 0xFF000 and stored in row major order. The cache is initially empty and no prefetching is done. The only data memory references made by the program are those to array ARR.

71. The total size of the tags in the cache directory is
(A) 32 Kbits (B) 34 Kbits (C) 64 Kbits (D) 68 Kbits

72. Which of the following array elements has the same cache index as ARR [0] [0]?
(A) ARR [0] [4] (B) ARR [4] [0] (C) ARR [0] [5] (D) ARR [5] [0]

73. The cache hit ratio for this initialization loop is
(A) 0% (B) 25% (C) 50% (D) 75%

Solutions:

Assumptions:
  1. Memory is word addressible.
  2. Since no information is given on the number of bytes constituting a word, we take 1 word = 1 Byte
71.  Answer: (D)


Cache Specification:
  • Cache size = 64 KB
  • Block size = 16 B
  • 2 - way set associative
Number of cache blocks = 64 KB/16 B = 4 K = 212 blocks
Number of words in a cache block = 16 B/1 B = 16 = 24 words
Number of sets in cache = 2^12 / 2 = 211 sets
Size of virtual address = 32 bits

Figure 1: Divisions of the address for cache use.

Blocks offset = 4 bits
Set index = 11 bits
=> Number of TAG bits = 32 - ( 11 + 4 ) = 17 bits

Size of TAGs in the cache directory = #cache blocks x #TAG bits = 212 * 17 = 22 * 210 * 17 = 68 Kbits



72. Answer (B)


Page Size = 4 KB
Number of elements that fit in a page = 4 KB/8 B = 29 elements
Number of elements in any row of the array = 1024 = 210 elements
Number of words in an array element = 8 B/1 B = 8 words.

Two main memory addresses will be mapped to the same cache set if they have the same bit pattern for the Set Index bits.

The address where array element ARR[0][0] is stored is 0xFF000 or 0x000FF000 since the address is a 32bit address[8*4]. The bits 4 - 14 in the address correspond to the Set Index from the calculation in Q 71.
0x000FF000 = 00000000000011111111000000000000 - (1)
0x00107000 = 00000000000100000111000000000000 - (2)

Addresses 0x000FF000 - 0x000FF00F have the same Set Index bits. There are sixteen addresses in this range each corresponding to one word. Since each array element takes up 8 words, this address range can store only two elements, ARR[0][0] & ARR[0][1]. So these two elements map to one of the 2 ways [each way is one cache block = 16 B] of some set k in the cache.

The next address for which the Set Index bits are the same is (2)
The number of addresses/words between these (1)&(2) = 2(11+4).
The number of array elements that can be stored in this address range = 215/8 = 212 = 22 * 210
=> 4 rows can be stored in this address range. So the last address, 0x00107000, will store ARR[4][0].
So the first element of every 4th row will map to the same cache set.


73. Answer (C)

Number of elements in the array ARR = 1024 * 1024
Size of an element of type double = 8 B
=> Number of elements that fit in a cache block = 16 B/8 B = 2 doubles or two array elements

The sequence of accesses generated by the for loop is

ARR[0][0], ARR[0][1], ARR[0][2], ... , ARR[0][1024], ARR[1][0], ARR[1][1], ARR[1][2], ... , ARR[1][1024], ... , ARR[1024][0], ARR[1024][1], ARR[1024][2], ... , ARR[1024][1024]

Initially, cache doesn't contain any array elements. The access for ARR[0][0] creates a cache miss which loads a block of data from main memory. Since two array elements can be accommodated in a cache block, ARR[0][1] is also brought into the cache. So the access for ARR[0][1] results in a cache hit. Again ARR[0][2] will be a cache miss which results in ARR[0][3] being a hit and so on.

Once the cache becomes full, existing cache blocks get replaced by the new blocks being brought into the cache, again with the same hit/miss pattern.

The cache access for half of the array elements will result in a miss and the other half will be a hit. So the cache hit ratio for the given initialization loop is 50%.

Written by

Wednesday, January 25, 2012

GATE 2010 CS/IT Answer Key


GATE 2010 - Answer Key
CS/IT : Computer Science & Information Technology

Written by

Tuesday, January 24, 2012

GATE 2011 CS/IT Answer Key

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html

GATE 2011 - Answer Key
CS/IT :  Computer Science & Information Technology


Written by

Monday, January 16, 2012

GATE - List of Organizing Institutes

The organizing institute for GATE 2012 is IIT Delhi.

Here is the list of organizing institutes for the previous GATE exams.

Year        Organizing Institute
--------------------------------
GATE 2012   IIT Delhi
GATE 2011   IIT Madras
GATE 2010   IIT Guwahati
GATE 2009   IIT Roorkee
GATE 2008   IISc Bangalore
GATE 2007   IIT Kanpur
GATE 2006   IIT Kharagpur
GATE 2005   IIT Bombay
GATE 2004   IIT Delhi
GATE 2003   IIT Madras
GATE 2002   IISc Banglore
GATE 2001   IIT Kanpur
GATE 2000   IIT Kharagpur
GATE 1999   IIT Bombay
GATE 1998   IIT Delhi
GATE 1997   IIT Madras
GATE 1996   IISc Banglore
GATE 1995   IIT Kanpur
GATE 1994   IIT Kharagpur
GATE 1993   IIT Bombay
GATE 1992   IIT Delhi
GATE 1991   IIT Madras
GATE 1990   IISc Banglore
GATE 1989   IIT Kanpur
GATE 1988   IIT Kharagpur
GATE 1987   IIT Bombay
GATE 1988   IIT Delhi
GATE 1987   IIT Madras
GATE 1986   IISc Banglore
--------------------------------

Written by

Thursday, November 10, 2011

GATE 2012 CS Syllabus

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html


GATE 2012 - SYLLABUS FOR COMPUTER SCIENCE AND INFORMATION TECHNOLOGY (CS)

Engineering Mathematics

Mathematical Logic:
Propositional Logic; First Order Logic.


Probability:
Conditional Probability; Mean, Median, Mode and Standard Deviation; Random Variables; Distributions; uniform, normal, exponential, Poisson, Binomial.


Set Theory & Algebra:
Sets; Relations; Functions; Groups; Partial Orders; Lattice; Boolean Algebra.


Combinatorics:
Permutations; Combinations; Counting; Summation; generating functions; recurrence relations; asymptotics.


Graph Theory:
Connectivity; spanning trees; Cut vertices & edges; covering; matching; independent sets; Colouring; Planarity; Isomorphism.


Linear Algebra:
Algebra of matrices, determinants, systems of linear equations, Eigen values and Eigen vectors.


Numerical Methods:
LU decomposition for systems of linear equations; numerical solutions of non-linear algebraic equations by Secant, Bisection and Newton-Raphson Methods; Numerical integration by trapezoidal and Simpson's rules.


Calculus:
Limit, Continuity & differentiability, Mean value Theorems, Theorems of integral calculus, evaluation of definite & improper integrals, Partial derivatives, Total derivatives, maxima & minima.

Computer Science and Information Technology

Digital Logic:
Logic functions, Minimization, Design and synthesis of combinational and sequential circuits; Number representation and computer arithmetic (fixed and floating point).


Computer Organization and Architecture:
Machine instructions and addressing modes, ALU and data-path, CPU control design, Memory interface, I/O interface (Interrupt and DMA mode), Instruction pipelining, Cache and main memory, Secondary storage.


Programming and Data Structures:
Programming in C; Functions, Recursion, Parameter passing, Scope, Binding; Abstract data types, Arrays, Stacks, Queues, Linked Lists, Trees, Binary search trees, Binary heaps.


Algorithms:
Analysis, Asymptotic notation, Notions of space and time complexity, Worst and average case analysis; Design: Greedy approach, Dynamic programming, Divide-and-conquer; Tree and graph traversals, Connected components, Spanning trees, Shortest paths; Hashing, Sorting, Searching. Asymptotic analysis (best, worst, average cases) of time and space, upper and lower bounds, Basic concepts of complexity classes  P, NP, NP-hard, NP-complete.


Theory of Computation:
Regular languages and finite automata, Context free languages and Push-down automata, Recursively enumerable sets and Turing machines, Undecidability.


Compiler Design:
Lexical analysis, Parsing, Syntax directed translation, Runtime environments, Intermediate and target code generation, Basics of code optimization.


Operating System:
Processes, Threads, Inter-process communication, Concurrency, Synchronization, Deadlock, CPU scheduling, Memory management and virtual memory, File systems, I/O systems, Protection and security.


Databases:
ER-model, Relational model (relational algebra, tuple calculus), Database design (integrity constraints, normal forms), Query languages (SQL), File structures (sequential files, indexing, B and B+ trees), Transactions and concurrency control.


Information Systems and Software Engineering:
information gathering, requirement and feasibility analysis, data flow diagrams, process specifications, input/output design, process life cycle, planning and managing the project, design, coding, testing, implementation, maintenance.


Computer Networks:
ISO/OSI stack, LAN technologies (Ethernet, Token ring), Flow and error control techniques, Routing algorithms, Congestion control, TCP/UDP and sockets, IP(v4), Application layer protocols (icmp, dns, smtp, pop, ftp, http); Basic concepts of hubs, switches, gateways, and routers. Network security  basic concepts of public key and private key cryptography, digital signature, firewalls.


Web technologies:
HTML, XML, basic concepts of client-server computing.


Download the syllabus as a single PDF file or separate files for Maths & CS Subjects.


GATE 2012 information page @ Indian Institute of Science.
Written by

Tuesday, October 11, 2011

GATE - 2011 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html


Download CS2011.pdf Written by

Monday, October 10, 2011

GATE - 2010 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2010.pdf Written by

GATE - 2009 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2009.pdf Written by

Sunday, October 9, 2011

GATE - 2008 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2008.pdf Written by

GATE - 2007 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2007.pdf Written by

GATE - 2006 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2006.pdf Written by

GATE - 2005 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2005.pdf Written by

Saturday, October 8, 2011

GATE - 2004 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2004.pdf Written by

GATE - 2003 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2003.pdf Written by

GATE - 2002 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2002.pdf Written by

GATE - 2001 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2001.pdf Written by

Friday, October 7, 2011

GATE - 2000 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS2000.pdf Written by

GATE - 1999 - Computer Science - Previous Question Paper

GATE 2013 Comprehensive Information Page @ http://www.codeblocks.info/2012/08/gate-2013.html



Download CS1999.pdf Written by