Consider the control flow graph shown in the figure. Which one of the…

GATE · 2026 · CS · Set 1 · Computer Science & IT

Consider the control flow graph shown in the figure.

image.png

Which one of the following options correctly lists the set of redundant expressions (common subexpressions) in the basic blocks B4 and B5? Note: All the variables are integers.

  1. A.

    B4: { 𝑏+𝑖 }

    B5: { 𝑐+𝑚 }

  2. B.

    B4: { 𝑔∗𝑘 }

    B5: { 𝑐+𝑚 }

  3. C.

    B4: { 𝑔∗𝑘, 𝑏+𝑖 }

    B5: { }

  4. D.

    B4: { 𝑔∗𝑘 }

    B5: { }

Attempted by 92 students.

Show answer

Correct answer: D

The worked solution is available to enrolled students.

Explore the full course: Iocl Engineers Officers Grade A Paper 2

Loading lesson…