Machine-translated by Google. Questions are authored in English.
Top

Discussion

Two values interfere in a register allocator when

  • A.they are assigned in the same basic block
  • B.they have the same type in the source program
  • C.one of them is used as an operand of the other
  • D.both are live at the same point in the program

Answer: D

Simultaneous liveness means they cannot share storage. Building the interference graph therefore depends on a liveness analysis over the flow graph. An inaccurate liveness result produces either wrong code or wasted registers.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.