Esempio n. 1
0
 def dump_segment_freeq(self, idx, freeq, size):
     pages = tailq.collect_values(freeq, 'freeq')
     return [[
         str(idx),
         str(size),
         as_hex(page['paddr']),
         as_hex(page['vaddr'])
     ] for page in pages]
Esempio n. 2
0
def get_threads_blocked_on_mutex(mtx):
    sq = gdb.parse_and_eval("sleepq_lookup((void *)%d)" % mtx.address)
    return map(lambda n: n.string(),
               tailq.collect_values(sq['sq_blocked'], 'td_name'))
Esempio n. 3
0
def get_all_threads():
    tdq = gdb.parse_and_eval('all_threads')
    return tailq.collect_values(tdq, 'td_all')
Esempio n. 4
0
def get_threads_blocked_on_mutex(mtx):
    ts = mtx['turnstile']
    return map(lambda t: t['td_name'].string(), tailq.collect_values(ts['td_queue'], 'td_lock'))
Esempio n. 5
0
def get_threads_blocked_on_mutex(mtx):
    ts = mtx['turnstile']
    return map(lambda t: t['td_name'].string(),
               tailq.collect_values(ts['td_queue'], 'td_lock'))
Esempio n. 6
0
 def get_all_segments(self):
     segq = gdb.parse_and_eval('seglist')
     return tailq.collect_values(segq, 'segq')
Esempio n. 7
0
def get_all_threads():
    tdq = gdb.parse_and_eval('all_threads')
    return tailq.collect_values(tdq, 'td_all')
Esempio n. 8
0
 def dump_segment_freeq(self, idx, freeq, size):
     pages = tailq.collect_values(freeq, 'freeq')
     return [[idx, size, as_hex(page['paddr']), as_hex(page['vaddr'])]
             for page in pages]
Esempio n. 9
0
 def get_all_segments(self):
     segq = gdb.parse_and_eval('seglist')
     return tailq.collect_values(segq, 'segq')