Detects deadlocks
Definition at line 397 of file deadlock.py.
def deadlock.Deadlock.__init__ |
( |
|
self | ) |
|
def deadlock.Deadlock.invoke |
( |
|
self, |
|
|
|
arg, |
|
|
|
from_tty |
|
) |
| |
Prints the threads and mutexes in a deadlock, if it exists.
Definition at line 403 of file deadlock.py.
References deadlock.find_cycle(), deadlock.get_thread_info(), and deadlock.print_cycle().
404 '''Prints the threads and mutexes in a deadlock, if it exists.''' 413 for thread_lwp, mutex_type
in blocked_threads.items():
414 get_owner_and_address_func = \
415 MutexType.get_mutex_owner_and_address_func_for_type(mutex_type)
416 if not get_owner_and_address_func:
418 mutex_owner_lwp, mutex_address = get_owner_and_address_func(
419 lwp_to_thread_id, thread_lwp
421 if mutex_owner_lwp
and mutex_address:
426 mutex_type=mutex_type
432 print(
'Found deadlock!')
436 'No deadlock detected. ' 437 'Do you have debug symbols installed?'
def print_cycle(graph, lwp_to_thread_id, cycle)
def invoke(self, arg, from_tty)
The documentation for this class was generated from the following file: