Thread: Semaphores and critical sections

  1. #1
    Registered User
    Join Date
    Sep 2003
    Posts
    224

    Semaphores and critical sections

    Are critical sections equivalent to having a semaphore with a count of one?

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,660
    Are critical sections equivalent to mutexes?
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  3. #3
    Registered User
    Join Date
    Nov 2001
    Posts
    1,348
    Yes, funtionally. No, in terms of properties.

    critical section != kernel object
    semaphore == kernel object

    Kuphryn

  4. #4
    Registered User
    Join Date
    Sep 2003
    Posts
    224
    Thanks. I meant functionally.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Threads, Linked Lists, Semaphores, Critical Section ...
    By _jr in forum Windows Programming
    Replies: 4
    Last Post: 06-21-2006, 08:14 AM
  2. CreateThread ?!
    By Devil Panther in forum Windows Programming
    Replies: 13
    Last Post: 11-15-2005, 10:55 AM
  3. semaphores using C++ in console program
    By Unregistered in forum C++ Programming
    Replies: 8
    Last Post: 12-20-2001, 12:46 PM