Question d’entretien chez Bloomberg

What is 'deadlock'?

Réponses aux questions d'entretien

Utilisateur anonyme

31 mai 2010

When two competing threads/processes need to acquire a resource which the other one has they are said to be deadlocked. Both want what the other has to perform a task but neither will release what they have until they get what the other has. A timeout on the held resources would help deadlock avoidance in this instance.

3

Utilisateur anonyme

6 sept. 2011

Thread A has resource 'X' locked, and needs to access resource 'Y' before releaseing 'X' but 'Y' currently locked. Meanwhile its Thread B that has 'Y' locked, but needs to access 'X' before releasing 'Y'. Without a timeout its a dead lock.

Utilisateur anonyme

27 févr. 2010

Threading process