Code Optimization Compiler Design

@T-Bone

This question paper focuses on the "Code Optimization" of Compiler Design. These Multiple Choice Questions (mcq) should be practiced to improve the Compiler Design skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

This question paper focuses on the "Code Optimization" of Compiler Design. These Multiple Choice Questions (mcq) should be practiced to improve the Compiler Design skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

Questions

1. Optimization can be categorized broadly into ____ types.

Mark the correct option

2. A fragment of code that resides in the loop and computes the same value at each iteration is called a?

Mark the correct option

3. A variable is called an _________ variable if its value is altered within the loop by a loop-invariant value.

Mark the correct option

4. Dead code plays no role in any program operation and therefore it can simply be eliminated.

Mark the correct option

5. Substitution of values for names whose values are constant, is done in

Mark the correct option

6. Peep-hole optimization is a form of

Mark the correct option

7. In analyzing the compilation of PL/I program, the term Machine independent optimization is assosiated with

Mark the correct option

8. Before generating intermediate code, the compiler can modify the intermediate code by address calculations and improving loops.

Mark the correct option

9. The compiler can make use of memory hierarchy and CPU registers.

Mark the correct option

10. A compiler for a high-level language that runs on one machine and produces code for a different machine is called

Mark the correct option

Index of Questions