Question 91
What is the function of an 'Access Link' (Static Link) inside a function's Activation Record?
Access links (static links) traverse nested scopes to access non-local variables declared in lexically outer functions.
What is the function of an 'Access Link' (Static Link) inside a function's Activation Record?
Access links (static links) traverse nested scopes to access non-local variables declared in lexically outer functions.
What is the function of a 'Control Link' (Dynamic Link) inside an Activation Record?
Control links (dynamic links) maintain call stack invocation history, pointing directly back to caller's frame.
In Peephole Optimization, which local code transformations are commonly performed on short instruction windows?
Peephole optimization inspects sliding target code windows to remove redundant loads/stores, eliminate jump-over dead code, and apply algebraic simplifications. All options (A, B, C) are correct!
What is 'Code Hoisting' in compiler optimization?
Code hoisting reduces code size by identifying identical expressions computed in all successor paths and hoisting them into the parent node.
Which of the following are major components of target code generation that contribute to producing efficient machine code?
Instruction selection chooses target instructions, register allocation maps values to registers or spill locations, and instruction scheduling orders instructions to improve execution; all three contribute to efficient target code.