-
Notifications
You must be signed in to change notification settings - Fork 286
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
Support Parsing of BTF Maps #140
Merged
Merged
Conversation
This file contains 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
dave-tucker
force-pushed
the
btf-maps
branch
2 times, most recently
from
December 10, 2021 23:48
165bc5b
to
72fc069
Compare
dave-tucker
force-pushed
the
btf-maps
branch
3 times, most recently
from
December 12, 2021 11:34
17a8c4e
to
5ffbdfc
Compare
dave-tucker
changed the title
Support Parsing of BTF Maps
[DO NOT MERGE] Support Parsing of BTF Maps
Dec 12, 2021
dave-tucker
added
feature
A PR that implements a new feature or enhancement
aya
This is about aya (userspace)
labels
Jan 10, 2022
dave-tucker
changed the title
[DO NOT MERGE] Support Parsing of BTF Maps
Support Parsing of BTF Maps
Jan 12, 2022
Parsing works fine, but relocations do not. marking as draft until this is resolved. |
✅ Deploy Preview for aya-rs ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
dave-tucker
force-pushed
the
btf-maps
branch
4 times, most recently
from
July 1, 2022 21:15
1df5342
to
859dacf
Compare
dave-tucker
force-pushed
the
btf-maps
branch
2 times, most recently
from
July 3, 2022 17:33
1f3d0bc
to
23968cd
Compare
alessandrod
reviewed
Jul 11, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks really great - thanks so much for working on it!
Almost there, just a couple of nits.
This commit allows for BTF maps in the .maps ELF section to be parsed. It reads the necessary information from the BTF section of the ELF file. While the btf_ids of Keys and Values types are stored, they are not (yet) used. When creating a BTF map, we pass the btf_key_type_id and btf_value_type_id. Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
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.
This PR allows for BTF maps in the .maps ELF section to be parsed.
It reads the necessary information from the BTF section of the ELF file.
It provides the BTF IDs to the
bpf_map_create
call.This allows for
bpftool
to pretty print maps! For example: