Repository navigation
Conversation
|
These commits modify the If this was unintentional then you should revert the changes before this PR is merged. |
|
The last commit is a squashed version of ab696d1...6352cfe in case you are curious how exactly I got there. |
This comment has been minimized.
This comment has been minimized.
42d6209 to
9a45e88
Compare
|
cc @rust-lang/miri |
This comment has been minimized.
This comment has been minimized.
|
Some questions, in case I won't finish reviewing today:
|
It will create a new incr comp session for both fat and thin lto, but it is currently only used for thin lto. This new incr comp session stores a work product index and the actual work products. The only extra work is creating that new incr comp session dir and writing an extra work product index file. The actual work products are just moved to a different location.
Previously we hardlinked some files directly from the old incr comp dir to the new one. Now we instead hardlink to a temporary path and later hardlink to the new path. This is important because these files are cached in the main incr comp cache, but we need access to them after the main incr comp cache is finalized and thus the files can be deleted by a concurrent rustc instance. |
|
Can't reproduce the CI failure with |
This comment has been minimized.
This comment has been minimized.
This ensures GC happens each time a new session directory is created, even if future prepare_session_directory call may forget it. This should not result in any behavior change, even in the presence of corrupted incr comp cache dirs given that the load_dep_graph result is only checked after GCing.
This is more consistent with the non-LTO cache copying.
This requires using a separate incr comp session for ThinLTO. Also avoid directly copying between incr comp session dirs.
To make sure they run for non-LTO builds too
5f604db to
fe5f597
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
Managed to reproduce it by removing the test output dir. Pushed a quick fix for most of the issue. Couple of codegen-llvm tests that still fail that I need to investigate. |
| // Generate a session directory of the form: | ||
| // | ||
| // {incr-comp-dir}/{crate-name-and-disambiguator}/s-{timestamp}-{random}-working | ||
| // {incr-comp-dir}/{crate-name}-{disambiguator}-{prefix}/s-{timestamp}-{random}-{suffix}-working |
There was a problem hiding this comment.
| // {incr-comp-dir}/{crate-name}-{disambiguator}-{prefix}/s-{timestamp}-{random}-{suffix}-working | |
| // {incr-comp-dir}/{crate-name}-{disambiguator}-{suffix}/s-{timestamp}-{random}-{suffix}-working |
|
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Split LTO out into a new CodegenBackend method with separate incr comp cache
|
The job Click to see the possible cause of the failure (guessed by this bot) |
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (a3081a9): comparison URL. Overall result: ❌✅ regressions and improvements - please read:Benchmarking means the PR may be perf-sensitive. Consider adding rollup=never if this change is not fit for rolling up. Next, please: If you can, justify the regressions found in this try perf run in writing along with @bors rollup=iffy rustc-perf Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary -4.5%, secondary -0.2%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary -0.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis perf run didn't have relevant results for this metric. Bootstrap: 461.156s -> 460.481s (-0.15%) |
View all comments
To allow moving it into the
-Zlink-onlystep in the next PR.Part of rust-lang/compiler-team#908