Aspire's Library

A Place for Latest Exam wise Questions, Videos, Previous Year Papers,
Study Stuff for MCA Examinations - NIMCET

Previous Year Question (PYQs)



Which of the following statements are correct?

  1. The first three-address instruction in the intermediate code is a leader.
  2. The instruction which is exactly at the middle of the given three address code is a leader.
  3. Any instruction that is the target of a conditional or unconditional jump is a leader.
  4. Any instruction that immediately follows a conditional or unconditional jump is a leader.

Choose the correct answer from the options given below:






Solution

In compiler design, leaders are used to form basic blocks.

Rules for finding leaders:

  1. The first instruction of the intermediate code is always a leader.

So, statement $1$ is true.

  1. The middle instruction is not necessarily a leader.

So, statement $2$ is false.

  1. Any instruction which is the target of a conditional or unconditional jump is a leader.

So, statement $3$ is true.

  1. Any instruction immediately following a conditional or unconditional jump is also a leader.

So, statement $4$ is true.

Correct statements are:

$1,3,4$



Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More


Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More

Ask Your Question or Put Your Review.

loading...