History between the operating system - multi-channel technology

The principle of multi-process - multi-channel technology

Operating System Introduction

The figure is the position where the operating system in the entire computer:

image-20181228060338147

Located between software applications and hardware devices, in essence, is a software,

(To provide an interface for programmers) by the system kernel (manages all hardware resources) and system interface consisting of

The operating system is running as a user-friendly operation of the computer software provided on hardware

Two central role of the operating system

1. shields the user from the complex and cumbersome hardware interface is provided for the application, to use a clear system interface

With these interfaces later programmers do not have to deal directly with the hardware

Example: Once you have an operating system that we can use Explorer to operate the data on the hard disk, and do not worry about, moving head ah, read and write data, etc.

2. The operating system will compete for the application of hardware resources into orderly use

Example: After all of the software micro-channel qq ah ah ah chicken are the common set of hardware devices assume three existing programs are using the printer, if not properly managed competition, a program may print half of the picture, another grabbed the printer program execution so the right to print the text half, resulting in two the task failed to complete the program, the operating system's task is to become of these disorderly orderly operation

The difference between the operating system and applications

The difference is not in the position, they are software, and operating system can be seen as a special software

1. The operating system are protected: the user can not be modified (such as application software qq do not belong to the operating system can easily uninstall)

2. Large: linux source code or widows are more than five million lines, this is just a kernel, not including user programs, such as GUI, libraries, and basic application software (such as windows Explorer, etc.), it is easy to reach this number of 10 or 20 times as much

3. Longevity: Due to the huge amount of operating system source code, written in a very time-consuming, and once completed, the operating system owner will not easily give up rewrite, the second is to improve based on the original, basically the windows95 / 98 / Me operating system to see a

OS development history:

Multi-channel technology found in third-generation operating system, in order to address the first two generations of operating systems and various problems arise, then what problem the previous two generations operating system has it? Take a look at the history of the operating system:

First computers (1940 ~ 1955): punch cards and vacuum

The first generation of background computer:

The first generation before man is to replace manpower with machinery to produce the first generation of computers is a mechanical computer age into the era of electronic signs, from Babbage failed until after World War II, the construction of digital computer little progress, World War II stimulated the explosive progress of the computer research.

john Atanasoff lowa State University professor and his student Clifford Berry built is believed to be the first digital computers can work. The machine uses 300 vacuum tubes. Around the same time, Konrad Zuse in Berlin built Z3 computer relay, a group of British 格兰布莱切 Lee Gardens Colossus was constructed in 1944, Howard Aiken at Harvard University built the Mark 1, William Mauchley the University of Pennsylvania and his students J.Presper Eckert built ENIAC. Some of these machines are binary, and some use vacuum tubes, some are programmable, but are very primitive, and even takes a few seconds to complete the simplest of operations.

During this period, the same team of engineers in the design, construction, programming, operation and maintenance of the same machine, all programming is a pure machine language, even worse, by tens of thousands of cables required to the basic functionality to control a machine connected to the plug-in circuit board. No programming language (assembler did not), the operating system is never heard. The more primitive process using the machine, see under 'work process'

Features:
no operating system concept
for all programming are direct manipulation of hardware

Work process:
programmer table on the wall of the machine an appointment for some time, and then took his programmer plug-in version to the engine room, will own plug-board computer in the street, within a few hours of his exclusive whole computer resources, behind a group of people had to wait (twenty thousand vacuum tubes there is often a case of being burned appearance).

Then came the punch cards, the program can be written on the card, and then read into the machine without the plug-in board

advantage:

Programmers exclusive resources in the entire period of application, you can instantly debug your program (a bug can be processed at once)

Disadvantages:

A waste of computer resources, a period of only one person.
Note: Only one program at a time in memory, cpu is called for execution, say the implementation of 10 programs, is serial

Second generation computer (1955 ~ 1965): transistors and batch systems

Second generation background computer:

