COMPUTER SCIENCE AND ENGINEERING
COMPILER DESIGN
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
Code optimization
|
|
Code generation
|
|
Intermediate code generation
|
|
Syntax analyzer
|
Detailed explanation-1: -Code generation is the final phase in a compiler. Given a code in intermediate form, it uses code generation algorithm and register allocation strategies to generate the final target code.
Detailed explanation-2: -Code generation is the final stage of the compilation process. It takes the optimized intermediate code as input and maps it to the target machine language. Code generator translates the intermediate code into the machine code of the specified computer.
Detailed explanation-3: -Code generation follows the stages of lexical analysis, syntax analysis, and semantic analysis.
Detailed explanation-4: -In computing, code generation is part of the process chain of a compiler and converts intermediate representation of source code into a form (e.g., machine code) that can be readily executed by the target system. Sophisticated compilers typically perform multiple passes over various intermediate forms.