Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Recent questions tagged code-optimization
0
votes
1
answer
1
compiler design tcompiler-design-timothy-g-griffin
6. Generate code for the following C program using any code generation algorithm. [3 Marks] main() { int x, a, b, c, d, e; x= a + b -( c + d ) * e }
6. Generate code for the following C program using any code generation algorithm. [3 Marks] main() { int x, a, b, c, d, e; ...
Ebrahim
150
views
Ebrahim
asked
Jan 31
Compiler Design
compiler-design
syntax-directed-translation
code-optimization
parsing
ullman
+
–
0
votes
0
answers
2
compiler-design-timothy-g-griffin
Find the FIRST and FOLLOW of the grammar to check whether it is LL (1) parser or not. N → AB | BA A → a | CAC B → b | CBC C → a | b
Find the FIRST and FOLLOW of the grammar to check whether it is LL (1) parser or not. N → AB | BA A → a | CAC B → b | CBC C → a | b
Ebrahim
109
views
Ebrahim
asked
Jan 11
Compiler Design
compiler-design
parsing
ullman
syntax-directed-translation
code-optimization
+
–
0
votes
0
answers
3
compiler-design-timothy-g-griffin
Please provide in detail solution step by step 5. Find the FIRST and FOLLOW of the grammar to check whether it is LL (1) parser or not. N → AB | BA A → a | CAC B → b | CBC C → a | b Please provid in detail solution step by step
Please provide in detail solution step by step 5. Find the FIRST and FOLLOW of the grammar to check whether it is LL (1) parser or not. N → AB | BA A → a | CAC...
Ebrahim
144
views
Ebrahim
asked
Jan 10
Compiler Design
compiler-design
syntax-directed-translation
parsing
code-optimization
+
–
0
votes
2
answers
4
Compiler Construction : Timothy G. Griffin
Please Answer this question in detail step by step: 3. Translate the arithmetic expression (a + b * c) + d + (a + b * c) − d + e into: a). Syntax tree, (please draw) b). DAG (Directed Acyclic Graph) representation, (please Draw) c). Three-Address Code representation.
Please Answer this question in detail step by step: 3. Translate the arithmetic expression (a + b * c) + d + (a + b * c) − d + e into: a). Syntax tree, (please dr...
Ebrahim
331
views
Ebrahim
asked
Dec 18, 2023
Compiler Design
compiler-design
syntax-directed-translation
code-optimization
+
–
0
votes
1
answer
5
Test Series
$\text{ Anyone please explain : }$
$\text{ Anyone please explain : }$
Rahhul A
297
views
Rahhul A
asked
Nov 13, 2023
Compiler Design
compiler-design
code-optimization
process-and-threads
threads
intermediate-code
+
–
0
votes
1
answer
6
Madeasy test Series
Please explain how 2?
Please explain how 2?
SKMAKM
332
views
SKMAKM
asked
Jul 29, 2022
Compiler Design
code-optimization
made-easy-test-series
+
–
0
votes
1
answer
7
Live Variable Analysis | Made Easy Full Syllabus Test
A variable v is live at a program point p if some path from p to program exit contains an r-value occurrence of v which is not preceded by an l-value occurrence of v . That is, the variable should be referenced before ... zero as from the exit point there are no such definitions, to begin with? This is the solution they have provided :
A variable v is live at a program point p if some path from p to program exit contains an r-value occurrence of v which is not preceded by an l-value occurrence of v . Th...
palashbehra5
1.2k
views
palashbehra5
asked
Jan 11, 2022
Compiler Design
compiler-design
made-easy-test-series
live-variable-analysis
code-optimization
+
–
0
votes
1
answer
8
Made Easy Test
How to approach such questions ?
How to approach such questions ?
Prasad Deshmukh
343
views
Prasad Deshmukh
asked
Dec 21, 2021
Compiler Design
compiler-design
code-optimization
made-easy-test-series
+
–
19
votes
2
answers
9
GATE CSE 2021 Set 2 | Question: 30
Consider the following $\text{ANSI C}$ code segment: z=x + 3 + y->f1 + y->f2; for (i = 0; i < 200; i = i + 2) { if (z > i) { p = p + x + 3; q = q + y->f1; } else { p = p + y->f2; q = q + x + 3; } ... $\textsf{y ->f2}$) in the optimized code, respectively, are: $403$ and $102$ $203$ and $2$ $303$ and $102$ $303$ and $2$
Consider the following $\text{ANSI C}$ code segment:z=x + 3 + y->f1 + y->f2; for (i = 0; i < 200; i = i + 2) { if (z i) { p = p + x + 3; q = q + y->f1;...
Arjun
9.8k
views
Arjun
asked
Feb 18, 2021
Compiler Design
gatecse-2021-set2
code-optimization
compiler-design
2-marks
+
–
12
votes
4
answers
10
GATE CSE 2021 Set 2 | Question: 38
For a statement $S$ in a program, in the context of liveness analysis, the following sets are defined: $\text{USE}(S)$ : the set of variables used in $S$ $\text{IN}(S)$ : the set of variables that are live at the entry of $S$ $\text{OUT}(S)$ : the set of variables ... S_2$) }\cup \text{ OUT ($S_2$)}$ $\text{OUT ($S_1$)} = \text{USE ($S_1$)} \cup \text{IN ($S_2$)}$
For a statement $S$ in a program, in the context of liveness analysis, the following sets are defined:$\text{USE}(S)$ : the set of variables used in $S$$\text{IN}(S)$ : t...
Arjun
6.8k
views
Arjun
asked
Feb 18, 2021
Compiler Design
gatecse-2021-set2
code-optimization
live-variable-analysis
compiler-design
2-marks
+
–
12
votes
4
answers
11
GATE CSE 2021 Set 1 | Question: 50
Consider the following $C$ code segment: a = b + c; e = a + 1; d = b + c; f = d + 1; g = e + f; In a compiler, this code segment is represented internally as a directed acyclic graph $\text{(DAG)}$. The number of nodes in the $\text{DAG}$ is _____________
Consider the following $C$ code segment:a = b + c; e = a + 1; d = b + c; f = d + 1; g = e + f;In a compiler, this code segment is represented internally as a directed acy...
Arjun
10.5k
views
Arjun
asked
Feb 18, 2021
Compiler Design
gatecse-2021-set1
compiler-design
code-optimization
directed-acyclic-graph
numerical-answers
2-marks
+
–
1
votes
1
answer
12
NIELIT Scientific Assistant A 2020 November: 50
Some code optimizations are carried out on the intermediate code because: they enhance the portability of the compiler to other target processors program analysis is more accurate on intermediate code than on machine code the ... cannot otherwise be used for optimization the information from the front end cannot otherwise be used for optimization
Some code optimizations are carried out on the intermediate code because:they enhance the portability of the compiler to other target processorsprogram analysis is more a...
gatecse
601
views
gatecse
asked
Dec 9, 2020
Compiler Design
nielit-sta-2020
compiler-design
code-optimization
normal
+
–
1
votes
1
answer
13
NIELIT Scientific Assistant A 2020 November: 53
Which of the following is not true for tree and graph? A tree is a graph A graph is a tree Tree can have a cycle Tree is a $\text{DAG}$
Which of the following is not true for tree and graph?A tree is a graphA graph is a treeTree can have a cycleTree is a $\text{DAG}$
gatecse
447
views
gatecse
asked
Dec 9, 2020
Compiler Design
nielit-sta-2020
compiler-design
code-optimization
directed-acyclic-graph
+
–
1
votes
1
answer
14
NIELIT Scientific Assistant A 2020 November: 66
Peephole optimization is a : Loop optimization Local optimization Constant folding Data flow analysis
Peephole optimization is a :Loop optimizationLocal optimizationConstant foldingData flow analysis
gatecse
457
views
gatecse
asked
Dec 9, 2020
Compiler Design
nielit-sta-2020
compiler-design
code-optimization
+
–
2
votes
4
answers
15
NIELIT 2017 DEC Scientist B - Section B: 5
Which of the following is machine independent optimization? Loop optimization Redundancy Elimination Folding All of the option
Which of the following is machine independent optimization?Loop optimizationRedundancy EliminationFoldingAll of the option
admin
8.9k
views
admin
asked
Mar 30, 2020
Compiler Design
nielit2017dec-scientistb
compiler-design
code-optimization
+
–
1
votes
1
answer
16
NIELIT 2017 DEC Scientist B - Section B: 42
The optimization phase in a compiler generally Reduces the space of the code Optimizes the code to reduce execution time Both (A) and (B) Neither (A) nor (B)
The optimization phase in a compiler generallyReduces the space of the codeOptimizes the code to reduce execution timeBoth (A) and (B)Neither (A) nor (B)
admin
1.8k
views
admin
asked
Mar 30, 2020
Compiler Design
nielit2017dec-scientistb
compiler-design
code-optimization
+
–
1
votes
1
answer
17
UGC NET CSE | December 2006 | Part 2 | Question: 35
Peer-hole optimization is a form of : loop optimization local optimization constant folding data flow analysis
Peer-hole optimization is a form of :loop optimizationlocal optimizationconstant foldingdata flow analysis
go_editor
1.3k
views
go_editor
asked
Mar 27, 2020
Compiler Design
ugcnetcse-dec2006-paper2
compiler-design
code-optimization
+
–
3
votes
1
answer
18
ISRO2020-42
Which of the following is a type of a out-of-order execution, with the reordering done by a compiler loop unrolling dead code elimination strength reduction software pipelining
Which of the following is a type of a out-of-order execution, with the reordering done by a compilerloop unrollingdead code eliminationstrength reductionsoftware pipelini...
Satbir
2.9k
views
Satbir
asked
Jan 13, 2020
Compiler Design
isro-2020
compiler-design
code-optimization
normal
+
–
Page:
1
2
3
4
next »
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register