Harbin Institute of Technology Li Zhijun operating system lecture notes-4. Operating system interface

Harbin Institute of Technology Li Zhijun operating system lecture notes-4. Operating system interface


From the perspective of upper-level applications, how to enter the operating system through the interface, so as to understand the working principle of the operating system, to expand the functions of the operating system and design system modules.

Interface

What is an interface? ——Starting from the socket (connecting two things, signal conversion, shielding details)

There are three main ways users use computers:

Insert picture description here
1. Command line: It is a bunch of programs that adds some important functions to make some important uses of the computer's hardware. (Function is more important)

Insert picture description here

The command is actually a program

The shell is an endless loop and never stops

2. Graphic button: The message loop calls the function of the system message (the yellow part in the figure below), and continuously takes out messages from the message queue. A message corresponds to a message processing function, which is the "message processing mechanism".

Insert picture description here
Operating system interface:

Insert picture description here
The interface of the operating system connects the operating system and the application program, and connects through the C language program.

The operating system interface is represented as a system call (system_call)

In a nutshell: the operating system is a function called by the system

The operating system interface is a standard provided by the operating system for upper-layer applications, so the same standard should be followed. In this way, different operating systems use the same interface standard, so that upper-layer applications can run on different operating systems.

How to find out which system calls the operating system has (POSIX standard):
Insert picture description here

Guess you like

Origin blog.csdn.net/m0_46772594/article/details/114257077