fix(syscall-stat): stop skipping syscall key 0 during stats traversal and no top mode - #119
Open
yuKing123-king wants to merge 1 commit into
Open
Conversation
yuKing123-king
force-pushed
the
fix/syscall-stat-first-key
branch
from
August 4, 2026 08:24
3b8787c to
2d9bbe7
Compare
yuKing123-king
force-pushed
the
fix/syscall-stat-first-key
branch
2 times, most recently
from
August 12, 2026 08:27
f411ec9 to
e379b4d
Compare
PR Reviewer Guide 🔍(Review updated until commit 5dabdbb)Here are some key observations to aid the review process:
|
… and no top mode Signed-off-by: Wang Yu <wangyu6@uniontech.com>
yuKing123-king
force-pushed
the
fix/syscall-stat-first-key
branch
from
August 12, 2026 08:34
e379b4d to
5dabdbb
Compare
已更改 |
|
Persistent review updated to latest commit 5dabdbb |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
修复了两个测试过程中发现的 Bug
Bug 1: 修复系统调用号 0 (read) 统计丢失问题
key初始化为 0,且使用bpf_map_get_next_key查找下一个 key。第一个 key 就是 0,get_next_key会跳过它直接找下一个,后续使用nxt_key作为真正第一个开始查找的key,导致系统调用号为0的readsyscall 永远不被统计。Bug 2: 修复
--top/-t动态刷新功能无效问题parse_args参数解析函数中遗漏了对-t和--top选项的处理。parse_args中添加了对应的 case 分支,使终端能正确识别并开启动态刷新模式。