Apparently existing implementation of "osv runqueue" in loader.py navigates the sched::cpus::runqueue structure which is an rbtree in a way that started breaking at some point probably with newer versions of boost.
To fix it we simply use the existing intrusive_set_root_node() method to help us navigate runqueue in a more resilient way. Signed-off-by: Waldemar Kozaczuk <[email protected]> --- scripts/loader.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/loader.py b/scripts/loader.py index 6270d980..c59d7e6f 100644 --- a/scripts/loader.py +++ b/scripts/loader.py @@ -1489,8 +1489,7 @@ def runqueue(cpuid, node=None): cpus = gdb.lookup_global_symbol('sched::cpus').value() cpu = cpus['_M_impl']['_M_start'][cpuid] rq = cpu['runqueue'] - p = rq['data_']['node_plus_pred_'] - node = p['header_plus_size_']['header_']['parent_'] + node = intrusive_set_root_node(rq) if node: offset = gdb.parse_and_eval('(int)&((sched::thread *)0)->_runqueue_link') -- 2.25.1 -- You received this message because you are subscribed to the Google Groups "OSv Development" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/osv-dev/20200708201037.35894-1-jwkozaczuk%40gmail.com.
