Skip to content
GATEiit

GATE CSE 2025 Session 1 Q13: Optimisation that uses live variable analysis

Question

Which ONE of the following techniques used in compiler code optimization uses live variable analysis?

Try it: multiple choice: exactly one correct option

Select one option
Wrong answer costs 1/3 mark in GATE.
Show answer and explanation

Answer: B (official GATE 2025 final answer key)

Concept used: Liveness tells which variables hold values still needed later, which drives register allocation.

First step: A register can be reused once the variable in it is dead, so register allocation needs to know where each variable is live.

Full step-by-step solution

Detailed working, common mistakes and linked mock tests will be available with a free GATEiit account. Log-in is coming soon.

Share this question

WhatsAppDownload image

Source: official GATE 2025 Session 1 CS question paper and final answer key, organised by IIT Roorkee. Question paper · Answer key