wasi: clean up core platform abstractions - #12503
Conversation
|
closes #12427 |
|
GNU testsuite comparison: |
| pub type Pid = u64; | ||
|
|
||
| #[cfg(target_os = "wasi")] | ||
| #[allow(dead_code)] |
There was a problem hiding this comment.
please refactor to avoid the allow dead code
There was a problem hiding this comment.
Okay, I think we can just remove ProcessChecker for WASI. Since the original PR is from a couple months ago, I don't remember why exactly it was added.
Merging this PR will not alter performance
Comparing Footnotes
|
0e00f98 to
2645a6d
Compare
2645a6d to
618421d
Compare
|
Is this ready to merge? |
|
If's ready for whatever you want to do with it. I have coreutils working in Wasm and wanted to upstream my changes here in case it's useful to others. However, the process has dragged on for months, and there's been some unnecessary friction. |
|
Now there's a new merge conflict. I've already resolved several other such conflicts in the past few months. I think I will just leave #11712 as a reference for whoever is interested in Wasm support and maintain my own private patches, rather than trying to upstream changes here. |
618421d to
7db371a
Compare
This is the first PR split out from the larger WASI changes in #11712.
Changes
rustix::fs::Statfor WASIFileInformationso same-file checks use device/inode identity instead of a file-type/size heuristic.read_fs_list()returnUResult<Vec<MountInfo>>on WASI, matching other platforms while still returning an empty mount list.OsStrExt/OsStringExtimports inenv.tailprocess-check stubs so the shared follow code compiles while--pidremains unsupported.OwnedFileDescriptorOrHandle::into_stdio().