You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brpc.apache.org by le...@apache.org on 2025/12/18 02:46:51 UTC

(brpc) branch master updated: fix gdb_bthread_stack bthread_begin error (#3176)

This is an automated email from the ASF dual-hosted git repository.

leander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/brpc.git


The following commit(s) were added to refs/heads/master by this push:
     new 2e197845 fix gdb_bthread_stack bthread_begin error (#3176)
2e197845 is described below

commit 2e197845391feaa016e9276abd94292eb1fb2286
Author: Searion <33...@users.noreply.github.com>
AuthorDate: Thu Dec 18 10:46:46 2025 +0800

    fix gdb_bthread_stack bthread_begin error (#3176)
    
    Co-authored-by: Haigang Xi <xh...@blackwingasset.com>
---
 tools/gdb_bthread_stack.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/gdb_bthread_stack.py b/tools/gdb_bthread_stack.py
index acb6628a..2b18e0af 100644
--- a/tools/gdb_bthread_stack.py
+++ b/tools/gdb_bthread_stack.py
@@ -55,8 +55,8 @@ bthreads = []
 status = False
 
 def get_bthread_num():
-    root_agent = gdb.parse_and_eval("&(((((*bthread::g_task_control)._nbthreads)._combiner)._agents).root_)")
-    global_res = int(gdb.parse_and_eval("((*bthread::g_task_control)._nbthreads)._combiner._global_result"))
+    root_agent = gdb.parse_and_eval("&(((*(((*bthread::g_task_control)._nbthreads)._combiner._M_ptr))._agents).root_)")
+    global_res = int(gdb.parse_and_eval("(*(((*bthread::g_task_control)._nbthreads)._combiner._M_ptr))._global_result"))
     get_agent = "(*(('bvar::detail::AgentCombiner<long, long, bvar::detail::AddTo<long> >::Agent' *){}))"
     last_node = root_agent
     long_type = gdb.lookup_type("long")


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org