1.2.2 Applications Generation - Program Creation (Translators) Flashcards
What is a translator?
A translator is a programming language processor that converts one computer language into another, usually source code to machine code
What is an assembler?
An assembler is the translator that converts a program written in assembly language to machine code.
What is a cross assembler?
A cross assembler can create code that runs on a different type of CPU to the one the assembler runs on.
What is a compiler?
Compilers translates a program written in source code into machine code. It stores this as an object file.
What is an interpreter?
An interpreter translates high-level language into machine code line by line, executing the machine code each time a line is translated.
What stages does a compiler go through to create the object file?
Lexical analysis - identifies the keywords and operators in the source code
Syntax analysis - checks that the program is written within the rules of the language
Code generation - produces the machine code to be as fast and memory efficient as possible.
What is the file that the machine code created by a compiler is stored in called?
An object file. A large program may contain many object files. These are combined using a linker.
What is a linker?
A linker is an application that combines object files and libraries to create an executable file.
What is assembly language?
Assembly language is a ‘middle ground’ between high-level and machine code. Commands are in the form of mnemonics.
When is assembly language most commonly used?
Assembly language is most often used when the program being created interacts very closely with hardware; device drivers are often written in assembly