At that time, computers are very expensive, consider themselves naturally want less waste when the machine approach. Commonly used method is a batch system.

Features:
design, production personnel, operators, programmers and maintenance personnel directly with a clear division of labor, is locked in a dedicated computer room air conditioning, run by a professional operator, which is the 'mainframe'.

With the operating system concept

With programming languages: FORTRAN or assembly language, written on paper, then perforation labeled cards, then the card cassette to enter the chamber, to the operator, then wait for a cup of coffee output interface

work process:

1036857-20170118153002781-1203239513

1036857-20170118153032921-860551349

The second generation of how to solve the problems of the first generation / disadvantages:
1. input save a bunch of people into a large wave input,
2. then sequentially calculated (this is a problem, but did not solve the second generation calculation)
3. The the output save a bunch of people into a large wave output

Modern operating system, formerly :( see figure)

Advantages: batch processing, saving time machine

Disadvantages: 1. A person is required to control the entire process, moved around the tape (two intermediate villain)

2. The calculation process is still the order of calculation - "Serial

Other procedures 3. original computer programmers exclusive for some time now to be a unified plan to work in a group, and wait for the results of the re-commissioning process requires equal batches are completed before they can operate (which greatly affected the development efficiency programs, not in time debugger)

Third generation computer (1965 ~ 1980): integrated circuit chips and multiprogramming

The third generation of computer generated background:

The early 1960s, most computer manufacturers have two completely incompatible product lines.

Is a word-oriented: large-scale scientific computers, such as IBM 7094, pictured above, is mainly used for scientific computing and engineering computing

The other one is character-oriented: commercial computer, such as the IBM 1401, pictured above, mainly for banks and insurance companies in the tape archive and print services

Development and maintenance of a completely different product is expensive, and the use of different users of different computers.

IBM's attempts to introduce system / 360 series to meet scientific computing and business computing, 360 and 1401 series of low-end machines rather, much stronger than the 7094 high-end machine functions, different performance of different selling prices

360 is the first use of a (small) chip (IC) mainstream models, compared with the second generation of computers using transistors, cost has been greatly improved. Descendants of these computers are still using large computer centers, which was the predecessor of servers now , these server processes the request of not less than one thousand times per second.

How to solve the problem of a second-generation computers:
a card room after being able to quickly get into the disk read operation from the card, then any time when the end of a job, a job operating system will be able to read from the tape, means into the vacant memory area of operation, such a technology called
simultaneous online operation of external devices: SPOOLING, while the technology for output. When using this technology, the machine is not in need IBM1401, the tape will not be moved around the (intermediate two villain no longer needed)

How to solve the problem of second-generation computer 2:

Third-generation computer operating system widely used in key technology second generation computer operating system is not: the multi-channel technology

cpu during the execution of a task, a hard disk if desired operation, the operation command transmission disk, once the command is issued, the robot arm slides on the hard disk data read into memory, this period of time, cpu wait time may be very short , but the cpu is already long, long, long enough to let the cpu do many other tasks, if we let the cpu switch during this time to do other tasks, such cpu does not take full advantage of it. Background This is the multi-channel technology generated

Multi-channel technology:

Multi-channel multi-channel technology means that multiple programs, multi-channel technology to solve multiple program competition or share the same resources (such as cpu) ordered scheduling problem solution that is multiplexed, multiplexing the multiplexed into multiplexed in time and space.

Multiplexing on the space : the memory is divided into several parts, each part into a program, so that, at the same time in memory there will be a multi-channel program.

1036857-20170313010137401-1096621807

