Compiler Design Week 12 Nptel Assignment Answers
Are you looking for NPTEL Compiler Design Week 12 Nptel Assignment Answers ? You’ve come to the right place! Access the most accurate answers at Progiez.
Table of Contents

Compiler Design Week 12 Nptel Assignment Answers (Jan-Apr 2025)
Course Link: Click Here
1. Backpatching is needed to generate intermediate code using
a) Single pass
b) Two passes
c) Multiple passes
d) None of the other options
2. Jump table is suitable for
a) Small number of cases
b) Large number of cases
c) Any number of cases
d) None of the other options
3. If case values are widely spaced, it is better to use
a) Jump table
b) Table search
c) Either jump table or simple table
d) None of the other options
4. Function call actions are divided into sequences
a) Calling and return
b) Calling and composition
c) Return and composition
d) None of the other options
Compiler Design Week 12 Nptel Assignment Answers
5. Evaluation of actual parameters is done by
a) Callee
b) Caller
c) Both Caller and Callee
d) None of the other options
6. In a callee-save register convention, who is responsible for saving registers?
a) Caller
b) Callee
c) Both Caller and Callee
d) None of the above
7. Local storage is created by
a) Callee
b) Caller
c) Both Caller and Callee
d) None of the other options
8. For a switch statement, the expression can result into values in the range -5 to +6. Number of entries in the jumptable should be
a) 5
b) 6
c) 11
d) 12
9. For a switch statement implemented as a jumptable, default_case is
a) A part of jumptable
b) Not a part of jumptable
c) in the middle of the jumptable
d) at the beginning of the jumptable
10. For pair of goto based storage allocation for functions, the second goto statement transfers control to the beginning of
a) Storage space
b) Function code
c) Program
d) None of the other options
11. In a jump table-based switch statement, how is the index for the jump table calculated when the case values include negative numbers?
a) Using the case value directly as the index
b) By shifting all case values so that the smallest value maps to index 0
c) By skipping negative case values in the jump table
d) By using absolute values of case numbers
12. Which of the following occurs during the calling sequence of a function call?
a) Saving the return address and passing arguments
b) Restoring registers and returning control to the caller
c) Freeing allocated memory and clearing local variables
d) None of the above
Compiler Design Week 10 Nptel Assignment Answers (Jan-Apr 2025)
For answers to others Nptel courses, please refer to this link: NPTEL Assignment