Topics in CS(difference between compile and interpret)

Compile the Compile : the translation of the entire source code into another code, and then waiting to be executed, occurs before the run, the product is "another piece of code."
Interpretation Interpret : the source code line by line to read and then do, occur at run time, the product is' operating results. "

High-level language code High-Level Code

High-level language code, naturally refers to code by a high-level programming language, there is a higher level of abstraction of the details of the computer.
With respect to the low-level programming language (low-level programming language) is closer to natural language (human language).
Integrated set of automated tools (garbage collection, memory management, etc.), will extend the life of programmers, happier write more concise, more readable code.

Low-level language code Low-Level Code

Low-level language code, refer to code written by a low-level programming language, relatively high-level language, a little more abstract, closer assembly or machine instructions.
But it also means that poor portability of the code.

In my opinion, high and low, just a set of words only relative.
The more advanced language, performance, more freedom less low-level language.
But in the abstract, read and write, portability, better than the more low-level language.
In previous years, C / C ++ language relatively assembly language, machine instructions, this is definitely high-level language.
And today, we have more knowledge of the C language people tend to "low-level language."
Perhaps the future of the world of developers, we now see the familiar Java, PHP, Python, ECMAScript, etc., are explosive language of "low" to.

Assembly language Assembly Language

Assembler language as a low level language, corresponding to the computer or other programmable hardware.
And the machine instruction architecture of the computer it is a strong association.
In other words, different assembly language code corresponding to a specific hardware, so do not talk about the portability.
With respect to the high-level language code that needs to be compiled and interpreted, the assembly code only needs to be translated into machine code can be executed.
Therefore, assembly language is often referred to as symbolic machine code (symbolic machine code)

Byte Code bytecode

Bytecode strictly speaking not a programming language, but middle-level programming language code for a variety of needs (portability, transportability, precompiled, etc.) produced (Intermediate Code).
It is composed of the code by the instruction set of the pile, for example, after the compilation javac java byte code is generated by the source.
In the process of compiling the source code, is the need for "lexical analysis syntax analysis → → generate object code" and other processes, and in the process of pre-compiled to complete this part of the work to produce bytecode.
Then later handed over to the interpreter (here usually refers to a virtual machine programming language) to explain the implementation, eliminating the previous precompiled overhead.

Machine Code Machine Code

Is a set of machine code may be directly executed by the CPU instruction set,
each instruction represents a specific task, or is loaded, or the jump, calculating operation or the like also.
All programs can be executed directly in the CPU, it is a series of instructions so composed.
But seen as a machine code during compilation, the lowest level code, because the outer further down is handed over to the hardware to perform.
Of course, the machine code can also be edited, but it is difficult to understand human gestures exist, readability is very poor.

 Mark: Java is often called a compiled language, while Python is called an interpreted language

Reference:

1. Disclaimer: This article is the original article CSDN bloggers "NumX", and follow CC 4.0 BY-SA copyright agreement, reproduced, please attach the original source link and this statement.

Original link: https://blog.csdn.net/baidu_36316735/article/details/58148449

2.http://huang-jerryc.com/2016/11/20/do-you-konw-the-different-between-compiler-and-interpreter/

Guess you like

Origin www.cnblogs.com/xkeepgoing/p/11783618.html