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

Freebsd-target-support #2221

Merged
merged 9 commits into from
Jun 27, 2022
Merged

Freebsd-target-support #2221

merged 9 commits into from
Jun 27, 2022

Conversation

b-ncMN
Copy link
Contributor

@b-ncMN b-ncMN commented Jun 9, 2022

Implement freebsd as a target for miri

diff Outdated Show resolved Hide resolved
tests/pass/libc.rs Outdated Show resolved Hide resolved
src/shims/env.rs Outdated Show resolved Hide resolved
@RalfJung
Copy link
Member

RalfJung commented Jun 10, 2022 via email

@RalfJung
Copy link
Member

RalfJung commented Jun 10, 2022

Thanks for the PR! Looks like our target support can grow quite a bit in the near future. :)

I think for this to work we need to make sure that these targets can actually remain supported as the Rust standard library evolves. So if/when we add freebsd to CI and the supported target in the README, then we should also list there who is actually going to maintain that target -- so that we have someone to ping when there is trouble with that target (the Rust standard library will inevitably change and that might require adjustments in Miri so that the target remains supported). We shouldn't have support for targets that nobody is going to maintain. And I don't want to be on the hook for maintaining them all. :)

So @InfRandomness do you want to be listed as maintaining freebsd support in Miri?

@b-ncMN
Copy link
Contributor Author

b-ncMN commented Jun 10, 2022

Thanks for the PR! Looks like our target support can grow quite a bit in the near future. :)

I think for this to work we need to make sure that these targets can actually remain supported as the Rust standard library evolves. So if/when we add freebsd to CI and the supported target in the README, then we should also list there who is actually going to maintain that target -- so that we have someone to ping when there is trouble with that target (the Rust standard library will inevitably change and that might require adjustments in Miri so that the target remains supported). We shouldn't have support for targets that nobody is going to maintain. And I don't want to be on the hook for maintaining them all. :)

So @InfRandomness do you want to be listed as maintaining freebsd support in Miri?

Sure !

@b-ncMN b-ncMN force-pushed the freebsd-target-support branch 4 times, most recently from fafefd0 to c35b41d Compare June 11, 2022 19:43
@bors
Copy link
Collaborator

bors commented Jun 12, 2022

☔ The latest upstream changes (presumably #2226) made this pull request unmergeable. Please resolve the merge conflicts.

@b-ncMN b-ncMN force-pushed the freebsd-target-support branch 3 times, most recently from ad4f00c to 30b7a78 Compare June 13, 2022 19:28
@b-ncMN b-ncMN marked this pull request as ready for review June 13, 2022 19:40
@b-ncMN
Copy link
Contributor Author

b-ncMN commented Jun 13, 2022

tests/pass/hello.rs seems to pass successfully but the other tests don't seem like they do

@dtolnay
Copy link
Member

dtolnay commented Jun 21, 2022

Thank you InfRandomness, this PR was already super helpful to me in rust-lang/libc#2813 (review) for validating a FreeBSD codepath in the libc crate.

unsafe {
assert_eq!(libc::getpid(), std::process::id());
}
}
Copy link
Member

@RalfJung RalfJung Jun 26, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This function is not even called; seems to be some rebase mistake?
Please just remove it. :)

@RalfJung
Copy link
Member

RalfJung commented Jun 26, 2022

This looks good overall! I just left some minor comments.
Please pull before pushing again; I have rebased your branch and adjusted CI to only run some minimal tests for FreeBSD. That should make CI pass, hopefully. :)

@RalfJung
Copy link
Member

Thanks. :)
@bors r+

I'm open tom follow-on PRs to get this to be a supported platform that passes all tests. :D

@bors
Copy link
Collaborator

bors commented Jun 27, 2022

📌 Commit 5719897 has been approved by RalfJung

@bors
Copy link
Collaborator

bors commented Jun 27, 2022

⌛ Testing commit 5719897 with merge f5593de...

@bors
Copy link
Collaborator

bors commented Jun 27, 2022

☀️ Test successful - checks-actions
Approved by: RalfJung
Pushing f5593de to master...

@bors bors merged commit f5593de into rust-lang:master Jun 27, 2022
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 this pull request may close these issues.

5 participants