Can the computer directly recognize and execute programs written in assembly language
This article is about whether computers can directly recognize and execute programs written in assembly language. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
I can't. Programs written in assembly language cannot be directly recognized and executed by computers; assembly language source programs must be translated into machine language programs (that is, target programs) before they can be executed. When the target program is placed in a predetermined location in memory, it can be processed and executed by the CPU of the computer.
Assembly language (Assembly Language) is any low-level language used in computers, microprocessors, microcontrollers or other programmable devices, also known as symbolic language. In assembly language, mnemonics are used to replace the opcodes of machine instructions, and address symbols or labels are used to replace the address of instructions or operands.
Assembly language is similar in nature to machine language, but the symbolized machine language is still a machine-dependent language. Compared with machine language, assembly language has made considerable improvements in writing, modification and reading, but it is still far from high-level language.
A program written in assembly language cannot be directly recognized by the computer. The assembly language source program must be translated into a machine language program (called the object program) before it can be executed. In different devices, assembly language corresponds to different machine language instruction sets and is converted into machine instructions through the assembly process.
Advantages of assembly language:
As the second generation programming language on top of machine language, assembly language also has many advantages:
It can easily read the memory status and hardware I / O interface.
The code written can be executed accurately because it lacks a lot of compilation links.
As a low-level language, it has high extensibility.
Disadvantages of assembly language:
Because the code is very monotonous and there are few special instruction characters, it makes the code lengthy and difficult to write.
Because assembler still needs to call memory to store data, BUG is easy to appear and it is not easy to debug.
Even if a program is completed, it will take a lot of time to maintain it later.
The defect of poor code compatibility is caused by the particularity of the machine.
Thank you for reading! This is the end of the article on "can computers directly recognize and execute programs written in assembly language". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!