Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KCOV: suppress parasitic coverage #5521

Open
dvyukov opened this issue Nov 20, 2024 · 1 comment
Open

KCOV: suppress parasitic coverage #5521

dvyukov opened this issue Nov 20, 2024 · 1 comment

Comments

@dvyukov
Copy link
Collaborator

dvyukov commented Nov 20, 2024

Some common kernel helper functions, especially the ones with loop, or called inside of loops, can produce lots of uninteresting coverage that overflows KCOV buffer. We already don't instrument some of such helpers, but we need to support more.

These can be found by running programs with beefy coverage (esp the ones that overflow KCOV buffer) with syz-execprog -coverfile, and then passing the resulting traces via addr2line.

Some helpers that I found:

  • is_bpf_text_address called during stack unwinding
  • arch_static_branch is called a lot from somewhere
  • string_nocheck has a loop
  • common containers (lib/xarray.c, lib/maple_tree.c) (are they interesting for us?)
@jiangenj
Copy link
Contributor

Add discussion link here https://groups.google.com/g/syzkaller/c/rSPSMttoNWw
and print pc count PR #5617 since syz-execprog, then addr2line takes much time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants