A Language Processing System (Cont.)
The Assemble-Link-Execute Cycle
- Object file:
It is an intermediate representation of code generated by a compiler.
Object files contain compact, pre-parsed code, often called binaries, that can be linked with other object files to generate a final executable or code library.
- Link library:
A file contains subroutines that are already compiled into machine language.
- Listing file:
It is a copy of the program's source file with line numbers and translated machine code.
It summarizes the result of processing an input file.
- Map file:
It contains information about the program's code, data, and stack segments.
Linker
Linker collects code separately compiled or assembled in different object files into a file that is directly executable.
This process involves resolving references between the modules and fixing the relocation information used by the operating system kernel when loading the file into memory to run it.
Loader
It copies programs from a storage device to main memory, where they can be executed.
It can also replace virtual addresses with physical addresses.