Difference between process and thread

1.A process is an instance of a computer program that is being executed. It contains the program code and its current activity. A thread is the smallest unit of processing that can be performed in an OS.

2.Process is considered heavy weight. Thread is considered light weight.

3.Process is unit of CPU utilization. Thread is unit of Resource Allocation and of protection.

4.Process do not share file descriptors. Thread can share file descriptors.

5.Process creation is very costly in terms of resources. Thread creation is very economical.

6.Program executing as process are relatively slow. Programs executing using thread are comparatively faster.

7.Process cannot access the memory area belonging to another process. Thread can access the memory area belonging to another thread within the same process.

8.Process switching is time consuming. Thread switching is faster.

9.One Process can contain several threads. One thread can belong to exactly one process.

10.Process do not share signal handling. Threads can share signal handling.


What to read next

Please Go through all these linksW3Schools – HTML Tutorial

DefinitionFiber optics is the technology used to transmit information as pulses of light through strands of fiber made of glass or plastic over long