Definición de compilación y compilador

Compiler definition and compiler

Compiler definition and compiler

Compilation it is a process of combining and translating something (source program) into another form. Compilation It is a technique of reading a program that is written in the source language and then translated into another language, called the target language.

When going through the translation process, of course, the compiler will report any oddities or bugs it might find. The translation process performed by the compiler is called the compilation process (compilation).

Compiler is a program that reads a program written in a source language (source language) and translates it into a target language. The compilation process is divided into two large groups: 1. Analysis p>

Source programs are divided and formed in intermediate forms

Representation) In general, the process in the analyst phase consists of three main parts namely* Lexical analyzer=> Read Cracker source program for Karaker Reference to the set of parameters in the source language. The resulting token is stored in the character symbol table, which does not follow the pattern. It is reported as unknown. p>

* Syntax parser=> Analysis of the compatibility of the token pattern with the rules specified in the source language (line)

* semantic analyzer=> Check the tabs and expressions for the specified limit values

Example: – The maximum length of the identifier is 8 characters – Unique expression 80 Cracker – Values ​​range from -32768 to 32767

2. Synthesis

Create the desired target programs from intermediate forms For the synthetic stage it consists of 3 main parts, namely

* Intermediate code generator=> Generate an intermediate code based on a parse tree, which is then translated when the translator relies on the syntax* Code optimizerOptimize (save space and calculation time) p>

* Code generatorGenerate code in high-level languages