Conversation
This comment has been minimized.
This comment has been minimized.
|
|
This comment has been minimized.
This comment has been minimized.
73f1b4f to
7f509ab
Compare
This comment has been minimized.
This comment has been minimized.
2537bfb to
b31fd85
Compare
|
cc @rust-lang/lang |
|
Does this perhaps fix #127336 by rejecting it? |
This comment was marked as resolved.
This comment was marked as resolved.
b31fd85 to
2beed43
Compare
It doesn't currently. |
2beed43 to
839b844
Compare
|
Undrafting now that CI passes |
|
☀️ Test successful - checks-actions |
What is this?This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.Comparing 55d4364 (parent) -> 86d0aef (this PR) Test differencesShow 433 test diffsStage 1
Stage 2
Additionally, 384 doctest diffs were found. These are ignored, as they are noisy. Job group index
Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard 86d0aef80403f095d8bbabf44d9fdecfcd45f076 --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
Thanks @oli-obk, @lcnr, @fee1-dead, @fmease and @workingjubilee for reviews! |
|
Finished benchmarking commit (86d0aef): comparison URL. Overall result: ❌ regressions - please read the text belowOur benchmarks found a performance regression caused by this PR. Next Steps:
@rustbot label: +perf-regression 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 2.0%, secondary -0.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 2.6%, secondary 2.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeResults (primary 0.0%, secondary 0.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 756.784s -> 693.274s (-8.39%) |
|
(Note: the bootstrap change is unrelated to this PR, we used to unnecessarily compile too much stuff in the bootstrap benchmark). |
|
As noted in this summary comment, the performance regression is expected and will be addressed in follow ups. @rustbot label: +perf-regression-triaged |
This patch implements the non-const parts of rust-lang/rfcs#3729. It introduces two new traits to the standard library,
MetaSizedandPointeeSized. See the RFC for the rationale behind these traits and to discuss whether this change makes sense in the abstract.These traits are unstable (as is their constness), so users cannot refer to them without opting-in to
feature(sized_hierarchy). These traits are not behindcfgs as this would make implementation unfeasible, there would simply be too manycfgs required to add the necessary bounds everywhere. So, likeSized, these traits are automatically implemented by the compiler.RFC 3729 describes changes which are necessary to preserve backwards compatibility given the introduction of these traits, which are implemented and as follows:
?Sizedis rewritten asMetaSizedMetaSizedis added as a default supertrait for all traits w/out an explicit sizedness supertrait already.There are no edition migrations implemented in this, as these are primarily required for the constness parts of the RFC and prior to stabilisation of this (and so will come in follow-up PRs alongside the const parts). All diagnostic output should remain the same (showing
?Sizedeven if the compiler seesMetaSized) unless thesized_hierarchyfeature is enabled.Due to the use of unstable extern types in the standard library and rustc, some bounds in both projects have had to be relaxed already - this is unfortunate but unavoidable so that these extern types can continue to be used where they were before. Performing these relaxations in the standard library and rustc are desirable longer-term anyway, but some bounds are not as relaxed as they ideally would be due to the inability to relax
Deref::Target(this will be investigated separately).It is hoped that this is implemented such that it could be merged and these traits could exist "under the hood" without that being observable to the user (other than in any performance impact this has on the compiler, etc). Some details might leak through due to the standard library relaxations, but this has not been observed in test output.
Notes:
PointeeSizedis a different name from the RFC just to make it more obvious that it is different fromstd::ptr::Pointeebut all the names are yet to be bikeshed anyway.Fixes #79409.
r? @ghost (I'll discuss this with relevant teams to find a reviewer)