Machine-translated by Google. Questions are authored in English.
Top

Discussion

Which one of the following cannot be the input to the code generation process ?

  • A.Source program
  • B.Intermediate code
  • C.Assembly program
  • D.Machine code

Answer: D

The answer is Machine code.

Code generation is the final phase of a compiler: it takes the program in an earlier form and produces target code. Machine code is what comes out of the process, so it cannot be its input.

The code generator normally works on the intermediate code; the source program is what that intermediate code was made from and is the input to the translation as a whole; and an assembly program is translated into machine code by an assembler. Each can stand at the input side of code generation, while machine code never does.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.