Video

Latest

OS - Deadlock vs Race Around Condition (Must)

    



Deadlock :

  1. This happens when 2 or more threads are waiting on each other to release the resource for infinite amount of time.
  2. In this the threads are in blocked state and not executing.

Race/Race Condition :

  1. This happens when 2 or more threads run in parallel but end up giving a result which is wrong and not equivalent if all the operations are done in sequential order.
  2. Here all the threads run and execute there operations.

In Coding we need to avoid both race and deadlock condition.

No comments