Intermediate Compilers & Programming Language Theory
Q70 / 100

What is the purpose of three-address code as an intermediate representation?

Correct! Well done.

Incorrect.

The correct answer is C) To express computations as a sequence of simple instructions with at most one operator and three operands (e.g., t1 = b + c), simplifying optimization and code generation

C

Correct Answer

To express computations as a sequence of simple instructions with at most one operator and three operands (e.g., t1 = b + c), simplifying optimization and code generation

Explanation

Three-address code (e.g., t1 = a * b; t2 = t1 + c) breaks complex expressions into uniform, simple steps. Its regular structure makes it easy to apply dataflow analyses, perform optimizations, and translate to target machine instructions.

Progress
70/100