1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

What is the difference between a computer process and thread?

Discussion in 'Engineering Concepts' started by aspguy, May 16, 2008.

  1. aspguy

    aspguy New Member

    Joined:
    May 2, 2005
    Messages:
    59
    Likes Received:
    1
    Trophy Points:
    0
    What is the difference between a computer process and thread?
     
  2. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,293
    Likes Received:
    365
    Trophy Points:
    83
    By definition process will execute the threads(set of instructions), which may contain multiple threads but the other way is not true.

    Also different processes can't work under same memory location i.e. threads ca share resource but sharing of processes resources is not that easy.
     
  3. mialuzzatto

    mialuzzatto New Member

    Joined:
    Aug 5, 2015
    Messages:
    122
    Likes Received:
    4
    Trophy Points:
    0
    Occupation:
    Work at https://www.idevelopersquare.com
    Location:
    Waltham, MA, USA
    Home Page:
    Hello,

    Threads are used for small tasks, whereas processes are used for more 'heavyweight' tasks – basically the execution of applications. Another difference between a thread and a process is that threads within the same process share the same address space, whereas different processes do not.
     
  4. tutorsweb

    tutorsweb Member

    Joined:
    Oct 12, 2015
    Messages:
    79
    Likes Received:
    1
    Trophy Points:
    8
    Occupation:
    www.tutorsweb.com
    Location:
    hyderabad
    Home Page:
    A process is a program in execution, whereas a thread is a path of execution within a process. Processes are generally used to execute large, ‘heavyweight’ jobs such as running different applications, while threads are used to carry out much smaller or ‘lightweight’ jobs such as auto saving a document in a program, downloading files, etc.
     
  5. JohnAdams

    JohnAdams New Member

    Joined:
    Oct 15, 2016
    Messages:
    20
    Likes Received:
    1
    Trophy Points:
    3
    Gender:
    Male
    The processes and threads are independent sequences of execution, the difference between the process and a thread is that threads run in a shared memory space, while processes run in separate memory spaces.

    A process has a complete, private set of basic run time resources and each process has its own memory space. Threads exist within a process and every process has at least one thread.

    Each process provides the resources needed to execute a program. Each process is started with a single thread, known as the primary thread. A process can have multiple threads in addition to the primary thread.

    Processes are heavily dependent on system resources available while threads require minimal amount of resource, so a process is considered as heavyweight.
     

Share This Page