The concept of thread-parallel computing, Computer Engineering

Assignment Help:

The Concept of Thread

Thread is a chronological flow of control within a process. A process can include one or more threads. Threads have their own register values and program counter, but they are split the memory space and other resources of the procedure. Each process always starts with a single thread. Through the implementation of other threads may be produced as and when necessary. Like processes, each thread has an implementation state (ready, running, terminated or blocked). A thread has entrance to the memory address space and resources of its process. Threads have related life cycles as the processes do. A single processor system can maintain concurrency by switching implementation among two or more threads. A multi-processor system can hold parallel concurrency by executing a separate thread on each processor. There are three basic process in concurrent programming languages for terminating and creating threads:

Unsynchronised creation and termination:  In this method threads are terminated and created using library functions such as, START_PROCESS, CREATE_THREAD, CREATE_PROCESS and START_THREAD. As a effect of these function calls a new process or thread is produced and starts consecutively independent of its parents.

Unsynchronised creation and synchronized termination:  This method uses two instructions: JOIN and FORK. The FORK instruction creates a new thread or process. When the parent needs the child's(thread or process) result, it calls JOIN instruction. At this junction two threads (processes) are synchronised.

Synchronised creation and termination:  The most commonly system construct to implement synchronization is

COBEGIN...COEND. The threads among the COBEGIN...COEND construct are executed in similar. The termination of parent-child is suspended until all child threads are ended.

We can think of a thread as basically a inconsequential process. However, threads present some advantages over processes. The advantages of this are:

i) It takes very less time to terminate and create a new thread than to Terminate and Create a process. The reason being that a newly terminate thread uses the current process address space.

ii) It obtains less time to switch between two threads within the similar process, partly because the recently created thread uses the current process address space.

iii) Less communication overheads -- communicating between the threads of one process is easy because the threads share among former entities the address space. So, data produced by one thread is directly available to all the other threads.


Related Discussions:- The concept of thread-parallel computing

What is parsing in grammatical structure, What is Parsing? Parsing: ...

What is Parsing? Parsing: It is the process of analyzing a text, made of an order of tokens, to find out its grammatical structure regarding a given formal grammar. Parsing

Describe distributed object model, Question 1 Give a brief explanation on m...

Question 1 Give a brief explanation on message oriented middleware Question 2 Describe Distributed object model Question 3 Explain File systems in a distributed computing Env

Define the addressing modes, Q. Define the ADDRESSING MODES? The elemen...

Q. Define the ADDRESSING MODES? The elementary set of operands in 8086 can reside in memory, register and immediate operand. How can these operands be retrievedby various addre

What is xml, XML is the Extensible Markup Language. It betters the function...

XML is the Extensible Markup Language. It betters the functionality of the Web by letting you recognize your information in a more accurate, flexible, and adaptable way. It is e

Why a linked list is called a dynamic data structure, Why a linked list is ...

Why a linked list is called a dynamic data structure? What are the advantages of using linked list over arrays?    A linked list is known as a dynamic data structure because it

Describe the operation of voltage to frequency ADC, Describe the operation ...

Describe the operation of voltage to frequency ADC. Ans: A voltage-to-frequency converter i.e. VFC is an oscillator that frequency is linearly proportional to a control volt

Operating system, explain the various types of computer systems

explain the various types of computer systems

Analysis of amdahls law, Q. Analysis of Amdahls law? The conclusions of...

Q. Analysis of Amdahls law? The conclusions of analysis of Amdahl's law are: 1) To optimize performance of parallel computers modified compilers should be developed that sho

State the optimal route of node, State the optimal route of node Consid...

State the optimal route of node Consider the node i which has path length K+1, with the directly preceding node on the path being j. The distance to node i is w(j, i) plus the

Queueing process, explain in detail about queueing process

explain in detail about queueing process

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd