Skip to content

Instantly share code, notes, and snippets.

View zhuizhuhaomeng's full-sized avatar

lijunlong zhuizhuhaomeng

  • openresty.Inc
  • xiamen
View GitHub Profile
[1]+ Running ./xdp_drop_ipv6_count_user /var/run/netns/orbpf1 veth1 &
[1]+ Running ./xdp_drop_ipv6_count_user /var/run/netns/orbpf1 veth1 &
libbpf: elf: skipping unrecognized data section(7) xdp_metadata
libbpf: Error loading BTF: Invalid argument(22)
libbpf: magic: 0xeb9f
version: 1
flags: 0x0
hdr_len: 24
type_off: 0
type_len: 892
commit cf5b90dff53e0ebaba49073fe0c2d7e45f30cd52
Author: lijunlong <lijunlong@openresty.com>
Date: Mon Jul 10 13:17:46 2023 +0800
Bug: _stp_stack_user_sprint&_stp_stack_kernel_sprint flush the output buffer if the backtrace size greater than STP_BUFFER_SIZE.
diff --git a/runtime/linux/print.c b/runtime/linux/print.c
index db71871d2..98916d1ca 100644
--- a/runtime/linux/print.c
+++ b/runtime/linux/print.c
commit 1ec33bf603d2900750af2a5c3dc0e964f5dfa4aa
Author: lijunlong <lijunlong@openresty.com>
Date: Mon Jul 10 13:17:46 2023 +0800
Bug: _stp_stack_user_sprint&_stp_stack_kernel_sprint flush the output buffer if the backtrace size greater than STP_BUFFER_SIZE.
diff --git a/runtime/dyninst/print.c b/runtime/dyninst/print.c
index f23c3858e..e2a8b8843 100644
--- a/runtime/dyninst/print.c
+++ b/runtime/dyninst/print.c
Breakpoint 1, elf_compress_gnu (scn=scn@entry=0x5635858, inflate=inflate@entry=0, flags=flags@entry=0) at elf_compress_gnu.c:40
40 elf_compress_gnu.c: No such file or directory.
(gdb) bt
#0 elf_compress_gnu (scn=scn@entry=0x5635858, inflate=inflate@entry=0, flags=flags@entry=0)
at elf_compress_gnu.c:40
#1 0x00007ffff795e48d in check_section (result=result@entry=0x563aee0, shstrndx=shstrndx@entry=46,
scn=scn@entry=0x5635858, inscngrp=inscngrp@entry=false) at dwarf_begin_elf.c:208
#2 0x00007ffff795ec3b in global_read (shstrndx=<optimized out>, elf=<optimized out>, result=0x563aee0)
at dwarf_begin_elf.c:407
#3 dwarf_begin_elf (elf=0x5633b10, cmd=cmd@entry=DWARF_C_READ, scngrp=scngrp@entry=0x0) at dwarf_begin_elf.c:558
_stp_init_stack:54: stack_trace_saves_regs_fn=ffffffff8cf88860 for _stp_stack_print_fallback().
_stp_stack_unwind_one_user:546: STARTING user unwind
HEX: runtime.cgocall[2]
_stp_stack_unwind_one_user:562: CONTINUING user unwind to depth 1
unwind:1493: pc=4041bc, 4041bc
unwind:1536: trying debug_frame
set_no_state_rule:249: reg=10, where=1
_stp_search_unwind_hdr:789: binary search for 4041bc
adjustStartLoc:734: adjustStartLoc=430b40, ptrType=DW_EH_PE_absptr, m=/tmp/y_trace_yfieYs0/test_prog, s=.absolute eh=0
adjustStartLoc:734: adjustStartLoc=41aac0, ptrType=DW_EH_PE_absptr, m=/tmp/y_trace_yfieYs0/test_prog, s=.absolute eh=0
commit b322f8820f0a965bd95315d73bfecd377fe82231
Author: lijunlong <lijunlong@openresty.com>
Date: Thu Jul 6 21:39:30 2023 +0800
bugfix: unwind failed because did not get unwind data from the .zdebug_frame section.
diff --git a/translate.cxx b/translate.cxx
index 4115650e3..568b50c3c 100644
--- a/translate.cxx
+++ b/translate.cxx
commit e5fbe2fdf6376d7b064d6bdc4e8980bd7dc21052
Author: lijunlong <lijunlong@openresty.com>
Date: Thu Jul 6 21:39:30 2023 +0800
bugfix: unwind failed because did not get unwind data from the .zdebug_frame section.
diff --git a/translate.cxx b/translate.cxx
index 4115650e3..60415563a 100644
--- a/translate.cxx
+++ b/translate.cxx
commit ffbb604ca72b709d8f77eebab7da97ec366c4f5b
Author: lijunlong <lijunlong@openresty.com>
Date: Wed Jun 28 16:10:40 2023 +0800
bugfix: _stp_stack_user_sprint flush the buffer to the terminal when the log->buf is full.
diff --git a/runtime/linux/print.c b/runtime/linux/print.c
index 594b155be..8dbb3a800 100644
--- a/runtime/linux/print.c
+++ b/runtime/linux/print.c
diff --git a/dwflpp.cxx b/dwflpp.cxx
index c2fdb05f5..96d55490e 100644
--- a/dwflpp.cxx
+++ b/dwflpp.cxx
@@ -2892,7 +2892,7 @@ dwflpp::find_variable_and_frame_base (vector<Dwarf_Die>& scopes,
// version is recent enough to not need this workaround if
// we would see an imported unit.
if (dwarf_tag (vardie) == DW_TAG_variable
- && strcmp (dwarf_diename (vardie), local.c_str ()) == 0
+ && strcmp (dwarf_diename (vardie) ?: "<unknown>", local.c_str ()) == 0
{
"classDog::func_a(int)": {
"classDog": [
"4a2",
"514"
]
},
"classDog::func_b(long int)": {
"classDog": [
"4db",