Is the threading model based on kernel-level or user-level threads?
User Level Threads
– The user level threads are managed by a user level library
– In this method user level thread they only still uses the require a kernel system call to operate.
– It does not mean that the kernel knows anything about thread management.
– User level threads are typically fast.
– The user level threads are good in non blocking tasks, if not entire process will be in block if any thread blocks are their.
Kernel Level Threads
– Kernel level threads are managed by the Operating system.
– In this level the thread operations are implemented in the kernel code.
– In this level threads the kernel level threads may favor heavy processes of threads.
– Kernel Level Threads are slow compare to the user level due to management overhead.
– These level threads are not portable by the implementation because it is OS dependent.
What is the most significant advantage of the implementation?
– The kernel threading has the full knowledge of all threads.
– It can process large number of threads than process having small number of threads.
– The Kernel level threads are good for applications which are frequently blocks.
– The user level threads has the package which can be implement on the OS that does not support threads.
– The User level threads does not require modification to OS.
– User level are Simple Representation
– User level are Simple Management
– User level are Fast and Efficient
What is the most significant disadvantage of the implementation?
– The kernel-level threads are slow and inefficient.
– These kind of threads has the operations which are hundreds of times slower than the user level threads.
– Thread control block maintain the information about threads which are significant overhead and increased in kernel complexity.
– There is a lack of coordination between threads and operating system kernel.
– These kind of thread to relinquish control to other threads.
– The User level threads requires non-blocking systems call that is known as the multithreaded kernel.
– The entire process will blocked in the kernel even the threads are left in the processes.
Example: The process will be in block stage if one thread causes a page fault.
Provide a scenario where this method of threading will provide the best solution and explain why?
The methods which provide the best solution is Multithreading Models.
By using the Multithreading Models we can give the best solution in different ways and methods
few method and model of Multithreading Models are as follows:
– Many to many relationship model method.
– Many to one relationship model method.
– One to one relationship model method.
By using the those above model methods we can define the best solution in threading because
combined system and multiple threads of the same application can run in parallel on multiple
processors and also it can block the system call when we need not to block the entire process.