title: Multithreading Linux vs Windows One-One Many-Many One-One
body: <p>What multithreading methods do different OS use and why are they important:</p>
  
  <pre><code>Multithreading Models
  
      Many-to-One - many user threads to one kernel thread
      One-to-One - each user thread is mapped to a kernel thread
      Many-to-Many - Many user threads to smaller or equal # of kernel threads
  </code></pre>
  
  <p>This is what I know about multithreading models.</p>
  
  <ul>
  <li>Solaris uses Many-to-One</li>
  <li>Linux &amp; Windows family (at least to XP, not sure about Win7) uses One-to-One</li>
  <li>IRIX, HP-UX,andTru64 UNIX (Solaris prior to v9) uses Many-to-Many</li>
  </ul>
  
  <p>Why they are important?</p>
  
  <ol>
  <li>Responsiveness - web browsing in one thread, loading images in
  another </li>
  <li>Resource sharing - allow several thread of activity in same
  address space </li>
  <li>Economy - memory &amp; resources for process creation is
  costly while threads share resources of a process (Solaris is 30x
  slower creating process than a thread) </li>
  <li>Scalability - In multiprocessor, threads can run parallel on diff processors,
  single-thread process can only run on one processor regardless of
  how many processors exist</li>
  </ol>