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

Discussion

Alias analysis is described as conservative when it

  • A.ignores pointers entirely and considers only named variables
  • B.assumes that no two pointers ever refer to the same object
  • C.reports a possible alias whenever it cannot prove there is none
  • D.reports an alias only when it can prove one exists

Answer: C

Assuming distinctness without proof would produce wrong code. Reporting a possible alias costs an optimisation, which is the acceptable side on which to err. Type based rules let compilers rule out some aliases without any analysis.

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

Post your comment

Please log in or register to post a comment.