-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Migrate reproducible-build
run-make
test to rmake
#128456
Conversation
This comment has been minimized.
This comment has been minimized.
Note to self: look at linker not found |
☔ The latest upstream changes (presumably #127095) made this pull request unmergeable. Please resolve the merge conflicts. |
31604f2
to
6f554ec
Compare
Looks like the linker problem got fixed, but now, there are some issues with the bin copying on this test: run_in_tmpdir(|| {
rustc().input("reproducible-build-aux.rs").run();
rfs::create_dir("test");
rfs::copy("reproducible-build.rs", "test/reproducible-build.rs");
rustc()
.input("reproducible-build.rs")
.crate_type("bin")
.arg(&format!("--remap-path-prefix={}=/b", cwd().display()))
.run();
eprintln!("{:#?}", rfs::shallow_find_dir_entries(cwd()));
rfs::copy(bin_name("reproducible_build"), bin_name("foo"));
rustc()
.input("test/reproducible-build.rs")
.crate_type("bin")
.arg("--remap-path-prefix=/test=/b")
.run();
assert_eq!(rfs::read(bin_name("reproducible_build")), rfs::read(bin_name("foo")));
}); I think it might be assuming that the bins are directories due to the lack of extension. I tried manually adding extensions with |
This comment has been minimized.
This comment has been minimized.
Oh this one is easy. rustc performs hyphen normalization for library names, i.e. |
Alright, I have done a big cleanup. This should be a lot nicer to look at. Note this line: // FIXME(Oneirical): this specific case fails the final assertion.
// diff_dir_test(CrateType::Bin, RemapType::Cwd { is_empty: false }); In the original test: # TODO: Builds of `bin` crate types are not deterministic with debuginfo=2 on
# Windows.
# See: https://github.com/rust-lang/rust/pull/87320#issuecomment-920105533
# Issue: https://github.com/rust-lang/rust/issues/88982
#
# different_source_dirs_bin \
# remap_cwd_bin \ Note that despite the comment mentioning a Windows-specific problem, As for Feel free to run try jobs after CI is green. @rustbot review |
This PR modifies cc @jieyouxu |
That seems like the case. If I drop the |
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.
Thanks, this is now much easier to follow!
@bors try |
@rustbot author |
…<try> Migrate `reproducible-build` `run-make` test to rmake Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html). This will likely fail. Locally, rustc errors with `linker 'linker' not found` on line 36 while the file exists according to the dir-debug statement before it. If this gets fixed and the test passes, further developments may include: - [x] There may be some leftovers from each test - `test_in_tmpdir` may therefore be required. - [ ] Try jobs on all ignored architectures. - [x] A potential refactor with a struct and a custom function like rust-lang#128410 so this isn't just a huge stream of `rfs` and `rustc`. This is a little bit harder to do in this test considering the variability present in each test case. try-job: aarch64-apple try-job: test-various try-job: armhf-gnu try-job: x86_64-msvc try-job: x86_64-mingw try-job: i686-msvc try-job: i686-mingw try-job: x86_64-gnu-llvm-17 try-job: dist-various-1
ed0a203
to
b80db63
Compare
Trying again. |
…<try> Migrate `reproducible-build` `run-make` test to rmake Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html). This will likely fail. Locally, rustc errors with `linker 'linker' not found` on line 36 while the file exists according to the dir-debug statement before it. If this gets fixed and the test passes, further developments may include: - [x] There may be some leftovers from each test - `test_in_tmpdir` may therefore be required. - [ ] Try jobs on all ignored architectures. - [x] A potential refactor with a struct and a custom function like rust-lang#128410 so this isn't just a huge stream of `rfs` and `rustc`. This is a little bit harder to do in this test considering the variability present in each test case. // try-job: aarch64-apple // try-job: aarch64-gnu // try-job: armhf-gnu // try-job: test-various // try-job: dist-various-1 try-job: x86_64-msvc try-job: x86_64-mingw try-job: i686-msvc try-job: i686-mingw
☀️ Try build successful - checks-actions |
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.
Thanks! A nit for an outdated FIXME, then r=me after a rebase and running the second batch of non-Windows try-jobs and if they come back green.
// FIXME(Oneirical): ignore-windows | ||
// # FIXME: Builds of `bin` crate types are not deterministic with debuginfo=2 on | ||
// # Windows. | ||
// # See: https://github.com/rust-lang/rust/pull/87320#issuecomment-920105533 | ||
// # Issue: https://github.com/rust-lang/rust/issues/88982 |
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.
Suggestion: this comment is moved to specific cases, we should remove this top-level ignore-windows FIXME comment.
@rustbot author |
b80db63
to
e752410
Compare
@bors try |
…<try> Migrate `reproducible-build` `run-make` test to rmake Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html). This will likely fail. Locally, rustc errors with `linker 'linker' not found` on line 36 while the file exists according to the dir-debug statement before it. If this gets fixed and the test passes, further developments may include: - [x] There may be some leftovers from each test - `test_in_tmpdir` may therefore be required. - [ ] Try jobs on all ignored architectures. - [x] A potential refactor with a struct and a custom function like rust-lang#128410 so this isn't just a huge stream of `rfs` and `rustc`. This is a little bit harder to do in this test considering the variability present in each test case. // try-job: x86_64-msvc // windows jobs passed in a prior run // try-job: x86_64-mingw // try-job: i686-msvc // try-job: i686-mingw try-job: aarch64-apple try-job: aarch64-gnu try-job: armhf-gnu try-job: test-various try-job: dist-various-1
☀️ Try build successful - checks-actions |
@bors rollup=iffy (reproducible-build isn't always reproducible) |
☀️ Test successful - checks-actions |
Finished benchmarking commit (569d7e3): comparison URL. Overall result: ✅ improvements - no action needed@rustbot label: -perf-regression Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)Results (primary 2.5%, secondary 0.8%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResults (secondary -3.2%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 751.349s -> 750.018s (-0.18%) |
Part of #121876 and the associated Google Summer of Code project.
This will likely fail. Locally, rustc errors with
linker 'linker' not found
on line 36 while the file exists according to the dir-debug statement before it.If this gets fixed and the test passes, further developments may include:
test_in_tmpdir
may therefore be required.remap-path-prefix-dwarf
run-make
test to rmake #128410 so this isn't just a huge stream ofrfs
andrustc
. This is a little bit harder to do in this test considering the variability present in each test case.// try-job: x86_64-msvc // windows jobs passed in a prior run
// try-job: x86_64-mingw
// try-job: i686-msvc
// try-job: i686-mingw
try-job: aarch64-apple
try-job: aarch64-gnu
try-job: armhf-gnu
try-job: test-various
try-job: dist-various-1