What is Loader?
A loader is a module that is the essential part of the operating system, that is responsible for loading the program from secondary memory to main memory and executing them.
- The main function of the loader is to locate the executable file inside the file system.
- The loader allocates memory to store the program and once the memory is allocated then it loads the program in that memory space.
- The loader is also responsible for resolving the external dependencies such as references, and system libraries mentioned inside the program.
- Loaders are responsible for ensuring the correct loading of the program inside the memory.
- There are two types of loading in the operating system, Static and Dynamic Loading.
Static and Dynamic Loader in Operating System
An Operating system is the critical component for managing the various memory resources in the computer system. One of the essential tasks of the operating system is to manage the executable programs or applications in the computer system. A program needs to be loaded into the memory for the purpose of execution. For the execution context, the loader comes into the picture.