-
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
[beta] always disable copy_file_range to avoid EOVERFLOW errors #79008
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
|
This is going to just be a (possible) performance hit, right? Do we have numbers on it (perhaps from a past PR)? I am wondering basically if the fix here is worth the performance loss; maybe we should gate the disable on e.g. mips or something like that. cc @pietroalbini this or #79007 will likely want to land into 1.48 |
It's not just performance. copy_file_range can also save disk space if you're on btrfs or xfs by creating reflink copies, That might also be relevant for anything running in certain container setups. As for the performance numbers:
|
Ok, the performance impact is not too big and this is the most minimal patch, so I think it's the right thing to backport to 1.48 and 1.49 (once that branches). @bors r+ rollup=never p=1 |
📌 Commit d19e2de has been approved by |
I find this statement a bit confusing when looking at the results. That said it's not a regression/performance degradation but an optimisation delayed by few more weeks (with proper reason) so the decision is understandable. |
Yes, and ultimately (AFAIK) use of such file systems is somewhat unusual, though not entirely unexpected. I also somewhat expect that the specialization here is likely not used by cases where it is absolutely critical to get this behavior - those likely want to call the relevant APIs directly. Once we get more assurance that this all works and roll it out for a while we may provide more guarantees here |
⌛ Testing commit d19e2de with merge a238a370d9a199d57826b528681c572fa0929f03... |
💔 Test failed - checks-actions |
@bors retry spurious apple lldb error |
☀️ Test successful - checks-actions |
beta-nominating & accepting this for backport (really forward port) to 1.49, which has just branched. |
Do you need a separate PR for that? |
No, I will pick it up as a part of regular beta backports, likely sometime in the next week or two. |
…ulacrum [beta] backports * [beta] always disable copy_file_range to avoid EOVERFLOW errors rust-lang#79008 * Enforce no-move rule of ReentrantMutex using Pin and fix UB in stdio rust-lang#77801 * bootstrap: use the same version number for rustc and cargo rust-lang#79133 * [beta] Revert "Enable ASLR for windows-gnu" rust-lang#79141 * [beta] revert rust-lang#78790, vendor libtest for rustc-src rust-lang#79571 * Mirror centos vault to S3 rust-lang#79435 * [beta] Update cargo rust-lang#79739 This also bumps to non-dev stable compiler. r? `@ghost`
A bigger hammer as alternative to #79007
Pro: will certainly fix the issue
Cons: will disable copy_file_range for everyone
Resolves #78979