aspose file tools*
The moose likes Threads and Synchronization and the fly likes Differences between Process and Thread Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Threads and Synchronization
Bookmark "Differences between Process and Thread" Watch "Differences between Process and Thread" New topic
Author

Differences between Process and Thread

Rahul Mahindrakar
Ranch Hand

Joined: Jul 28, 2000
Posts: 1850
Lets list down the differences between the two in this thread!!
V Srinivasan
Ranch Hand

Joined: Aug 16, 2000
Posts: 99
Can we say
Process is purely CPU's action
Thread manipulates the CPU's idle time
Marcela Blei
Ranch Hand

Joined: Jun 28, 2000
Posts: 477
Originally posted by V Srinivasan:
Process is purely CPU's action
Thread manipulates the CPU's idle time

Yes, but a Thread manages one single process
Rahul Mahindrakar
Ranch Hand

Joined: Jul 28, 2000
Posts: 1850
Differences between a thread and a Process
1) It takes less overhead to create and destroy individual threads than it does individaual process which is why all modern operating systems support multithreading
2) IPC (Inter Process communication) is much slower and more restrictive than communication between threads
3) Each process has a complete set of its own variables while threads share the same data.
Regds.
Rahul P. Mahindrakar
Prabhjyot Singh
Greenhorn

Joined: Dec 28, 2000
Posts: 22
Methods like yield(),wait() are provided for IPC in java.Thus they cater to different threads inside the same ONE process.Multiple concurrent processes are supported in modern os's in process control blocks are created by the os track their addresses.Sharing of data is expensive between processes,the familiar consumer-producer processes ascompared to threads within a single process coz of faster context switching.Hope it helps.
 
 
subject: Differences between Process and Thread