Bloomberg L.P. Interview Question: What is 'deadlock'?... |

Interview Question

Software Engineer Interview London, England

What is 'deadlock'?


Interview Answer

3 Answers


Threading process

Interview Candidate on 27 Feb 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.

Anonymous on 31 May 2010

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.

Anonymous on 6 Sep 2011

Add Answers or Comments

To comment on this, Sign In or Sign Up.