1. Home
  2. Computer Science MCQs
  3. Software Engineering
  4. In compiler design, which optimization technique moves…

Added 12 Sep 2025

In compiler design, which optimization technique moves computations outside loops?

  1. Constant folding
  2. Loop invariant code motion Correct answer
  3. Common subexpression elimination
  4. Dead code elimination

Correct answer

B. Loop invariant code motion

13 views

MCQSEXAM

Explanation

Loop invariant code motion identifies and moves computations that don't change within loops.

Reference

Asked in: GATE CS, UGC NET CS

https://www.geeksforgeeks.org/loop-invariant-code-motion/

Preparing for an exam?

Doubts & discussion

Not sure why the answer is B? Ask here and get an explanation.

Ask a doubt about this MCQ

Shown after review. No links please.

More Software Engineering MCQs

Practise all Software Engineering MCQs

Similar MCQs