1
GATE CSE 2006
MCQ (Single Correct Answer)
+2
-0.6
Consider the following C code segment.
for (i = 0; i < n; i++) 
  { 
      for (j=0; j < n; j++) 
      { 
          if (i%2) 
          { 
           x += (4*j + 5*i); 
           y += (7 + 4*j); 
          } 
       } 
  } 
Which one of the following is false?
A
The code contains loop invariant computation
B
There is scope of common sub-expression elimination in this code
C
There is scope of strength reduction in this code
D
There is scope of dead code elimination in this code
2
GATE CSE 2005
MCQ (Single Correct Answer)
+2
-0.6
Consider line number 3 of the following C - program.
int main ( ) {              /* Line 1 */ 
int I, N;                   /* Line 2 */ 
fro (I = 0, I < N, I++);    /* Line 3 */ 
} 
Identify the compiler's response about this line while creating the object-module
A
No compilation error
B
Only a lexical error
C
Only syntactic errors
D
Both lexical and syntactic errors
3
GATE CSE 2003
MCQ (Single Correct Answer)
+2
-0.6

Consider the syntax directed definition shown below.

GATE CSE 2003 Compiler Design - Code Generation and Optimization Question 10 English

Here, gen is a function that generates the output code, and newtemp is a function that returns the name of a new temporary variable on every call. Assume that ti's are the temporary variable names generated by newtemp. For the statement 'X : = Y + Z', the 3-address code sequence generated by this definition is

A
$$X = Y + Z$$
B
$${t_1} = Y + Z;X = {t_1}$$
C
$${t_1} = Y;{t_2} = {t_1} + Z;X = {t_2}$$
D
$${t_1} = Y;{t_2} = Z;\,{t_3} = {t_1} + {t_2};X = {t_3}$$
4
GATE CSE 2003
MCQ (Single Correct Answer)
+2
-0.6
Which of the following is NOT an advantage of using shared, dynamically linked libraries as opposed to using statically linked libraries?
A
Smaller sizes of executable files
B
Lesser overall page fault rate in the system
C
Faster program startup
D
Existing programs need not be re-linked to take advantage of newer versions of libraries
GATE CSE Subjects
Software Engineering
Web Technologies
EXAM MAP
Medical
NEET
Graduate Aptitude Test in Engineering
GATE CSEGATE ECEGATE EEGATE MEGATE CEGATE PIGATE IN
CBSE
Class 12