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

Reproducible BTF tarballs #98

Closed
brycekahle opened this issue Sep 21, 2023 · 3 comments · Fixed by #108
Closed

Reproducible BTF tarballs #98

brycekahle opened this issue Sep 21, 2023 · 3 comments · Fixed by #108

Comments

@brycekahle
Copy link
Collaborator

brycekahle commented Sep 21, 2023

I believe that if you removed a BTF .tar.xz file and re-ran the script, you would get a different output. The actual BTF should be the same, but because tar is preserving mtime, users, and possible other data, the .tar.xz file will always be different.

I can see two potential avenues to explore:

  1. Extract a datetime from the package repo to use as the mtime for the BTF file itself
  2. Force the same datetime for all files. This StackOverflow answer talks about a way to do that.

WDYT?

@brycekahle
Copy link
Collaborator Author

For context, I think this is valuable so we can re-run the script on the archive when things change, such as pahole arguments, and only update what actually changes.

@rafaeldtinoco
Copy link
Contributor

Sorry has been some busy last weeks. I wonder if the BTF ids coming from pahole won't be random. From libbpf, the BTF ids are created as the types are added to the "BTF" object.

I believe pahole has this process parallelized which would cause the IDs to, maybe, be different from one run to another.

@brycekahle
Copy link
Collaborator Author

brycekahle commented Oct 16, 2023

We aren't using -j, so it isn't an issue: acmel/dwarves#42

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

Successfully merging a pull request may close this issue.

2 participants