-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Consider aggressively avoiding generating memcpys for moves if we can avoid it #13707
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
Is there any reason to use |
Triage: no change |
Triage: I know @pcwalton was doing some work on a related area recently, but don't believe it bore any fruit. |
I'm going to resurrect this bug as a tracking bug for various bad Here's one that has been affecting Stylo (cc @bholley): https://bugzilla.mozilla.org/show_bug.cgi?id=1380198 |
Let's close this or actually treat it as a tracking bug and put more details in it, it's not currently very actionable. I vote for closing it. Cc @rust-lang/compiler @rust-lang/wg-codegen |
I think we can address a few of these issues with mir optimizations and ABI adjustments as noted above.
|
The plan is getting something like #47954 into the compiler in the coming months. |
@oli-obk your last point can be achieved by moving the |
Add `move_const_to_impl` assist Closes rust-lang#13277 For the initial implementation, this assist: - only applies to inherent impl. Much as we can *technically* provide this assist for default impl in trait definitions, it'd be complicated to get it right. - may break code when the const's name collides with an item of a trait the self type implements. Comments in the code explain those caveats in a bit more detail.
) rust-lang#133150 This is more likely to be intended as an intra-doc link than it is to be intended as a refdef. If a refdef is intended, it does not need to be nested within a list item. ```markdown - [`LONG_INTRA_DOC_LINK`]: this looks like an intra-doc link, but is actually a refdef. The first line will seem to disappear when rendered as HTML. ``` > - [`LONG_INTRA_DOC_LINK`]: this > looks like an intra-doc link, > but is actually a refdef. > The first line will seem to > disappear when rendered as HTML. changelog: [`doc_nested_refdefs`]: add suspicious lint for link def at start of list items and block quotes
Given that our assembler output tends to have a lot of moves in it and LLVM is bad at optimizing them out, I'm beginning to wonder if we shouldn't take more aggressive steps. For example:
Any others?
The text was updated successfully, but these errors were encountered: