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

Discussion

Local optimisation is optimisation performed

  • A.on the source text before parsing has begun
  • B.within a single basic block at a time
  • C.across the whole of a single procedure at once
  • D.across every procedure in the whole program

Answer: B

Correct answer: within a single basic block at a time

A basic block is a straight-line run with one entry and one exit, so within it control flow is trivial and every statement executes exactly once in order. That makes local optimisation cheap and certain - no data flow analysis is needed - and correspondingly limited in what it can see.

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

Post your comment

Please log in or register to post a comment.