Compiler Construction MCQ :Memory allocation-activation record, activation trees : Link2

Compiler Construction MCQ :Memory allocation-activation record, activation trees : Link2

Compiler Construction MCQ & Answers

       Are you worried about the answers to Compiler Construction questions :Memory allocation-activation record, activation trees? We have arranged the Show Answer button under the each question. Candidates can click on it to know the right option among the given alternatives. Furthermore, the applicants can check our web portal @ www.totalmcq.com to take part in more MCQ on various subject. Wish, the given information about the Compiler Construction MCQ will helpful to the advance and can learn the various types of questions and answers.


Q.1. Which of the following are storage allocation strategies ---------

A. Static allocation
B. Stack allocation
C. Heap allocation
D. all of the above.

Q.2. ------tree is used to depict the way control enters and leaves activations.

A. Activation                                                       B. Parse
C. Syntax                                                            D. None of the above

Q.3. In activation tree each node represent---------

A. Activation of main program                          B. Activation of a procedure
C. Both A and B                                                   D. None of the above

Q.4. In activation tree each root represent---------

A. Activation of main program                          B. Activation of a procedure
C. Both A and B                                                   D. None of the above

Q.5. The node for a is the parent of node for b if and only if--------

A. If lifetime of a occurs before lifetime of b
B. If control flows from activation of a to b
C. Both A and B
D. None of the above

Q.6. The node for a is to the left of node for b if and only if--------

A. If lifetime of a occurs before lifetime of b
B. If control flows from activation of a to b
C. Both A and B
D. None of the above.

Q.7. Flow of control in a program corresponds to which traversal of activation tree?

A. Depth first traversal                                               B. Breadth first traversal
C. Both A and B                                                           D. None of the above

Q.8.--------can be used to keep track of live procedure activations

A. Activation tree                                                         B. Activation node
C. Control stack                                                          D. None of the above.

Q.9. If the occurrence of name in procedure is in the scope of declaration within the procedure then it is said to be------

A. Local                                                                         B. Nonlocal
C. Global                                                                       D. None of the above

Q.10. Information needed by execution of a procedure is managed using a contiguous block of storage called-----

A. Activation record                                                     B. Frame
C. Both A and B                                                             D. Activation tree

Q.11. In activation record, optional control link points to------

A. Activation record of caller                                     B. Activation record of callee
C. Both A and B                                                            D. None of the above

Q.12. The field of actual parameter in activation record is used by which procedure-----------

A. Calling procedure                                                  B. Called procedure
C.Both A and B                                                            D. None of the above.

Q.13. Consider an assignment statement like a[i]:=a[j] then here a[i] represent------and a[j] represent-------

A. Value and storage location                                   B. Storage location and value
C. Value and value                                                      D. None of the above.

Q.14. In which allocation, names are bound to storage as program is compiled-----

A. Static                                                                         B. Heap
C. Stack                                                                         D. None of the above.

Q.15. Call by reference also called as----

A. Call-by-address                                                       B. Call-by-location
C. Both A and B                                                             D. None of the above