Skip to content

Find a way to test auxv on Linux #234

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

Closed
gnzlbg opened this issue Dec 12, 2017 · 4 comments
Closed

Find a way to test auxv on Linux #234

gnzlbg opened this issue Dec 12, 2017 · 4 comments

Comments

@gnzlbg
Copy link
Contributor

gnzlbg commented Dec 12, 2017

Ideally we should add some synthetic tests like the ones for cpuinfo that works on all platforms. The auxv crate has some of them here: https://bitbucket.org/marshallpierce/rust-auxv/src/8d07bcd24d72f35ab3a610fb022dc5988a9ce210/src/test-data/?at=master (@marshallpierce)

but none of them are for ARM or PowerPC which are the only platforms were we currently use auxv.

@marshallpierce
Copy link

I added a procfs auxv file from my raspberry pi 3 to that repo, so now there's at least an arm sample.

@gnzlbg
Copy link
Contributor Author

gnzlbg commented Dec 12, 2017

Nice! That is very helpful! As a rough sketch of what we could initially do, how does the following sound?:

  • add the auxv crate as a dev-dependency and test that our implementation produces the same results as the auxv crate on all the platforms that we are currently testing
  • test directly against some or all of the auxv dumps of the auxv crate (I don't know the best way to set this up, but worst case we can just copy the files here)
  • generate dumps of auxv for other platforms that we care about and commit them to the auxv crate upstream

@marshallpierce
Copy link

Sounds good to me!

@gnzlbg
Copy link
Contributor Author

gnzlbg commented Mar 1, 2018

This has already been fixed on master. We test run-time detection against the auxv crate and some processor dumps for ARM, Aarch64, and PowerPC.

@gnzlbg gnzlbg closed this as completed Mar 1, 2018
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

3 participants