WHAT IS COMPILER?
I NEED 10 POINTS ON COMPILER..
IN JAVA
Answers
Hey mate!
I am here with your answer!
A cross compiler is a compiler capable of creating executable code for a platform other than the one on which the compiler is running. For example, a compiler that runs on a Windows 7 PC but generates code that runs on Android smartphone is a cross compiler.
Hope this will help you
Compiler
A compiler is a computer program which converts the High level programming language to Low level programming language or Machine language. The codes written in the High level programming language in a computer are turned into the Machine level programming language by compiler. A computer system cannot understand the high programming language, Hence it is necessary to convert the programming language to Low level programming or Machine level language.
A computer system can only understand the Machine level language and Binary codes. This language is in the form of Binary codes in the form of "0,1". A computer can understand only the language of binary code.
When a programmer simply writes a code or program in the text editor by using programming languages like C and Python. This files containing the code are called as "Source statement". When the code has to be executed, The compiler parses the High level programme to the low level programme, This process is also called as Parsing.
Each and every line passes through the compiler and after the execution of all lines, The output code is created in the form of Binary code. This output of the object is also called as 'Object module'. This object code is nothing but the Machine code that processor can process and execute it.
Later, The processed code is sent to the output unit. And this is how the code is executed and output is shown.
Programming languages like Java, C and C++ uses object oriented language. This helps the compiler to perform it's work with the help of bytecode in bits of seconds. Rather than it, some programming languages are very high level programming languages which don't use Object Oriented Programming language. This programming languages require more time to get executed. Examples of this programming languages can be given as Python and JavaScript.
Additionally, In some Operating systems like Mac and Linux, one more step is to be done before executing the code which is to "resolve the instructions locations and data" for executing the more code at same time.
A compiler contains 2 main parts. 3GL and Assembler. 3GL works with the compiler and High level programming languages. And Assembler works on the code written using assembler language by processor.