Two types of multitasking

Source: Internet
Author: User

There are two types of multitasking:

1. Process-based

Process refers to a "self-containment" of the running program, directly managed by the operating system, directly run. have their own address space, each process will consume memory. Process-based features allow a computer to run two or more programs at the same time.

2. Thread-based

A thread is a sequential control flow within a process. A process has multiple threads, and multiple threads share a process's memory space.

Main thread: Once the Main method is running, the main thread is turned on.

Features of the main thread:

1. Start first

2. Final End

3. Create other sub-threads

4. Recycling Resources

Two types of multitasking

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.