Operating System

Topics: Process, Thread, Central processing unit Pages: 3 (507 words) Published: November 29, 2011
David Wongso (091101879) / VA4
David Steven (091101885) / VA4
Gery Alvin (091101886) / VA4


4.1 Provide two programming examples in which multithreading does not provide better performance than a single-threaded solution.

* Lebih dari satu thread melakukan I / O pada perangkat yang sama. * Lebih dari satu thread menggunakan data yang sama yang harus dikunci.

4.2 Describe the actions taken by a thread library to context switch between user-level threads.

* Hal ini untuk menyimpan tumpukan data dan data lokal lainnya, yang dapat dengan mudah dilakukan jika ditulis dalam bahasa pemrogrman dan memuat tumpukan data lainnya untuk proses yang sedang dialihkan.

4.3 Under what circumstances does a multithreaded solution using multiple kernel threads provide better performance than a single-threaded solution on a single-processor system?

* Umumnya, setiap situasi di mana pemungutan dihindari menggunakan multithreading, yang memungkinkan thread untuk memblokir daripada berkutat di beberapa kondisi.

4.4 Which of the following components of program state are shared across threads in a multithreaded process?

* Heap memory dan Global variables

4.5 Can a multithreaded solution using multiple user-level threads achieve better performance on a multiprocessor system than on a single-processor system?

* Tidak, karena kernel tidak dapat mengetahui tingkat thread pengguna selain dari proses tunggal, yang tentu saja selalu berjalan pada satu CPU.

4.6 As described in Section 4.5.2, Linux does not distinguish between processes and threads. Instead, Linux treats both in the same way, allowing a task to be more akin to a process or a thread depending on the set of flags passed to the clone() system call. However, many operating systems—such as Windows XP and Solaris—treat processes and threads differently. Typically, such systems use a notation wherein the data structure for a process contains pointers to the...
Continue Reading

Please join StudyMode to read the full document

You May Also Find These Documents Helpful

  • Essay on Operating System
  • Computer Operating System Essay
  • Essay on Memory and Process Manager Functionality Introduction to Operating Systems
  • Operating System and Windows Essay
  • Types Of Operating System Essay
  • U02a1 Operating System Upgrade Plan Essay
  • operating systems Essay
  • Operating Systems Essay

Become a StudyMode Member

Sign Up - It's Free