Multiplexing in time : when a program while waiting for I / O, another program can use the cpu, memory can be stored if a sufficient number of jobs at the same time, the cpu utilization can be close to 100%, similar to our elementary school mathematics learn integrated approach . After the (operating system uses a multi-channel technology, you can control the switching process, or to execute permissions competition between the cpu process. This will not only be switched on when a process encounters io, a cpu time the process takes too long It will switch, or by the operating system away execute permission cpu's)

The biggest problem on the reuse of space: the memory must be split between programs, this division requires the hardware level achieved by the operating system. If the memory is not divided from each other, the program can access a memory of another program,

First is the loss of security, such as your qq program can access the operating system's memory, which means you can get all the permissions qq operating system.

Second is the loss of stability, it is possible when a program crashes the program but also to other memory recovered, say the operating system to reclaim the memory, the operating system crashes.

Multi-channel technical case:

Life in the process we will also do more than one task, but one person is essentially impossible to do simultaneously perform multiple tasks,

Example 1: eating and playing games, performed simultaneously, essentially switches between the two tasks, play games Chiyikoufan Then, while playing the game again Chiyikoufan;

Example 2: cooking and washing, if there is no multi-channel technology, when the rice cooker to cook, we can only wait, assuming that it takes five minutes rice washing, cooking takes 40 minutes, the equivalent of 40 minutes is a waste of time. It can do the laundry in the cooking of waiting, assuming that the clothes put into the washing machine takes five minutes, the laundry takes 40 minutes, then the total time of 5 (Wash rice) +5 (fitted dress) +40 (longest waiting time) greatly improved work efficiency

Multi-channel technology also switch between different tasks to perform, due to the switching speed of the computer is very fast, so the user does not have any feeling, it looks like two tasks are executed, but another problem is that not enough just to switch also needs to be saved before switching the current status, switch status restored back when these switches are saved and takes time! In the case that is due to the emergence of waiting for IO operations during the task it was to switch, but for some programs do not appear IO operation, the switch can not only improve efficiency, but will reduce the efficiency

For example: do one hundred multiplication problems and division problems do one hundred, two tasks are computing tasks do not need to wait, this time switching but reduces the operating efficiency!

Third-generation computer operating system is still the batch

Many first generation of computer programmers miss the exclusive, instantly debug your program. In order to meet programmers can quickly get a response, there has been time-sharing operating system

How to solve the problem of the second-generation computer 3:

Sharing operating system:
a plurality of multi-channel technology line terminals +

20 clients simultaneously loaded into memory, thinking, 17, in three runs, cpu on the use of multi-channel memory mode process in the three programs, since the instructions are generally short and few presented by the customer consumption duration, indexing computer provides fast interactive services for many users, all users are thought to yourself computer resources

CTTS: Massachusetts Institute of Technology (MIT) is developed on a modified 7094 machine off, CTSS compatible time-sharing system, after the third generation of widely used computer hardware must be protected (program memory between isolated from one another), time The system began to prevail

MIT, the Bell Labs and General Electric successfully developed in CTTS decided to develop MULTICS can simultaneously support hundreds of terminals (its designers focused on the construction of all the users in the Boston area to meet the computing needs of a machine), it is clear that they have to be on God, Finally his death.

Later MULTICS who participated in the development of Bell Labs computer scientist Ken Thompson developed a simple, single-user version of MULTICS, which is later UNIX systems . It is derived based on a number of other versions of Unix, in order for the program to run on any version of unix, proposed a unix the IEEE standard, POSIX (Portable Operating System Interface Portable Operating System Interface)

Later, in 1987, there has been a small clone of UNIX, that minix, for educational use. Finnish student Linus Torvalds wrote Linux on it

The fourth generation of computers (1980 - present): PC

The fourth generation is our common operating system, mostly with a graphical interface, such as: Windows, macOS, CentOS, etc.

As a result of IC design, computer volume decline in growth performance, and cost can be accepted and the average consumer, and most of the third-generation operating system requires professional learning to use, so the company began developing the kind of individual chiefs do not need professional learning can also quickly get started operating system, namely the above operating system!

They are using the GUI graphical user interface, the user need only click on the elements of the interface by dragging the mouse to complete most operations

Guess you like

Origin www.cnblogs.com/yangyuanhu/p/11112763.html